Skip block which won't support smart data

tags/zabbix-agent-addons-0.2.20-1
Daniel Berteaud 12 years ago
parent bb5e69ff30
commit 708cdf2747
  1. 2
      zabbix_scripts/disco_smart_sudo

@ -13,6 +13,8 @@ closedir($dh);
foreach my $block (@blocks){
my $removable = 0;
my $size = 1;
# Skip block we already know they won't support SMART
next if ($block =~ m/^(ram|loop|md|dm\-)\d+/);
if ( -e "/sys/block/$block/removable"){
open REMOVABLE, "/sys/block/$block/removable";
$removable = join "", <REMOVABLE>;

Loading…
Cancel
Save