aboutsummaryrefslogtreecommitdiff
path: root/plugins-scripts/check_disk_smb.pl
diff options
context:
space:
mode:
authorGravatar Holger Weiss <holger@zedat.fu-berlin.de> 2010-04-11 09:39:24 +0200
committerGravatar Holger Weiss <holger@zedat.fu-berlin.de> 2010-04-11 09:39:24 +0200
commite4613410033dc24d9efe34013c8a35b16487af8f (patch)
tree17eb5ef14f30d2c6fcb4086839249867894df3f3 /plugins-scripts/check_disk_smb.pl
parent4bf27452ab4bffbfbf6597e0c74c7f1529d10e54 (diff)
downloadmonitoring-plugins-e4613410033dc24d9efe34013c8a35b16487af8f.tar.gz
Fix Debian bug #425129: SMB guest mode won't work
| The check_disk_smb plugin purports to support guest users, but it | doesn't work out, because it doesn't specify the -N command line | option to smbclient when no password is specified, making smbclient | stop and ask. [ http://bugs.debian.org/425129 ] (Fixed by Josip Rodin, forwarded by Jan Wagner.)
Diffstat (limited to 'plugins-scripts/check_disk_smb.pl')
-rwxr-xr-xplugins-scripts/check_disk_smb.pl1
1 files changed, 1 insertions, 0 deletions
diff --git a/plugins-scripts/check_disk_smb.pl b/plugins-scripts/check_disk_smb.pl
index 985fa961..022fa505 100755
--- a/plugins-scripts/check_disk_smb.pl
+++ b/plugins-scripts/check_disk_smb.pl
@@ -78,6 +78,7 @@ my $user = $1 if ($opt_u =~ /^([-_.A-Za-z0-9\\]+)$/);
($opt_p) || ($opt_p = shift) || ($opt_p = "");
my $pass = $1 if ($opt_p =~ /(.*)/);
+$pass = "-N" if ($opt_p eq "");
($opt_w) || ($opt_w = shift) || ($opt_w = 85);
my $warn = $1 if ($opt_w =~ /^([0-9]{1,2}\%?|100\%?|[0-9]+[kMG])$/);