0

I have a couple of Python scripts I want to launch at bootup. One is located at the path below. /home/my-sickbeard-install/SickBeard.py Since Cron has never ever worked for me and nobody on about 5 forums knows how to fix my Cron problem even though it's a pretty much clean install of the OS, I need another method of launching these scripts on bootup. Can someone suggest to me another way I can launch them please? Note: This is actually for something I'm trying to do a Debian machine. Not sure if it makes any difference.

john smith
  • 3,161

2 Answers2

0

You can add it to /etc/rc.local. This can be used to run scripts and programs on system boot which doesn't have their own scripts for runlevels. It will run as root

Run sudo nano /etc/rc.local and add your line before exit 0

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

python /home/my-sickbeard-install/SickBeard.py 2>&1 >/dev/null &

exit 0

Press CTRL+ O to save and CTRL+ X to exit.

Germar
  • 6,537
0

have you tryed this:

python-py | echo '/home/my-sickbeard-install/SickBeard.py'
cron -l /home/my-sickbeard-install/SickBeard.py
cron -l -restart

and it might work fine this way.

Michael
  • 2,597