Sponsored Content
Top Forums Shell Programming and Scripting not able to monitor the process Post 302227335 by rikxik on Thursday 21st of August 2008 04:20:15 AM
Old 08-21-2008
@infyanurag:

Please post the output of the grep.
Also post the output of "ptree <pid_of_monitor_process>".

That may provide some clue.
 

10 More Discussions You Might Find Interesting

1. Programming

How to monitor if a process is running

I would like to know if i can monitor if a process is running. I have one program wich is running all the time, called oliba, but sometimes it goes down, and I have to launch it again. Is there a way to monitor the pid of the program, and if the program goes down, to lauch it again? Can you give... (3 Replies)
Discussion started by: Pedro Tavares
3 Replies

2. Shell Programming and Scripting

Lightwight Process monitor

We've been having some problems with a specific program in our nightly processing, so I whipped up a little script to run to monitor it, and send an e-mail when it's complete (failure or not). My primary problem is that I cannot modify the binary or the script that calls it, since the developers... (7 Replies)
Discussion started by: LivinFree
7 Replies

3. Shell Programming and Scripting

script to monitor process running on server and posting a mail if any process is dead

Hello all, I would be happy if any one could help me with a shell script that would determine all the processes running on a Unix server and post a mail if any of the process is not running or aborted. Thanks in advance Regards, pradeep kulkarni. :mad: (13 Replies)
Discussion started by: pradeepmacha
13 Replies

4. UNIX for Dummies Questions & Answers

Monitor Memory of a process

Hi, I need to monitor the memory usage of a particular process continuously. As of now I am using the following command: ps -fu <user name> -o pid,comm,vsz | grep <process_name> | grep -v grep The output of this command gives me what i need except i want the output to keep getting updated... (3 Replies)
Discussion started by: archana485
3 Replies

5. UNIX for Advanced & Expert Users

code to monitor a process

hi, I need to change the code such that it becomes configurable to send email or sms or both. At the moment the code works like sending both email and sms for any alert now want to change it to send email/sms as per my demand. 1. Like for a particular alert I only want email 2. If the alert... (2 Replies)
Discussion started by: madfox
2 Replies

6. Shell Programming and Scripting

script to monitor the process system when a process from user takes longer than 15 min run.

get email notification from from system when a process from XXXX user takes longer than 15 min run.Let me know the time estimation for the same. hi ,any one please tell me , how to write a script to get email notification from system when a process from as mentioned above a xxxx user takes... (1 Reply)
Discussion started by: kirankrishna3
1 Replies

7. Shell Programming and Scripting

Script to Monitor a Process with Top.

Hi, I have written a script to monitor a Process with the help of top command. This is my script. ====================== #!/bin/sh DATE=`date +%Y%m%d%H%M%S` HOME=/home/xmp/testing/xmp_report RADIUS_PID=`xms -xmp sh pr | grep "RADIUS.iamsp02ldv" |awk '{ print $3 }'` PSE_PID=`xms -xmp sh... (5 Replies)
Discussion started by: Siddheshk
5 Replies

8. Shell Programming and Scripting

Script to monitor the process

Hi, I need help to monitoring a process using the shell script The same output is below oracle 32578 32577 0 Feb27 ? 00:06:47 java -cp .:lib/ant.jar:lib/ojdbc5.jar:lib/log4j-1.2.17.jar:/ORACLE_HOME/server/lib/wlfullclient.jar:/ORACLE _HOME/server/lib/weblogic.jar:Alerts.jar... (9 Replies)
Discussion started by: ajothi
9 Replies

9. Shell Programming and Scripting

Monitor and restart UNIX process

Hi all, Tearing my hair out..! I have a requirement to monitor and restart a unix process via a simple watchdog script. I have the following 3 scripts that dont work for me.. script 1 (only produces 1 output if process is up or not)... (4 Replies)
Discussion started by: jonnyd
4 Replies

10. Shell Programming and Scripting

Monitor log when Process comes UP

Hi, I need to grep a pattern in the log file of a process and send a mail if pattern found.But I am not able to figure out how do I detect when the process comes UP,it is started several times a day and each time it is started I need to perform this action. Please suggest something. (3 Replies)
Discussion started by: vishal bhargava
3 Replies
ptree(1)																  ptree(1)

NAME
ptree - print process trees SYNOPSIS
/usr/bin/ptree [-a] [-c] [-z zone] [pid | user] ... ptree prints the process trees containing the specified pids or users, with child processes indented from their respective parent pro- cesses. An argument of all digits is taken to be a process-id, otherwise it is assumed to be a user login name. The default is all pro- cesses. The following options are supported: -a All. Print all processes, including children of process 0. -c Contracts. Print process contract memberships in addition to parent-child relationships. See process(4). This option implies the -a option. -z zone Zones. Print only processes in the specified zone. Each zone ID can be specified as either a zone name or a numerical zone ID. This option is only useful when executed in the global zone. The following operands are supported: pid Process-id or a list of process-ids. ptree also accepts /proc/nnn as a process-id, so the shell expansion /proc/* can be used to specify all processes in the system. user Username or list of usernames. Processes whose effective user IDs match those given are displayed. Example 1: Using ptree The following example prints the process tree (including children of process 0) for processes which match the command name ssh: $ ptree -a `pgrep ssh` 1 /sbin/init 100909 /usr/lib/ssh/sshd 569150 /usr/lib/ssh/sshd 569157 /usr/lib/ssh/sshd 569159 -ksh 569171 bash 569173 /bin/ksh 569193 bash The following exit values are returned: 0 Successful operation. non-zero An error has occurred. /proc/* process files See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWesu | +-----------------------------+-----------------------------+ |Interface Stability |See below. | +-----------------------------+-----------------------------+ The human readable output is Unstable. The options are Evolving. gcore(1), ldd(1), pargs(1), pgrep(1), pkill(1), plimit(1), pmap(1), preap(1), proc(1), ps(1), ppgsz(1), pwd(1), rlogin(1), time(1), truss(1), wait(1), fcntl(2), fstat(2), setuid(2), dlopen(3C), signal.h(3HEAD), core(4), proc(4), process(4), attributes(5), zones(5) 11 Oct 2005 ptree(1)
All times are GMT -4. The time now is 08:49 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy