Search Exchange
Search All Sites
Nagios Live Webinars
Let our experts show you how Nagios can help your organization.Login
Directory Tree
Directory
rdmarsh
byrdmarsh, October 11, 2016
Due to the "grep nfs" part it has a bug if your hostname has the letters "nfs" in it, and I guess the same applies for vg, lv or mount names as well.
Here's a patch:
- Linux ) NFS_MOUNTS=`egrep -v '(^#)' /etc/fstab | grep nfs | awk '{print $2}'`;;
+ Linux ) NFS_MOUNTS=`awk '!/^(\s+)#/ && /(\s+)nfs(\s+)/ {print $2}' /etc/fstab`;;
Here's a patch:
- Linux ) NFS_MOUNTS=`egrep -v '(^#)' /etc/fstab | grep nfs | awk '{print $2}'`;;
+ Linux ) NFS_MOUNTS=`awk '!/^(\s+)#/ && /(\s+)nfs(\s+)/ {print $2}' /etc/fstab`;;