Sharing Knowledge | System Admin Articles

NOHUP : Run command continiously even if session closed

nohup command is used to run any command continiously even if you close your session from the server.

If nohup added in front of any command will continue running that command or process, even if you exit your terminal or close your session in that server


nohup command-to-run &


  • command-to-run : is name of command or script which you want to run. You can pass argument to that command or script.
  • & : nohup does not automatically runs the command in the background. you must do that explicitly, by ending the command line with an & symbol.


# nohup /root/ error.log  2>&1  &

Labels: Linux, Tips

My Profile PhotoAbout the Author

I'm Parthiban, An UNIX System Admin by Profession. I'm Experienced in Linux/Unix System Administration and Scripting. I have done lot of work on the infrastructure Mgmt side in Linux, UNIX and Windows system administration, Hardware, Storage and Data center. I'm blogging since 2008.
Follow Me On Twitter or On Facebook

0 Comments for "NOHUP : Run command continiously even if session closed"

What do you think about this Article? Add your Opinion..!

Back To Top