How to ensure a program is always running but without root access

bootcronmonitoringprocess

Currently I need to have a program running all the time, but when the server is rebooted I need to manually run the program. And sometimes I'm not available when that happens.

I can't use a normal configuration to restart my program when the server is starting because I don't have root access and the administrator don't want to install it.

Best Answer

I posted this on a similar question


If you have a cron daemon, one of the predefined cron time hooks is @reboot, which naturally runs when the system starts. Run crontab -e to edit your crontab file, and add a line:

@reboot /your/command/here

I'm told this isn't defined for all cron daemons, so you'll have to check to see if it works on your particular one