- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- what is nohup?
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2001 01:01 AM
тАО11-19-2001 01:01 AM
Thanks.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2001 01:05 AM
тАО11-19-2001 01:05 AM
Solutionnohup means 'no hang up'. When you login in a system and type some command or executing script in command prompt, it will hold up for a while until the job is finished. During this time, there is no prompt and you cannot execute anything. But with 'nohup' before your command, it will execute the job at the background and at the same time, you can still type any other command at the prompt which do not bother your previous job !
Regards,
Patrick
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2001 01:05 AM
тАО11-19-2001 01:05 AM
Re: what is nohup?
Use nohup (no hang-up) so that your background processes do not get terminated when you exit your login session eg.
$ nohup forever_running_script &
Hope this helps. Regards.
Steven Sim Kok Leong
Brainbench MVP for Unix Admin
http://www.brainbench.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2001 01:09 AM
тАО11-19-2001 01:09 AM
Re: what is nohup?
its documented quite well there.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2001 01:28 AM
тАО11-19-2001 01:28 AM
Re: what is nohup?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2001 01:30 AM
тАО11-19-2001 01:30 AM
Re: what is nohup?
& means run the process in the background.
Hope this helps. Regards.
Steven Sim Kok Leong
Brainbench MVP for Unix Admin
http://www.brainbench.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2001 02:09 AM
тАО11-19-2001 02:09 AM
Re: what is nohup?
nohup makes started process to ignore hangup and quit signals, thus our process wont die when his parent dies.
Best way to run a process with nohup is:
# nohup our_process &
Run it in background.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2001 03:56 AM
тАО11-19-2001 03:56 AM
Re: what is nohup?
and have done it lots of times,
use teh command jobs
to figure out what 'jobs' are in the background
bring them to the foreground with fg %jobid
You can kill with kill %job
Later,
Bill
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-19-2001 06:38 AM
тАО11-19-2001 06:38 AM
Re: what is nohup?
I think previous replies may cause some confusion.
Nohup has nothing to do with putting a process in the background. Appending an "&" to your command line causes that process to run in the background.
Nohup has everything to do with keeping a process running after you "hang up" the connection.
An example of when I run a nohup process is when I need to dial-in, start a long-running process, and hang up the connection. The job needs to be started with nohup put in the background so I can logout without the job quitting.
Also, by default output is written to nohup.out so you may want to redirect stdout and stderr when nohup'ing a process. I'd use:
nohup command line with args >output_filename 2>&1 &
Darrell