summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--configure.in10
1 files changed, 7 insertions, 3 deletions
diff --git a/configure.in b/configure.in
index c9a9615..dc5f281 100644
--- a/configure.in
+++ b/configure.in
@@ -871,6 +871,10 @@ else
871 echo "** Could not find mailq or eqivalent" 871 echo "** Could not find mailq or eqivalent"
872fi 872fi
873 873
874dnl SWAP info required is amount allocated/available and amount free
875dnl The plugin works through all the swap devices and adds up the total swap
876dnl available.
877
874dnl dunno why this does not work below - use hack (kbd) 878dnl dunno why this does not work below - use hack (kbd)
875dnl fine on linux, broken on solaris 879dnl fine on linux, broken on solaris
876dnl if /bin/test -e "/proc/meminfo" 880dnl if /bin/test -e "/proc/meminfo"
@@ -901,7 +905,7 @@ then
901 echo " using Solaris format" 905 echo " using Solaris format"
902 fi 906 fi
903 EXTRAS="$EXTRAS check_swap" 907 EXTRAS="$EXTRAS check_swap"
904elif [swapinfo -k 2>&1 | egrep -i "Device" >/dev/null] 908elif [swapinfo -k 2>&1 | egrep -i "^Device" >/dev/null]
905then 909then
906 echo "found swapinfo command" 910 echo "found swapinfo command"
907 AC_DEFINE(HAVE_SWAP,1,[Define if swap/swapinfo command is found]) 911 AC_DEFINE(HAVE_SWAP,1,[Define if swap/swapinfo command is found])
@@ -913,11 +917,11 @@ then
913 echo " using FreeBSD format" 917 echo " using FreeBSD format"
914 fi 918 fi
915 EXTRAS="$EXTRAS check_swap" 919 EXTRAS="$EXTRAS check_swap"
916elif [swapinfo -d 2>/dev/null | egrep -i "^TYPE +AVAIL +USED +FREE" >/dev/null] 920elif [swapinfo -dfM 2>/dev/null | egrep -i "^TYPE +AVAIL +USED +FREE" >/dev/null]
917then 921then
918 AC_DEFINE(HAVE_SWAP,1,[Define if swap/swapinfo command is found]) 922 AC_DEFINE(HAVE_SWAP,1,[Define if swap/swapinfo command is found])
919 AC_PATH_PROG(PATH_TO_SWAP,swapinfo) 923 AC_PATH_PROG(PATH_TO_SWAP,swapinfo)
920 AC_DEFINE_UNQUOTED(SWAP_COMMAND,"/bin/sh '$PATH_TO_SWAP -d | /bin/tail -l +2'",[Path to swap/swapinfo binary, with any args]) 924 AC_DEFINE_UNQUOTED(SWAP_COMMAND,"$PATH_TO_SWAP -dfM",[Path to swap/swapinfo binary, with any args])
921 AC_DEFINE_UNQUOTED(SWAP_FORMAT,["%*s %d %*d %d"],[Format string for parsing swap output ]) 925 AC_DEFINE_UNQUOTED(SWAP_FORMAT,["%*s %d %*d %d"],[Format string for parsing swap output ])
922 echo " using HP-UX format HP-UX" 926 echo " using HP-UX format HP-UX"
923fi 927fi