diff --git a/mount/mount-lib.pl b/mount/mount-lib.pl
index 47e2c1452..ebcc6515a 100755
--- a/mount/mount-lib.pl
+++ b/mount/mount-lib.pl
@@ -359,7 +359,7 @@ foreach my $m (@mounted) {
($t, $f) = @$zp;
}
else {
- ($t, $f) = &mount::disk_space($m->[2], $m->[0]);
+ ($t, $f) = &disk_space($m->[2], $m->[0]);
}
if (($m->[2] eq "simfs" || $m->[2] eq "vzfs" ||
$m->[0] eq "/dev/vzfs" ||
@@ -370,8 +370,14 @@ foreach my $m (@mounted) {
}
$total += $t*1024;
$free += $f*1024;
+ my ($it, $if);
+ if (defined(&inode_space)) {
+ ($it, $if) = &inode_space($m->[2], $m->[0]);
+ }
push(@fs, { 'total' => $t*1024,
'free' => $f*1024,
+ 'itotal' => $it,
+ 'ifree' => $if,
'dir' => $m->[0],
'device' => $m->[1],
'type' => $m->[2] });
diff --git a/system-status/lang/en b/system-status/lang/en
index 744c48b9d..078723b4b 100644
--- a/system-status/lang/en
+++ b/system-status/lang/en
@@ -24,6 +24,8 @@ right_used2=$2 used, $1 guaranteed, $3 burstable
right_out=$1 of $2
right_fsfull=Warning! The $2 filesystem mounted at $1 has no free disk space!
right_fsnearly=Warning! The $2 filesystem mounted at $1 has only $3 of free disk space
+right_ifsfull=Warning! The filesystem mounted at $1 has no free inodes out of $2!
+right_ifsnearly=Warning! The filesystem mounted at $1 has only $3 of free inodes out of $2
right_quota=Disk usage and quota
right_header5=Account Information
right_uquota=Disk quota and usage
diff --git a/system-status/system_info.pl b/system-status/system_info.pl
index c5d68edd5..9fb0e8e1b 100644
--- a/system-status/system_info.pl
+++ b/system-status/system_info.pl
@@ -223,6 +223,24 @@ if ($info->{'disk_fs'} && &show_section('disk')) {
'level' => 'warn',
'warning' => $msg });
}
+ next if (!$fs->{'itotal'});
+ if ($fs->{'ifree'} == 0) {
+ my $msg = &text('right_ifsfull',
+ "$fs->{'dir'}",
+ $fs->{'itotal'});
+ push(@rv, { 'type' => 'warning',
+ 'level' => 'danger',
+ 'warning' => $msg });
+ }
+ elsif ($fs->{'free'}*1.0 / $fs->{'total'} < 0.01) {
+ my $msg = &text('right_ifsnearly',
+ "$fs->{'dir'}",
+ $fs->{'itotal'},
+ $fs->{'ifree'});
+ push(@rv, { 'type' => 'warning',
+ 'level' => 'warn',
+ 'warning' => $msg });
+ }
}
}