Re: Just Moved server from Digital Ocean and now server won't run


N9UMJ
 

#!/bin/bash
### BEGIN INIT INFO
#
# Provides:             YSFReflector
# Required-Start:       $all
# Required-Stop:
# Default-Start:        2 3 4 5
# Default-Stop:         0 1 6
# Short-Description:    Example startscript YSFReflector

#
### END INIT INFO
## Fill in name of program here.
PROG="YSFReflector"
PROG_PATH="/usr/local/bin/"
PROG_ARGS="/etc/YSFReflector.ini"
PIDFILE="/var/run/YSFReflector.pid"
USER="root"

start() {
      if [ -e $PIDFILE ]; then
          ## Program is running, exit with error.
          echo "Error! $PROG is currently running!" 1>&2
          exit 1
      else
          cd $PROG_PATH
          ./$PROG $PROG_ARGS
          echo "$PROG started"
          touch $PIDFILE
      fi
}

stop() {
      if [ -e $PIDFILE ]; then
          ## Program is running, so stop it
         echo "$PROG is running"
         rm -f $PIDFILE
         killall $PROG
         echo "$PROG stopped"
      else
          ## Program is not running, exit with error.
          echo "Error! $PROG not started!" 1>&2
          exit 1
      fi
}

## Check to see if we are running as root first.
## Found at
## http://www.cyberciti.biz/tips/shell-root-user-check-script.html
if [ "$(id -u)" != "0" ]; then
      echo "This script must be run as root" 1>&2
      exit 1
fi

case "$1" in
      start)
          start
          exit 0
      ;;
      stop)
          stop
          exit 0
      ;;
      reload|restart|force-reload)
          stop
          sleep 5
          start
          exit 0
      ;;
      **)
          echo "Usage: $0 {start|stop|reload}" 1>&2
          exit 1
      ;;
esac
exit 0
### END

On Tue, Jun 18, 2019 at 6:28 AM Mike KB8JNM <groupio@...> wrote:

Show me YSFReflector.ini & your YSFReflector.sh  contents

and  does"  /var/run/YSFReflector.pid  "  exist ?


what is returned when you run  YSFReflector restart ?


On 6/18/2019 1:47 AM, N9UMJ wrote:
Mike

I tried to reload the YSFReflecor and can't get it to reinstall over whats already there.

Analog_Bridge  NXDNClients  P25Clients  Quantar_Bridge  YSFParrot
DMRGateway     NXDNGateway  P25Gateway  YSFClients      md380-emu
MMDVM_Bridge   NXDNParrot   P25Parrot   YSFGateway      opt
root@hwsrv-499225:/opt# sudo chown mmdvm /var/log/YSFReflector
chown: cannot access '/var/log/YSFReflector': No such file or directory
root@hwsrv-499225:/opt# cd YSFClients
root@hwsrv-499225:/opt/YSFClients# ls
LICENCE    YSFClients      YSFGateway  YSFReflector
README.md  YSFClients.sln  YSFParrot
root@hwsrv-499225:/opt/YSFClients# cd YSFReflector
root@hwsrv-499225:/opt/YSFClients/YSFReflector# sudo nano YSFreflector.ini
root@hwsrv-499225:/opt/YSFClients/YSFReflector# udo nano YSFReflector.ini

root@hwsrv-499225:/opt/YSFClients/YSFReflector# sudo nano YSFReflector.ini
root@hwsrv-499225:/opt/YSFClients/YSFReflector# sudo useradd mmdvm -g mmdvm -s /                                                                             sbin/nologin
useradd: user 'mmdvm' already exists
root@hwsrv-499225:/opt/YSFClients/YSFReflector# sudo chown mmdvm /var/log/YSFRef                                                                             lector
chown: cannot access '/var/log/YSFReflector': No such file or directory
root@hwsrv-499225:/opt/YSFClients/YSFReflector#

What Think??

On Mon, Jun 17, 2019 at 10:52 PM Mike KB8JNM <groupio@...> wrote:

http://manpages.ubuntu.com/manpages/bionic/man1/uname.1.html

On 6/17/2019 10:28 PM, N9UMJ wrote:
Mike

I recovered uname -r with sudo apt-get --reinstall install linux-headers-`uname -r`


Now it shows 4.15.0-15 generic for uname-r 




On Sun, Jun 16, 2019, 9:04 PM Mike KB8JNM <groupio@...> wrote:

Not sure if there is anything specific to Ubuntu but Just a thought... Your packaging might be missing something needed. Someone else may be able to chime in on that.

What does it say when you type   '  uname -r   ' from cmd line ?

Not familiar with Dig Oc but

Did you use one of their stock images ?  or - Can/did you load your own iso ?


On 6/16/2019 7:40 PM, N9UMJ wrote:
Hi Mike

Ubuntu 18.04

On Sun, Jun 16, 2019 at 12:20 PM Mike KB8JNM <groupio@...> wrote:

What OS and kernel version ?

On 6/16/2019 12:03 PM, N9UMJ wrote:
I just moved all of the DvSwitch files and server configurations away from Digital Ocean to a new VPS and can't get it to run, All of the ports have been configut=red on the firewall as the working version of DO, I was wondering if someone could give me some tips on what it might be or would be will to take a look see and see if I may have missed something

Thanks
Rick n9umj

Join main@DVSwitch.groups.io to automatically receive all group messages.