diff options
author | Ton Voon <tonvoon@users.sourceforge.net> | 2008-02-28 16:21:59 +0000 |
---|---|---|
committer | Ton Voon <tonvoon@users.sourceforge.net> | 2008-02-28 16:21:59 +0000 |
commit | 9f3d864fd3e47d4e728b196b1b6948a8a5e47e4e (patch) | |
tree | ffaf70a0a09e40cf706f1362a01450f76e845d18 /configure.in | |
parent | f00e6a9676154eaac8aed140c49bde76e52d6cee (diff) | |
download | monitoring-plugins-9f3d864fd3e47d4e728b196b1b6948a8a5e47e4e.tar.gz |
Reverted check_procs for solaris back to using pst3 due to truncation
for argument fields using other methods
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1937 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 49 |
1 files changed, 41 insertions, 8 deletions
diff --git a/configure.in b/configure.in index 341add80..6d94582c 100644 --- a/configure.in +++ b/configure.in @@ -512,16 +512,49 @@ if test -n "$PS_COMMAND" && test -n "$PS_FORMAT" && test -n "$PS_COLS" && test - ac_cv_ps_cols="$PS_COLS" AC_MSG_RESULT([(command-line) $ac_cv_ps_command]) +dnl Now using the pst3/kmem hack for solaris systems to avoid truncation +elif test "$ac_cv_uname_s" = "SunOS"; then + # + # this is a very, very ugly hack, to hardcode the location for plugins + # + if test "$libexecdir" = '${exec_prefix}/libexec'; then + if test "$exec_prefix" = "NONE"; then + if test "$prefix" = "NONE"; then + pst3="$ac_default_prefix/libexec/pst3" + else + pst3="$prefix/libexec/pst3" + fi + else + pst3="$exec_prefix/libexec/pst3" + fi + else + pst3="$libexecdir/pst3" + fi + ac_cv_ps_command="$pst3" + ac_cv_ps_format="%s %d %d %d %d %d %f %s %n" + ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" + ac_cv_ps_cols=9 + AC_MSG_RESULT([using nagios-plugins internal ps command (pst3) for solaris]) + if test `isainfo -b` = 64 ; then + PST3CFLAGS="-m64" + AC_SUBST(PST3CFLAGS) + AC_MSG_NOTICE([using 64bit pst3]) + else + AC_MSG_NOTICE([using 32bit pst3]) + fi + EXTRAS_ROOT="$EXTRAS_ROOT pst3" + +dnl Removing this for the moment - Ton dnl Using /usr/ucb/ps on Solaris systems, to avoid truncation dnl Limitation that command name is not available -elif test "$ac_cv_uname_s" = "SunOS" && /usr/ucb/ps -alxwwn 2>/dev/null | \ - egrep -i ["^ *F +UID +PID +PPID +%C +PRI +NI +SZ +RSS +WCHAN +S +TT +TIME +COMMAND"] > /dev/null -then - ac_cv_ps_varlist="[&procuid,&procpid,&procppid,&procpcpu,&procvsz,&procrss,procstat,&pos]" - ac_cv_ps_command="/usr/ucb/ps -alxwwn" - ac_cv_ps_format=["%*s %d %d %d %d %*d %*d %d %d%*[ 0123456789abcdef]%[OSRZT]%*s %*s %n"] - ac_cv_ps_cols=8 - AC_MSG_RESULT([$ac_cv_ps_command]) +dnl elif test "$ac_cv_uname_s" = "SunOS" && /usr/ucb/ps -alxwwn 2>/dev/null | \ +dnl egrep -i ["^ *F +UID +PID +PPID +%C +PRI +NI +SZ +RSS +WCHAN +S +TT +TIME +COMMAND"] > /dev/null +dnl then +dnl ac_cv_ps_varlist="[&procuid,&procpid,&procppid,&procpcpu,&procvsz,&procrss,procstat,&pos]" +dnl ac_cv_ps_command="/usr/ucb/ps -alxwwn" +dnl ac_cv_ps_format=["%*s %d %d %d %d %*d %*d %d %d%*[ 0123456789abcdef]%[OSRZT]%*s %*s %n"] +dnl ac_cv_ps_cols=8 +dnl AC_MSG_RESULT([$ac_cv_ps_command]) dnl Some gnu/linux systems (debian for one) don't like -axwo and need axwo. dnl so test for this first... |