[Nagiosplug-devel] [ nagiosplug-Bugs-948667 ] check_procs under HP-UX does not see command arguments

SourceForge.net noreply at sourceforge.net
Tue Aug 10 09:22:02 CEST 2004


Bugs item #948667, was opened at 2004-05-05 10:16
Message generated for change (Comment added) made by jhmartin
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=948667&group_id=29880

Category: Argument proccessing
Group: CVS
Status: Open
Resolution: None
Priority: 5
Submitted By: Mark Plaksin (happyzi)
Assigned to: Ton Voon (tonvoon)
Summary: check_procs under HP-UX does not see command arguments

Initial Comment:
The ps command used by check_procs on HP-UX does not
show command arguments.  So it can't be used to search
for things like "man ascii".

I think this is true for all versions of check_procs. 
I've specifically tried 1.3.1 and CVS HEAD under HP-UX
11.00.  I suspect it's the same on all versions of HP-UX.

configure picks '/usr/bin/ps -el' as the ps command. 
If this is changed to:
/usr/bin/env UNIX95=1 /usr/bin/ps  -eo
'state,uid,ppid,args'

and PS_FORMAT is "%s %s %s %n%s" and PS_VARLIST is
procstat,&procuid,&procppid,&pos,procprog

then it works.

----------------------------------------------------------------------

Comment By: Jason Martin (jhmartin)
Date: 2004-08-10 08:21

Message:
Logged In: YES 
user_id=589094

The CVS HEAD configure.in uses ps -el as the ps command for 
HP-UX, and that command only returns up to 15 characters of 
the  command name and excludes all arguments. 

ps -ef returns up to 64 characters of
the combination of command name and arguments.

Head -2 of ps -ef returns
     UID   PID  PPID  C    STIME TTY       TIME COMMAND
    root   625   624  0  Jun 17  ?         6:11 /usr/sbin/netfmt -
C -F -f /var/adm/nettl.LOG000 -c /var/adm/con

Head -3 of the UNIX95 syntax above returns
$ /usr/bin/env UNIX95=1 /usr/bin/ps -eo 'state,uid,ppid,args'
S        UID  PPID COMMAND
R        198  3023 /usr/bin/ps -eo state,uid,ppid,args
S         96     1 vmstat -S 300 2

This is true on the following versions of HPUX:
HP-UX hostname B.11.11 U 9000/800 1651319313 unlimited-
user license
HP-UX localhost B.10.20 E 9000/800 882327441 8-user license


----------------------------------------------------------------------

Comment By: Ton Voon (tonvoon)
Date: 2004-05-05 13:00

Message:
Logged In: YES 
user_id=664364

What do you suggest? It should be something like:

ps -eo 's uid ppid vsz rss pcpu comm args'

to get all the required information. Will need a head -2 output.


----------------------------------------------------------------------

Comment By: Mark Plaksin (happyzi)
Date: 2004-05-05 11:54

Message:
Logged In: YES 
user_id=115461

Thanks for the quick response :)

The recent change doesn't do the trick.  I tested with
today's CVS.

We run multiple PeopleSoft instances on a single machine. 
We want per-instance process checking and the only way to
tell which instance a process is for is by looking at the
arguments to the command.  For example, there is one
PSQRYSRV process for earch instance.  They show up in the
process table like "PSQRYSRV -C dom=INSTANCE_NAME".


----------------------------------------------------------------------

Comment By: Ton Voon (tonvoon)
Date: 2004-05-05 11:42

Message:
Logged In: YES 
user_id=664364

Mark,

CVS HEAD was recently changed for HP-UX (configure output should 
show HP-UX as the ps syntax). Does this work?

Ton

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=948667&group_id=29880




More information about the Devel mailing list