- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- background job
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
Forums
Discussions
Discussions
Discussions
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
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
05-16-2005 12:16 PM
05-16-2005 12:16 PM
background job
I tried to run background job on 11.11
but when I close terminal session,
# nohup sar -d 180 400 > sar.log &
background job also stopped.
what's the problem ??
regards
moon
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2005 12:29 PM
05-16-2005 12:29 PM
Re: background job
When I run nohup sar -d 180 400 > sar.log & nothing happens and when I run
# sar -d 180 400
I only get the headings from the output.
you can also do
#at now
sar -d 180 400 > sar.log
this will then give you a PID witht he process running
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2005 12:41 PM
05-16-2005 12:41 PM
Re: background job
nohup jobname &
or
jobname &
exit twice in seqeuence to release the terminal session.
ps -ef | grep jobname
to see the process list.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2005 12:58 PM
05-16-2005 12:58 PM
Re: background job
now I using #at now command but is it wrong?
#nohup sar -d 180 400 > sar.log &
then I tried to exit terminal session.
you know this message showed.
#there is running jobs
after that I exit session.
#ps -ef|grep sar -> no process
do I have to set something ??
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2005 02:05 PM
05-16-2005 02:05 PM
Re: background job
nohup sar -d 180 400 > sar.log &
then close your emulation session, don't 'exit'.
When you 'exit', the shell makes a reasonable attempt to kill all child processes.
What 'nohup' does, is stops a 'HUP' signal getting to your child process, not a reasonable 'TERM' or 'QUIT'. If you kill (not exit) the shell session, it isn't quite so friendly.
You can try setting 'stty -hupcl', but that probably won't help either.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2005 03:25 PM
05-16-2005 03:25 PM
Re: background job
it is find and you do not need the nohup or & as I previously stated:
# at now
sar -d 180 400 > sar.log
you can also schedule a job using at eg
at
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-16-2005 03:52 PM
05-16-2005 03:52 PM