I have the following line in crontab.
When I reboot, the script runs (i.e., my Teamspeak 3 server starts) in the background, but I was trying to find how I could stop it (I can't just ctrl+c the terminal since it's now running in the background). One forum post said to kill the process by using the command below.
ps -ef | grep -i XXXX: to find your background running process kill OID : kill your unnecessary process
By OID, I assumed he meant PID. However, when I tried to apply this to my scenario, I found three processes running, as shown below.
$ps -ef | grep ts3 server 889 586 0 22:33 ? 00:00:00 /bin/sh -c /usr/bin/teamspeak3-server_linux-amd64/ts3server_minimal_runscript.sh server 890 889 0 22:33 ? 00:00:00 /usr/bin/teamspeak3-server_linux-amd64/ts3server_minimal_runscript.sh server 903 890 0 22:33 ? 00:00:00 ./ts3server_linux_amd64
I am confused. Why are there three processes running? I was expecting just to see one script running (i.e., I imagined just the middle line would be there). I could kill all three and I guess it would stop my script, but I want to understand why there are three processes here and not one?