02-24-2009
Status of a Linux process
All,
I have fair amount of knowledge about shell scripting, but only liitle on system administration.
I would like to know how to analyze whether the particular linux process is alive or not ? If it is alive, will it affect the performace of other process ?.
Also is it still consuming resource? If so, how much resource its consuming?
Example,
aps 31649 13702 0 Feb17 ? 00:00:00 auto_remote
The above process is running since Feb17,2009. I would like to know whether this process is till doing any useful operation. Is it consuming any resouce, etc.,
10 More Discussions You Might Find Interesting
1. AIX
On AIX 5.2, I use "ps -ef " command to display the process status, the field of command looks like: , the detailed contents are:
# ps -ef |grep rtesfmrt
Display:
osa 32455 1 0 18:20 - 1:57
The origianl format shoud be:
osa 32455 1 0 18:20 - 1:57 ... (2 Replies)
Discussion started by: Frank2004
2 Replies
2. UNIX for Advanced & Expert Users
Hi all,
How can a process be aware of the signals it handles. I looked at available signal API, but couldn't find any help.
If a process defines it own handler for a signal, the default handler for that signal becomes overridden.
I am interested in getting to know the... (2 Replies)
Discussion started by: bluehive
2 Replies
3. Solaris
Hello Folks,
On a Solaris 8 system I am trying to diagnosis memory usage of the running processes. I've been using prstat, and top , but the outputs of those include the shared memory used by the process. Hence, more a dozen of running processes are using the shared memory, and the total memory... (1 Reply)
Discussion started by: altinkaya
1 Replies
4. UNIX for Advanced & Expert Users
Hi all,
How can I get the list of all the processes that are either Orphan or Zombie or Running or Ended or Stopped ?
Please suggest !!
Thanks.
Varun:b: (2 Replies)
Discussion started by: varungupta
2 Replies
5. Programming
hello everybody!!
i want to post a question!
is there any way to get process status using C commands?
To be more specific, i want to know whether a process is running or is stop or killed.
thanks in advance! (3 Replies)
Discussion started by: nicos
3 Replies
6. Shell Programming and Scripting
Hi,
I am executing the command: "./opmnctl status" to get the status of the processes in the instance. There are totally 5 processes that are avaialble, out of which 3 are "Alive" and 2 are "Down". How can I use the IF loop to get the status and echo it??
For instance I want to run a check... (8 Replies)
Discussion started by: yoursdavinder
8 Replies
7. Shell Programming and Scripting
Hi we have weblogic deployed under Linux Enterprise 5 .
Now i want to write a script that checks if weblogic is running or not
I have found that weblogic uses Java as process .
Can i do this way :
my Script File :
Echo Checking Status
if
then
echo Server Running
else
echo... (2 Replies)
Discussion started by: Ravi Pavanv
2 Replies
8. Shell Programming and Scripting
Hi,
I have a cron job which runs every ten minutes, now i hav to check the process whether it is running or not only once and then this should be sent to a log file..
crontab :
00,10,20,30,40,50 * * * * a
process check
ps = 'ps -ef |grep a '
if
then
echo " Success" >... (3 Replies)
Discussion started by: NehaKrish
3 Replies
9. UNIX for Dummies Questions & Answers
how can I learn the status of a process (sleeping, running or ready.) (2 Replies)
Discussion started by: merturk
2 Replies
10. UNIX for Beginners Questions & Answers
Hi All,
Have a query
How to check for a process and if down start it , try if for 2 times and its not starting don't do it
My code is working to some extent but while starting try starting both times.
Please advise , whats wrong here ?
if you have any other approach please do share.
My... (1 Reply)
Discussion started by: abhaydas
1 Replies
LEARN ABOUT HPUX
getrusage
getrusage(2) System Calls Manual getrusage(2)
NAME
getrusage - get information about resource utilization
SYNOPSIS
DESCRIPTION
The function provides measures of the resources used by the current process or its terminated and waited-for child processes. If the
value of the who argument is information is returned about resources used by the current process. If the value of the who argument is
information is returned about resources used by the terminated and waited-for children of the current process. If the child is never waited
for (for instance, if the parent has set or sets to the resource information for the child process is discarded and not included in the
resource information provided by The r_usage argument is a pointer to an object of type in which the returned information is stored.
If the current process is multi-threaded, returns the information about the resources used by all the active and the reaped threads/light-
weight processes in the current process if the value of the who argument is If the value of the who argument is in a multi-threaded
process, information returned is the same as it would be for a single-threaded process.
RETURN VALUE
Upon successful completion, returns Otherwise, is returned, and is set to indicate the error.
ERRORS
The function will fail if:
[EINVAL] The value of the who argument is not valid.
SEE ALSO
exit(2), sigaction(2), time(1), times(2), wait(1), <sys/resource.h>.
getrusage(2)