Thursday, May 13, 2010

Running a process that doesnt get killed on hangup

If you want to run a process on a server you are remotely connected to, without getting it disturbed if you close your SSH/telnet connection to a server, you should use command nohup

nohup your_command &

& puts it into backgroung process, and nohup is a POSIX command to ignore the HUP (hangup) signal, enabling the command to keep running after the user who issues the command has logged out.