Auto start program on Ubuntu

systemsautomation
systemsautomation used Ask the Experts™
on
Hi

I have installed Jasperserver on Ubuntu desktop 9. I just want to put it in Auto-start in Ubuntu so that does not need to be started manually everytime the computer restarts.

Please remember it should be started without logging into Ubuntu.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Top Expert 2009

Commented:
add your script in

/etc/init.d/rc.local

so it will start automaticaly when sytem will boot

but one way we do in linux

chkconfig servicename ON  [ i dont know if ubuntu support this]

so it will start the service automaticaly when system will boot


Top Expert 2009
Commented:
i think its /etc/rc.local

Commented:
on ubuntu, prefer using /etc/rc.local (wich is called by /etc/init.d/rc.local)
Success in ‘20 With a Profitable Pricing Strategy

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

Author

Commented:
Should I simply add my command at the end of the file e.g.
/opt/jasperserver.sh start ?
To make program start just after user logins Gnome, go to System menu, then choose Preferences and select Sessions:
Then press button Add, type application name, command to start it (its location like /usr/sbin/local/liferea), and press Ok and then Close. After next login to Gnome application will start. It works with any Linux distro running Gnome as Desktop manager.

Commented:
yes, in /etc/rc.local before the "exit 0"
Top Expert 2009

Commented:
if you run your problem like this
/opt/jasperserver.sh start

then yes, just add that line to rc.local file

your program will start automaticaly

Commented:
EscuroAnjo> "Please remember it should be started without logging into Ubuntu."

it has to be in the rc scripts

Author

Commented:
Thanks

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial