LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices



Reply
 
Search this Thread
Old 05-29-2009, 03:01 AM   #1
vinaykori
LQ Newbie
 
Registered: Jan 2008
Posts: 4
Blog Entries: 2

Rep: Reputation: 0
Shell script for reading a particular process contineously from process table


Hi All,
Can any one help me out in writing the script for the below scenrio.

Shell script for reading a particular process contineously from process table and redirect to a file with process details.

Requirement:
There will be a number of processes is running with the same process name having diffrenet Process ID. i wan't whenever a new process get invokes with the same process name then those process details needs to be redirect to File where you can easly see the no of processes ran.

For this require a deamon shell which will be always running in the back ground and checks for a particular process like "http" , whenever it invokes need to append the file with process details.

Example:
There are 4 http process are running whenever the new http process invokes "fifth" one that also need to update in the file with process details.
 
Old 05-29-2009, 03:30 AM   #2
ghostdog74
Senior Member
 
Registered: Aug 2006
Posts: 2,697
Blog Entries: 5

Rep: Reputation: 241Reputation: 241Reputation: 241
do your own homework
 
Old 05-29-2009, 07:52 AM   #3
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 729Reputation: 729Reputation: 729Reputation: 729Reputation: 729Reputation: 729Reputation: 729
Per the LQ Rules, please do not post homework assignments verbatim. We're happy to assist if you have specific questions or have hit a stumbling point, however. Let us know what you've already tried and what references you have used (including class notes, books, and Google searches) and we'll do our best to help. Also, keep in mind that your instructor might also be an LQ member.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
process interaction in shell script a.toraby Programming 10 11-09-2008 11:02 AM
Shell Script : Kill a running process when another process starts ashmew2 Linux - General 3 08-20-2008 04:47 AM
shell script - keepalive a process zipo13 Programming 2 07-19-2007 12:06 PM
kill the process invoked from a shell script, when the script is killed kskkumar Linux - Software 8 05-23-2007 12:29 PM
Process Table-Process Control Block sarahmencer Linux - General 1 01-09-2006 10:14 PM


All times are GMT -5. The time now is 04:06 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration