Re: Checking If process is running
From: scriptOmatic (ScriptOmatic_at_ChironComputing.Com)
Date: 05/28/03
- Next message: goat troll: "Re: unix based email"
- Previous message: BG: "Re: unix based email"
- In reply to: Courtney Messam: "Checking If process is running"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Tue, 27 May 2003 22:05:54 GMT
Courtney Messam wrote:
>
> Hi Guys,
> I currently have this process that monitors some stuff on my server. Every
> time somebody tries to execute the script I want to check if the script is
> already running. I have issued this command below and I get two processes
> returning but I am expecting only one. This does not help what I want to do
> and sometimes I get incorrect response when I check if a process is running.
> ---------------------
> neptune:$ ps -ef | grep -v "grep" | grep "uptime.ksh"
>
> oracle 28992 300 0 May 14 ? 0:00 sh -c /admin/monitor/uptime.ksh
> >>/data/log/monitor/uptime
> oracle 28996 28992 0 May 14 ? 0:00 /bin/ksh
> /admin/monitor/uptime.ksh
> --------------------
>
> 1. First of all, is there a way to run the ps command or equivalent command
> to only show one process
> 2. Why am I see 2 processes in the output?
>
> Thanks guys
Courtney,
If you would like a web interface, your shell script "uptime.ksh" can
be plugged into OpenSysMon -- see http://www.opensysmon.com
-- http://ftp.opensysmon.com is a shell script archive site with an open source system monitoring and network monitoring software package. Many platforms are supplied already compiled.
- Next message: goat troll: "Re: unix based email"
- Previous message: BG: "Re: unix based email"
- In reply to: Courtney Messam: "Checking If process is running"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|