11.06.2008, 18:43
http://forum.sa-mp.com/index.php?topic=31833
^^ restarts every night and moves log to make way for new one
Theres also:
^ make that something like checksamp.sh in your SAMP directory, and then use a 5 min cron job to run /path/to/server/checksamp.sh
^^ restarts every night and moves log to make way for new one
Theres also:
Код:
#!/bin/sh cd /path/to/server PROCESS_COUNT=$(ps -fu root | grep serverexe | grep -v grep | wc -l) case $PROCESS_COUNT in 0) /path/to/server/serverexe & ;; 1) echo OK, program is running once ;; *) echo OK, program is already running multiple times ;; esac

