run a command at startup

General support questions

run a command at startup

Postby squirrelof09 » 2013/07/21 01:45:30

I have a screen command that I'd like run on my system as soon as it comes up.

I run a teamspeak 3 server, it needs to start first, then I'd like for a java application to execute next. I already have a ts3 start script written. BUt unfortunately I can't figure out a way to get this java application to start, I have to manually use a screen command to start the application, like this
cd /home/teamspeak/teamspeak3-server_linux-amd64/tsbot
screen -S ts3bot java -mx30M -jar JTS3ServerMod.jar

How would I go about making the above command run at startup?
squirrelof09
 
Posts: 3
Joined: 2012/11/21 00:55:07

Re: run a command at startup

Postby mphelpsmd » 2013/07/21 04:35:40

Append your command to /etc/rc.d/rc.local, and it will run at startup.

Michael
mphelpsmd
 
Posts: 16
Joined: 2013/06/09 18:42:22


Return to CentOS 6 - General Support

Who is online

Users browsing this forum: No registered users and 14 guests