Uploaded image for project: 'Observium'
  1. Observium
  2. OBS-1649

issue with WMI disk serials

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • None
    • Professional Edition
    • Poller

    Description

      If a Volume serial number begin with zero, the snmp polling seems to drop the leading zero, so the WMI polling will never find the volume, as it has a 'incorrect' storage_descr.

      Just got wmi storage poller to drop the leading zero, seemed easiest..

      Index: includes/polling/storage/wmi.inc.php
      ===================================================================
      — includes/polling/storage/wmi.inc.php (revision 7470)
      +++ includes/polling/storage/wmi.inc.php (working copy)
      @@ -18,7 +18,7 @@
      {
      echo(".");

      • $storage_name = $disk['DeviceID'] . "\\\\ Label:" . $disk['VolumeName'] . " Serial Number " . strtolower($disk['VolumeSerialNumber']);
        + $storage_name = $disk['DeviceID'] . "\\\\ Label:" . $disk['VolumeName'] . " Serial Number " . ltrim(strtolower($disk['VolumeSerialNumber']),'0');
        $storage_id = dbFetchCell("SELECT `storage_id` FROM `storage` WHERE `storage_descr`= ?", array($storage_name));
        $rrd_filename = "storage-host-resources-mib-" . $storage_name .".rrd";
        $used = $disk['Size'] - $disk['FreeSpace'];

      Attachments

        Activity

          People

            landy Mike Stupalov
            pxs Paul Semple
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: