From: Quentin Smith Date: Sat, 14 Mar 2009 15:39:26 +0000 (-0400) Subject: Be more cautious about removing munin plugins X-Git-Tag: 0.0.7^0 X-Git-Url: http://xvm.mit.edu/gitweb/invirt/packages/xvm-munin-config.git/commitdiff_plain/49147b8b79902535de106b20ac31d9dcba665ad0?ds=sidebyside Be more cautious about removing munin plugins svn path=/trunk/packages/xvm-munin-config/; revision=2248 --- diff --git a/debian/xvm-munin-host-config.postinst b/debian/xvm-munin-host-config.postinst index 1f64371..fc2de88 100755 --- a/debian/xvm-munin-host-config.postinst +++ b/debian/xvm-munin-host-config.postinst @@ -37,10 +37,10 @@ EOF # Install munin plugins that are now configured munin-node-configure --suggest --shell | sh - (cd /etc/munin/plugins; + (cd /etc/munin/plugins && for i in smart_*; do - if smartctl -i /dev/${i#smart_} | grep Device | grep EQLOGIC; then - rm -v $i; + if smartctl -i "/dev/${i#smart_}" | grep Device | grep EQLOGIC; then + rm -v "$i"; fi done)