ID:100593
 
Redundant
Applies to:Dream Daemon
Status: Redundant

This feature has already been implemented, or is already achievable with existing methods.
I'm currently hosting my game on a Linux machine and I made a cronjob that auto restarts my Game every day at 7AM,
but It kills all the DreamDaemons that are online at this moment because there is no way to get the PID to kill, so my suggestion is can DreamDaemon automaticly create a .pid file in the folder that the game is hosted in?
There's no need to do this, because many (Debian-based, at least) Linux distributions nowadays provide a handy tool for this: start-stop-daemon.

Try the following command:
/sbin/start-stop-daemon -d /home/myuser/byondgame -p /home/myuser/byondgame/byondgame.pid -m -b -S -x /usr/local/byond/bin/DreamDaemon -- /home/myuser/byondgame/byondgame.dmb 1025 -safe -logself


This should run the .dmb file located in /home/myuser/byondgame/byondgame.dmb and leave a byondgame.pid file.

You can use the following commands to use the .pid file to interact with the server.

Rebooting:
/sbin/start-stop-daemon -p /home/myuser/byondgame/byondgame.pid -K -s 10


Shutting down the server:
/sbin/start-stop-daemon -p /home/myuser/byondgame/byondgame.pid -K -s 15


Forcibly shutting down the server (in case it's frozen up):
/sbin/start-stop-daemon -p /home/myuser/byondgame/byondgame.pid -K -s 9


Good luck!
/sbin/start-stop-daemon -d /home/iratu/DragonballShuurajou -p /home/iratu/DragonballShuurajou/DragonballShuurajou.pid -m -b -S -x /usr/local/byond/bin/DreamDaemon -- DreamDaemon /home/iratu/DragonballShuurajou/DragonballShuurajou.dmb 6339 -safe -logself -quiet

I am using this command, did I make an error somewhere? because when I try to run it it does not startup the game.

[EDIT]

Okay nevermind this, It seems I made a huge mistake -_- Got it running now, Thanks Android Data.
Ter13 resolved issue (Redundant)