From 926645ce74a10b91686822bade08fa7b7282847a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn-Egil=20Dahlberg?= Date: Thu, 18 Jul 2013 17:16:48 +0200 Subject: os_mon: Fix freebsd diskspace queries Use 'df -k -l' to query FreeBSD about diskspace on local disks. Previously 'df' -k -t ufs' was used but this will not handle zfs disks. Just use '-l' instead of listing potential filesystems. --- lib/os_mon/src/disksup.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/os_mon') diff --git a/lib/os_mon/src/disksup.erl b/lib/os_mon/src/disksup.erl index 8c8bbe843a..24b4c4cce5 100644 --- a/lib/os_mon/src/disksup.erl +++ b/lib/os_mon/src/disksup.erl @@ -263,7 +263,7 @@ check_disk_space({unix, dragonfly}, Port, Threshold) -> Result = my_cmd("/bin/df -k -t ufs,hammer", Port), check_disks_solaris(skip_to_eol(Result), Threshold); check_disk_space({unix, freebsd}, Port, Threshold) -> - Result = my_cmd("/bin/df -k -t ufs", Port), + Result = my_cmd("/bin/df -k -l", Port), check_disks_solaris(skip_to_eol(Result), Threshold); check_disk_space({unix, openbsd}, Port, Threshold) -> Result = my_cmd("/bin/df -k -t ffs", Port), -- cgit v1.2.3 From 88b1630f8fd21047aa7c733af6ade78f7f162287 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B6rn-Egil=20Dahlberg?= Date: Thu, 18 Jul 2013 17:30:25 +0200 Subject: os_mon: Fix openbsd diskspace queries Use 'df -k -l' to query OpenBSD about diskspace on local disks. Same reasoning as for FreeBSD - additional filesystems without listing them all. --- lib/os_mon/src/disksup.erl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/os_mon') diff --git a/lib/os_mon/src/disksup.erl b/lib/os_mon/src/disksup.erl index 24b4c4cce5..278da26a20 100644 --- a/lib/os_mon/src/disksup.erl +++ b/lib/os_mon/src/disksup.erl @@ -266,7 +266,7 @@ check_disk_space({unix, freebsd}, Port, Threshold) -> Result = my_cmd("/bin/df -k -l", Port), check_disks_solaris(skip_to_eol(Result), Threshold); check_disk_space({unix, openbsd}, Port, Threshold) -> - Result = my_cmd("/bin/df -k -t ffs", Port), + Result = my_cmd("/bin/df -k -l", Port), check_disks_solaris(skip_to_eol(Result), Threshold); check_disk_space({unix, netbsd}, Port, Threshold) -> Result = my_cmd("/bin/df -k -t ffs", Port), -- cgit v1.2.3