Hello,
I would like to run a certain command at boot on my freebsd VDS;
I have tried to create a file in /usr/local/etc/rc.d/ named triplea with the content
That wouldnt work, and the rc.d pages i saw in the handbook were either too complicated or confusing for my purpose.
I was also suggested to try crontab. So I did the following
and added the line
However after rebooting, it didnt work. Here is the tail end of /var/log/cron:
Well thats all the info Ive got and everything Ive tried. Id really appreciate any help with this, if you need any information, please dont hesitate to ask.
Thanks for your time,
Bung
I would like to run a certain command at boot on my freebsd VDS;
Code:
screen -d -m -S triplea /home/triplea/data/triplea_1_0_2/run-server.sh
I have tried to create a file in /usr/local/etc/rc.d/ named triplea with the content
Code:
#!/bin/sh
screen -d -m -S triplea /home/triplea/data/triplea_1_0_2/run-server.sh
That wouldnt work, and the rc.d pages i saw in the handbook were either too complicated or confusing for my purpose.
I was also suggested to try crontab. So I did the following
Code:
#crontab -e -u triplea
and added the line
Code:
@reboot /usr/share/bin/screen -d -m -S triplea /home/triplea/data/triplea_1_0_2/run-server.sh
However after rebooting, it didnt work. Here is the tail end of /var/log/cron:
Code:
Mar 11 21:50:00 allanr2 /usr/sbin/cron[98390]: (root) CMD (/usr/libexec/atrun)
Mar 11 21:50:00 allanr2 /usr/sbin/cron[98404]: (root) CMD (/usr/local/ispmgr/sbin/watchdog)
Mar 11 21:51:04 allanr2 crontab[99580]: (root) BEGIN EDIT (triplea)
Mar 11 21:52:11 allanr2 crontab[99580]: (root) REPLACE (triplea)
Mar 11 21:52:11 allanr2 crontab[99580]: (root) END EDIT (triplea)
Mar 11 21:52:13 allanr2 crontab[99848]: (root) BEGIN EDIT (triplea)
Mar 11 21:52:16 allanr2 crontab[99848]: (root) END EDIT (triplea)
Mar 11 21:52:44 allanr2 /usr/sbin/cron[322]: (triplea) CMD (/usr/local/bin/screen -S triplea -md /home/triplea/data/triplea_1_0_2/run-server.sh)
Mar 11 21:55:00 allanr2 /usr/sbin/cron[944]: (root) CMD (/usr/libexec/atrun)
Mar 11 21:55:00 allanr2 /usr/sbin/cron[988]: (operator) CMD (/usr/libexec/save-entropy)
Well thats all the info Ive got and everything Ive tried. Id really appreciate any help with this, if you need any information, please dont hesitate to ask.
Thanks for your time,
Bung