View Single Post
Old Oct 1st, 2006, 11:52 PM   #20
climbnorth
Newbie
 
Join Date: Oct 2006
Posts: 16
Rep Power: 0 climbnorth is on a distinguished road
At the terminal type:

$ ps -auxwww

if that doesn't work try:

$ ps -aef

(I think thats the syntax) That will show you list of all processes and some otehr information that is useful: such as the command line that was used to execute the command. Now use grep to find out which command it was. Grep matches regular expressions but all you need is something you can identify that would be in the executables path- such as the name of your home directory. To tie the ps and grep commands together, use a pipe:

$ ps -auxwww | grep <something>

the result will possibly give you a few lines. It should be easy to identify your process- because the command string will probably look familiar (a.out??).

Now use the "kill" command on the process ID (first column). To make sure kill works, you can throw the "-9" switch in (which is more forceful).

$ kill -9 <pid>

BTW none of this will "mess up the server." Even if you tried to kill other processes, you wouldn't have permission.

By default, when you run apps remotely they should hang up when you exit your console. This is a design feature. To "daemonize" a process, you would use the command nohup. This makes it so it "doesn't hang up" after you exit. Because of this, your process probably died when you logged out. That is of course, dependant on the OS. Sometimes "logout" doesn't wokr, sometimes you have to use "exit" to make sure all processes die. Also, some applications may be built in with nohup ability (apps that you start with a script will likely have a call to nohup to daemonize or something similar).
climbnorth is offline   Reply With Quote