From a98944623f350b634f369502fd20eb51273cf81b Mon Sep 17 00:00:00 2001 From: Alan Robertson Date: Tue, 31 Jul 2007 13:21:26 -0600 Subject: [PATCH 01/10] LF bug # 1662 - massive heartbeat specfile update - to make it more usable --HG-- extra : convert_revision : 5f8f217f306a74404e2ed1f9ea771f6dd2a5b3fe --- configure.in | 78 ++++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 60 insertions(+), 18 deletions(-) diff --git a/configure.in b/configure.in index f2b32e9474..ff9254ba9e 100644 --- a/configure.in +++ b/configure.in @@ -227,23 +227,39 @@ libdir=`var "$libdir" "$exec_prefix/lib"` libexecdir=`var "$libexecdir" "$exec_prefix/libexec"` noarchlibdir=`var "$noarchlibdir" "$prefix/lib"` -for var in libdir libexecdir -do - dir=`eval echo '${'${var}'}'` - case $dir in - *64) if - test ! -d "$dir" - then - newdir=`echo "$dir" | sed 's%64$%%'` - if - test -d "$newdir" - then - eval $var="$newdir" - AC_MSG_WARN([$var value now set to $newdir since $dir doesn't exist]) - fi - fi;; - esac -done + + +LDD=ldd + +AC_MSG_CHECKING(for proper library directory suffix) +tmpdir=/tmp +tmpCfile=${tmpdir}/$$test.c +tmpOutfile=${tmpdir}/$$test +echo 'int main(int argc, char** argv) { return(1);}' >$tmpCfile +if + cc ${tmpCfile} -o ${tmpOutfile} +then + LIBC=`${LDD} ${tmpOutfile} | grep libc | sed -e 's%.*=> *%%' -e 's% .*$%%'` + LibCdir=`dirname $LIBC` + LibDirSuffix=`basename $LibCdir` + AC_MSG_RESULT($LibDirSuffix) + rm -f $tmpCfile $tmpOutfile +else + AC_MSG_ERROR([Cannot Compile trivial C program]) +fi + +case $libdir in + */$LibDirSuffix) : Cool ;; + *) : Uh Oh... + libdir=`dirname $libdir`/$LibDirSuffix + AC_MSG_WARN([Overriding libdir to: $libdir]);; +esac +case $libexecdir in + */$LibDirSuffix) : Cool ;; + *) : Uh Oh... + libexecdir=`dirname $libexecdir`/$LibDirSuffix + AC_MSG_WARN([Overriding libexecdir to: $libexecdir]);; +esac for j in exec_prefix bindir sbindir datadir sysconfdir localstatedir \ includedir oldincludedir mandir docdir libdir noarchlibdir @@ -256,6 +272,10 @@ do fi done +dnl ************************************************************************ +dnl Test to see whether library directories should be lib or lib64... +dnl ************************************************************************ + dnl The GNU conventions for installation directories don't always dnl sit well with this software. In particular, GNU's stated: dnl @@ -398,6 +418,15 @@ AC_SUBST(docdir) dnl We use this in the RPM specfile... AC_SUBST(ac_configure_args) +cleaned_configure_args="" +for j in ${ac_configure_args} +do + case $j in + *--libdir=*|*--libexecdir=*) ;; + *) cleaned_configure_args="$cleaned_configure_args $j";; + esac +done +AC_SUBST(cleaned_configure_args) dnl ************************************************************************* PATH="$PATH:/sbin:/usr/sbin:/usr/local/sbin:/usr/local/bin" @@ -533,7 +562,6 @@ fi rm -f $F AM_CONDITIONAL(NONROOT_CHOWN, test "$nonroot_chown" = yes ) - dnl ************************************************************************ dnl checks for libraries dnl Needed for libnet test. @@ -1170,6 +1198,18 @@ dnl AC_CHECK_LIB(crypto, CRYPTO_free, CRYPTOLIB="-lcrypto",) AC_SUBST(CRYPTOLIB) +dnl *************************************************************************** +dnl Enable distro-style RPMs +dnl *************************************************************************** +AC_ARG_ENABLE([distro-rpm], + [ --enable-distro-rpm Enable distro-style RPMs + [default=no]], [], [enable_distro_rpm=no]) +case $enable_distro_rpm in + [Yy][Ee][Ss]*) DISTRO_STYLE_RPMS=1;; + *) DISTRO_STYLE_RPMS=0;; +esac +AC_SUBST(DISTRO_STYLE_RPMS) + dnl *************************************************************************** dnl TIPC communication module dnl *************************************************************************** @@ -2859,6 +2899,7 @@ resources/Makefile \ resources/heartbeat/Filesystem \ resources/heartbeat/hto-mapfuncs \ resources/heartbeat/ICP \ + resources/heartbeat/ids \ resources/heartbeat/IPaddr \ resources/heartbeat/IPaddr2 \ resources/heartbeat/IPsrcaddr \ @@ -2951,6 +2992,7 @@ AC_MSG_RESULT([ CC_WARNINGS = "${CC_WARNINGS}"]) AC_MSG_RESULT([ Mangled CFLAGS = "${CFLAGS}"]) AC_MSG_RESULT([ Libraries = "${LIBS}"]) AC_MSG_RESULT([ RPATH enabled = "${enable_rpath}"]) +AC_MSG_RESULT([ Distro-style RPMs = "${enable_distro_rpm}"]) AC_MSG_RESULT([ ]) AC_MSG_RESULT([Note: If you use the 'make install' method for installation you]) From a74cf3b9423541bb9c69c74954afd19a6dcae127 Mon Sep 17 00:00:00 2001 From: Alan Robertson Date: Tue, 31 Jul 2007 13:26:13 -0600 Subject: [PATCH 02/10] Incremented version number - to avoid confusion. --HG-- extra : convert_revision : 859a80bb59c71e486ed69ae01ecf8a6e5786dd01 --- configure.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.in b/configure.in index ff9254ba9e..368da0393b 100644 --- a/configure.in +++ b/configure.in @@ -39,7 +39,7 @@ AC_ARG_WITH(hapkgversion, ) if test -z "$HAPKGVERSION" ; then - HAPKGVERSION="2.1.2" + HAPKGVERSION="2.1.3-pre" fi AM_INIT_AUTOMAKE(heartbeat, $HAPKGVERSION) From 2c589d5d5b26a6d1ea756c0de5c2ffff8da891b6 Mon Sep 17 00:00:00 2001 From: Alan Robertson Date: Tue, 31 Jul 2007 13:34:26 -0600 Subject: [PATCH 03/10] Made the version number really 2.1.3 to keep from confusing RPM --HG-- extra : convert_revision : d45731dc1acf39b026db3c95cc80bcf46f9c3a99 --- configure.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.in b/configure.in index 368da0393b..fe3a8f7ca2 100644 --- a/configure.in +++ b/configure.in @@ -39,7 +39,7 @@ AC_ARG_WITH(hapkgversion, ) if test -z "$HAPKGVERSION" ; then - HAPKGVERSION="2.1.3-pre" + HAPKGVERSION="2.1.3" fi AM_INIT_AUTOMAKE(heartbeat, $HAPKGVERSION) From a6e3a74c68313fce06d3a321b0c5f0935db72f18 Mon Sep 17 00:00:00 2001 From: Alan Robertson Date: Tue, 31 Jul 2007 16:03:33 -0600 Subject: [PATCH 04/10] Merged in my ids fix with the ids fix from Andrew. --HG-- extra : convert_revision : 5f563158558cf326ea4960f4442514fc78dda252 --- configure.in | 1 - 1 file changed, 1 deletion(-) diff --git a/configure.in b/configure.in index 7ec8aff893..fe3a8f7ca2 100644 --- a/configure.in +++ b/configure.in @@ -2898,7 +2898,6 @@ resources/Makefile \ resources/heartbeat/db2 \ resources/heartbeat/Filesystem \ resources/heartbeat/hto-mapfuncs \ - resources/heartbeat/ids \ resources/heartbeat/ICP \ resources/heartbeat/ids \ resources/heartbeat/IPaddr \ From 87a50ec7b7dff37b8cc13a033406ca294124192e Mon Sep 17 00:00:00 2001 From: Alan Robertson Date: Wed, 1 Aug 2007 18:11:20 -0600 Subject: [PATCH 05/10] More updates to the spec file. --HG-- extra : convert_revision : 77167e8d0f7885fb72d11d734aaf58db6408cd21 --- configure.in | 87 +++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 80 insertions(+), 7 deletions(-) diff --git a/configure.in b/configure.in index fe3a8f7ca2..97ac5a2074 100644 --- a/configure.in +++ b/configure.in @@ -1152,13 +1152,85 @@ check_snmp_libs () LIBS="$OLDLIBS" } +SNMPLIBSET="" if test "$ENABLE_SNMP" = "yes"; then check_snmp_libs $SNMPLIB + SNMPLIBSET="$SNMPLIB" fi if test "$enable_snmp_subagent" = "yes"; then check_snmp_libs $SNMPAGENTLIB + SNMPLIBSET="$SNMPLIBSET $SNMPAGENTLIB" fi +dnl +dnl There are more sophisticated and general ways of doing this, that +dnl are more general - but this is better than nothing. +dnl +dnl The right procedure would be to locate the libraries that we've been told +dnl are needed, dnl then do an RPM query on each of these libraries +dnl to find out what package owns the library (file) +dnl That'll be a good project for some long, cold winter evening. +dnl +dnl Some food for thought from the 'ld' manual page: +dnl +dnl The linker uses the following search paths to locate required shared libraries. +dnl +dnl Ignore steps 1-2, because they involve rpath options (which we don't care about) +dnl +dnl 3. On an ELF system, if the -rpath and "rpath-link" options were not used, search the contents of the environment variable +dnl "LD_RUN_PATH". It is for the native linker only. +dnl +dnl 4. On SunOS, if the -rpath option was not used, search any directories specified using -L options. +dnl +dnl 5. For a native linker, the contents of the environment variable "LD_LIBRARY_PATH". +dnl +dnl 6. For a native ELF linker, the directories in "DT_RUNPATH" or "DT_RPATH" of a shared library are searched for shared +dnl libraries needed by it. The "DT_RPATH" entries are ignored if "DT_RUNPATH" entries exist. +dnl +dnl 7. The default directories, normally /lib and /usr/lib. +dnl +dnl 8. For a native linker on an ELF system, if the file /etc/ld.so.conf exists, the list of directories found in that file. +dnl +dnl If the required shared library is not found, the linker will issue a warning and continue with the link. +dnl +dnl +libs2packages() { + for arg + do + case $arg in + -ldl|-lm|-L*) ;; + -lcrypto) echo openssl;; + -lnetsnmp) echo net-snmp;; + -lsnmp) echo net-snmp;; + -lnetsnmpagent) echo net-snmp;; + -lnetsnmphelpers) echo net-snmp;; + -lnetsnmpmibs) echo net-snmp;; + -lrpm) echo rpm;; + -lrpmio) echo rpm;; + -lpopt) echo popt;; + -lsensors) echo sensors;; + -lwrap) echo tcpd;; + -lz) echo zlib;; + *) AC_MSG_WARN([SNMP library $arg not included in RPM build dependencies]) + esac + done +} + +AC_MSG_CHECKING(What packages are needed for SNMP at compile time for RPMs); +AC_MSG_RESULT(SNMPLIBSET is $SNMPLIBSET) +PKGSET=`libs2packages $SNMPLIBSET | tr ' ' '\012' | sort -u` +PKGSET=`echo $PKGSET` +AC_MSG_RESULT(PKGSET is $PKGSET) + +if test -z "$PKGSET"; then + SNMP_RPM_BUILD_REQUIRES="BuildRequires: ${CC}" +else + SNMP_RPM_BUILD_REQUIRES="BuildRequires: $PKGSET" +fi +AC_MSG_RESULT($SNMP_RPM_BUILD_REQUIRES) + +AC_SUBST(SNMP_RPM_BUILD_REQUIRES) + AC_ARG_WITH(mibsdir, [ --with-miBsdir=DIR directory for mib files. ], [ MIBS_DIR="$withval" ]) @@ -1175,7 +1247,7 @@ if test "x${enable_snmp_subagent}" = "xyes" -a "X${MIBS_DIR}" = "X"; then AC_MSG_ERROR(Could not find mibs directory, please specify with --with-mibsdir); fi - AC_MSG_RESULT($MIBS_DIR); + AC_MSG_RESULT($MIBS_DIR) fi AC_SUBST(MIBS_DIR) @@ -1187,9 +1259,10 @@ AM_CONDITIONAL(USE_APC_SNMP, test "$ENABLE_SNMP" = "yes") AM_CONDITIONAL(SNMP_SUBAGENT_BUILD, test "x${enable_snmp_subagent}" = "xyes") -if test x"$VERSION" \> x"1.9"; then - AC_DEFINE(HAVE_NEW_HB_API, 1, [have new heartbeat api]) -fi +# +# We've had this new API for a very long time +# +AC_DEFINE(HAVE_NEW_HB_API, 1, [have new heartbeat api]) dnl dnl On many systems libcrypto is needed when linking against libsnmp. @@ -1205,8 +1278,8 @@ AC_ARG_ENABLE([distro-rpm], [ --enable-distro-rpm Enable distro-style RPMs [default=no]], [], [enable_distro_rpm=no]) case $enable_distro_rpm in - [Yy][Ee][Ss]*) DISTRO_STYLE_RPMS=1;; - *) DISTRO_STYLE_RPMS=0;; + yes) DISTRO_STYLE_RPMS=1;; + *) DISTRO_STYLE_RPMS=0;; esac AC_SUBST(DISTRO_STYLE_RPMS) @@ -2469,7 +2542,7 @@ if test "x${enable_mgmt}" != "xno"; then AC_DEFINE_UNQUOTED(MGMT_ENABLED, 1, Define to 1 if the mgmt-daemon and friends are enabled.) dnl If this system might be RPM-based, then adjust some RPM-build details if test x"${RPM}" != x""; then -dnl FIXME: a flawy solution but no better one now +dnl FIXME: a flawed solution but no better one now if rpm -q python-gtk > /dev/null; then RPM_MGMT_RUNTIME_REQUIRES="libglade2, python-gtk"; else From dfde35bc0bef75ebdabdb5e4e401558987c5c27f Mon Sep 17 00:00:00 2001 From: Dejan Muhamedagic Date: Mon, 20 Aug 2007 17:40:24 +0200 Subject: [PATCH 06/10] configure.in: fix for platforms with libc in /lib/tls The changeset 5f8f217f306a introduced looking for a "proper library suffix" probably in order to deal better with 64-bit platforms (it's the one in /usr/lib/heartbeat for example). However, it fails in case libc is linked from /lib/tls/libc.so, producing "tls" as a library suffix, which is obviously wrong. --HG-- extra : convert_revision : 93d093a018516fd802435c2d4b17f340a1c570d9 --- configure.in | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/configure.in b/configure.in index 224462c498..9c66bd7abb 100644 --- a/configure.in +++ b/configure.in @@ -240,8 +240,7 @@ if cc ${tmpCfile} -o ${tmpOutfile} then LIBC=`${LDD} ${tmpOutfile} | grep libc | sed -e 's%.*=> *%%' -e 's% .*$%%'` - LibCdir=`dirname $LIBC` - LibDirSuffix=`basename $LibCdir` + LibDirSuffix=`echo $LIBC | awk -F/ '{print $2}'` AC_MSG_RESULT($LibDirSuffix) rm -f $tmpCfile $tmpOutfile else From 61b1de81348745e3d4d5a2f67a03872d60a3e4ad Mon Sep 17 00:00:00 2001 From: Alan Robertson Date: Thu, 23 Aug 2007 08:06:34 -0600 Subject: [PATCH 07/10] Put in a number of small fixes to make fedora packages make correctly... --HG-- extra : convert_revision : 9581cbd806086dcd016d4dfe2de524128c508ee1 --- configure.in | 85 +++++++++++++++++++++++++++++++++++----------------- 1 file changed, 57 insertions(+), 28 deletions(-) diff --git a/configure.in b/configure.in index 224462c498..f15ed24494 100644 --- a/configure.in +++ b/configure.in @@ -230,6 +230,16 @@ noarchlibdir=`var "$noarchlibdir" "$prefix/lib"` LDD=ldd +dnl Which C compiler? +dnl Defaults to GNU C compiler if available. +dnl Always tries to set the compiler to ANSI C via options (AM) +dnl Can force other with environment variable "CC". +AC_PROG_CC +AC_PROG_CC_STDC + +dnl ************************************************************************ +dnl Test to see whether library directories should be lib or lib64... +dnl ************************************************************************ AC_MSG_CHECKING(for proper library directory suffix) tmpdir=/tmp @@ -237,19 +247,37 @@ tmpCfile=${tmpdir}/$$test.c tmpOutfile=${tmpdir}/$$test echo 'int main(int argc, char** argv) { return(1);}' >$tmpCfile if - cc ${tmpCfile} -o ${tmpOutfile} + ${CC} ${tmpCfile} -o ${tmpOutfile} then LIBC=`${LDD} ${tmpOutfile} | grep libc | sed -e 's%.*=> *%%' -e 's% .*$%%'` LibCdir=`dirname $LIBC` LibDirSuffix=`basename $LibCdir` - AC_MSG_RESULT($LibDirSuffix) rm -f $tmpCfile $tmpOutfile else AC_MSG_ERROR([Cannot Compile trivial C program]) fi +# +# The code above doesn't work right everywhere (like Fedora) +# +case ${LibDirSuffix} in + lib*) : Cool;; + *) : Sigh... + case `file -L /bin/sh` in + *64-bit*) LibDirSuffix=lib64;; + *32-bit*) LibDirSuffix=lib;; + *) LibDirSuffix=lib;; + esac;; +esac +# +# This may not yet be quite right for PPC where the default +# is to produce 32-bit binaries, even though the OS is 64-bit +# or for that matter for system Z, But, it's a lot better than +# it used to be. +# +AC_MSG_RESULT($LibDirSuffix) case $libdir in - */$LibDirSuffix) : Cool ;; + */*${LibDirSuffix}) : Cool ;; *) : Uh Oh... libdir=`dirname $libdir`/$LibDirSuffix AC_MSG_WARN([Overriding libdir to: $libdir]);; @@ -272,9 +300,6 @@ do fi done -dnl ************************************************************************ -dnl Test to see whether library directories should be lib or lib64... -dnl ************************************************************************ dnl The GNU conventions for installation directories don't always dnl sit well with this software. In particular, GNU's stated: @@ -379,7 +404,7 @@ AC_DEFINE_UNQUOTED(HA_LOGDAEMON_IPC, "$HA_LOGDAEMON_IPC", Logging Daemon IPC soc dnl This IS a default but we should make sure we can override it for any dnl odd OS requirements. -HA_VARLOGDIR="/var/log" +HA_VARLOGDIR="${localstatedir}/log" AC_SUBST(HA_VARLOGDIR) AC_DEFINE_UNQUOTED(HA_VARLOGDIR,"$HA_VARLOGDIR", var log directory) @@ -433,12 +458,6 @@ PATH="$PATH:/sbin:/usr/sbin:/usr/local/sbin:/usr/local/bin" export PATH dnl checks for programs dnl -dnl Which C compiler? -dnl Defaults to GNU C compiler if available. -dnl Always tries to set the compiler to ANSI C via options (AM) -dnl Can force other with environment variable "CC". -AC_PROG_CC -AC_PROG_CC_STDC AC_PROG_YACC AC_DECL_YYTEXT AM_PROG_LEX @@ -1188,29 +1207,39 @@ libs2packages() { for arg do case $arg in - -ldl|-lm|-L*) ;; - -lcrypto) echo openssl;; - -lnetsnmp) echo net-snmp;; - -lsnmp) echo net-snmp;; - -lnetsnmpagent) echo net-snmp;; - -lnetsnmphelpers) echo net-snmp;; - -lnetsnmpmibs) echo net-snmp;; - -lrpm) echo rpm;; - -lrpmio) echo rpm;; - -lpopt) echo popt;; - -lsensors) echo sensors;; - -lwrap) echo tcpd;; - -lz) echo zlib;; + -ldl|-lm|-L*|-lc|-lpthread|-lnsl) ;; + -lresolv|-lcrypt|-lutil|-Wl,-E|-wL,-rpath) ;; + -lcrypto) echo openssl ;; + -lnetsnmp) echo net-snmp ;; + -lsnmp) echo net-snmp ;; + -lnetsnmpagent) echo net-snmp ;; + -lnetsnmphelpers) echo net-snmp ;; + -lnetsnmpmibs) echo net-snmp ;; + -lrpm) echo rpm ;; + -lrpmio) echo rpm ;; + -lpopt) echo popt ;; + -lsensors) case $host_vendor in + suse|SUSE|SuSE) + echo sensors;; + *) echo lm_sensors + esac ;; + -lwrap) case $host_vendor in + suse|SUSE|SuSE) + echo tcpd;; + *) echo tcp_wrappers;; + esac ;; + -lz) echo zlib ;; + -lperl|-l/*perl*/auto/DynaLoader/DynaLoader*) + echo perl ;; *) AC_MSG_WARN([SNMP library $arg not included in RPM build dependencies]) esac done } AC_MSG_CHECKING(What packages are needed for SNMP at compile time for RPMs); -AC_MSG_RESULT(SNMPLIBSET is $SNMPLIBSET) PKGSET=`libs2packages $SNMPLIBSET | tr ' ' '\012' | sort -u` PKGSET=`echo $PKGSET` -AC_MSG_RESULT(PKGSET is $PKGSET) +AC_MSG_RESULT($PKGSET) if test -z "$PKGSET"; then SNMP_RPM_BUILD_REQUIRES="BuildRequires: ${CC}" From a050486dcd2e32e735c333a0d39266f635012014 Mon Sep 17 00:00:00 2001 From: Alan Robertson Date: Thu, 23 Aug 2007 20:12:00 -0600 Subject: [PATCH 08/10] LF bug # 1692 - monitoring fails for apache OCF resource. Put in simple fix to apache resource agent monitoring from Sebastian Reitenbach --HG-- extra : convert_revision : a245a85222cdddfbc407c62076eb1bac5bbe5af4 --- heartbeat/apache | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/heartbeat/apache b/heartbeat/apache index d105b2ad4b..2d5a8af437 100644 --- a/heartbeat/apache +++ b/heartbeat/apache @@ -34,9 +34,9 @@ # OCF_RESKEY_options # OCF_RESKEY_testregex -HA_VARRUNDIR=${HA_VARRUN} . ${OCF_ROOT}/resource.d/heartbeat/.ocf-shellfuncs +HA_VARRUNDIR=${HA_VARRUN} ####################################################################### # From e4cb6c9dfd2fd3cf211969239431701964f0d297 Mon Sep 17 00:00:00 2001 From: Alan Robertson Date: Thu, 23 Aug 2007 22:17:27 -0600 Subject: [PATCH 09/10] Changed the specfile so that it uses only the correct name for python/gtk package according to the distro --HG-- extra : convert_revision : 1692e3bcbc0fd76cb72a01a34ebe5afcbd3c258e --- configure.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/configure.in b/configure.in index 46ddf9bdf6..22fbd28ce5 100644 --- a/configure.in +++ b/configure.in @@ -263,6 +263,7 @@ then case $LibDirSuffix in unknown) LibDirSuffix=`basename $LibCdir`;; esac + OutFileType=`file $tmpOutfile` rm -f $tmpCfile $tmpOutfile else AC_MSG_ERROR([Cannot Compile trivial C program]) @@ -271,9 +272,9 @@ fi # The code above doesn't work right everywhere (like Fedora) # case ${LibDirSuffix} in - lib*) : Cool;; + *lib*) : Cool;; *) : Sigh... - case `file -L /bin/sh` in + case $OutFileType in *64-bit*) LibDirSuffix=lib64;; *32-bit*) LibDirSuffix=lib;; *) LibDirSuffix=lib;; From 81f165e0dd0311ba2bf56c8a141f61aa84271873 Mon Sep 17 00:00:00 2001 From: Dejan Muhamedagic Date: Fri, 24 Aug 2007 15:14:25 +0200 Subject: [PATCH 10/10] RA apache: drop annoying messages if no configuration files are found --HG-- extra : convert_revision : 3a66bd7eb780482630a07ed6600fb29fdb48120d --- heartbeat/apache | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/heartbeat/apache b/heartbeat/apache index 2d5a8af437..1dc8495c55 100644 --- a/heartbeat/apache +++ b/heartbeat/apache @@ -128,7 +128,7 @@ apachecat() { close(cmd); } function listfiles(pattern, cmd,f) { - cmd="ls "pattern; + cmd="ls "pattern" 2>/dev/null"; while( ( cmd | getline f ) > 0 ) { printfile(f); }