- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- problem from process running in background
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
12-20-2007 01:19 AM
12-20-2007 01:19 AM
Today i executed one scripts(.scr)which will generate reports(.csv file).
i run in this way
abc.scr &
it means i will run in backgound.
This script runs while loop and once records are over it teminates. It generates one CSV file as output.
I observed that this script is not getting terminated and cntinuously generatin records.
Files size is incerasing like anything. Actually it should process only 100 items.
Is any way to identify and kill this process?
Thanks
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-20-2007 01:34 AM
12-20-2007 01:34 AM
Solutionif you start your script in backgroud
you get some job-id
$ abc.scr &
[1]
$ now you can
$ kill %1
or
$ ps -ef | grep abc.scr
$ kill $the-pid-you-see
Or you can save the pid into a pidfile for later reference:
$ abc.scr &
$ echo $! >/tmp/abc.scr.pid
$ ps -fp $(/tmp/abc.scr.pid)
$ do-something-else
$
$ kill $(cat /tmp/abc.scr.pid)
But better you debug why your loop does not terminate. What kind of loop is there in your script?
rgds
HGH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-20-2007 01:38 AM
12-20-2007 01:38 AM
Re: problem from process running in background
see your background jobs with:
$ jobs
[1] running abc.scr &
[2] running efg.scr &
$ kill %1
rgds
HGH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-20-2007 02:46 AM
12-20-2007 02:46 AM
Re: problem from process running in background
Thanks a lot problem got resolved. I killed the processes.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-20-2007 11:58 PM
12-20-2007 11:58 PM
Re: problem from process running in background
You can also get a nice hierarchal listing of all of your processes with:
$ UNIX95= ps -Hfu $LOGNAME