Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-1015

"system.swap.in" and "system.swap.out" cannot treat LVM device

    XMLWordPrintable

    Details

    • Type: Incident report
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.6.5
    • Fix Version/s: 1.9.0 (alpha)
    • Component/s: Agent (G)
    • Labels:
      None
    • Environment:
      zabbix-1.6.5 from ZABBIX SIA.
      Linux 2.6 i386, Linux 2.6 x86_64

      Description

      "system.swap.in" and "system.swap.out" cannot treat LVM device.
      It returns ZBX_NOTSUPPORTED.
      Actually, following command return ZBX_NOTSUPPORTED.

      1. zabbix_agentd -t system.swap.in[mapper/VolGroup00-LogVol01,count]
        system.swap.in[mapper/VolGroup00-LogVol01,count] [m|ZBX_NOTSUPPORTED]
      2. zabbix_agentd -t system.swap.in[mapper/VolGroup00-LogVol01,sectors]
        system.swap.in[mapper/VolGroup00-LogVol01,sectors] [m|ZBX_NOTSUPPORTED]
      3. zabbix_agentd -t system.swap.out[mapper/VolGroup00-LogVol01,count]
        system.swap.out[mapper/VolGroup00-LogVol01,count] [m|ZBX_NOTSUPPORTED]
      4. zabbix_agentd -t system.swap.out[mapper/VolGroup00-LogVol01,sectors]
        system.swap.out[mapper/VolGroup00-LogVol01,sectors] [m|ZBX_NOTSUPPORTED]

      Maybe it also returns ZBX_NOTSUPPORTED with other device-mapper devices.

      This problem is due to following two reasons.
      (1) swapdev in function SYSTEM_SWAP_IN() and SYSTEM_SWAP_OUT() are too short to treat LVM device. It has only 10 char length.
      (2) Both "system.swap.in" and "system.swap.out" use function get_swap_stat() and get_swap_dev_stat().
      Function get_swap_stat() uses /proc/swap and /proc/swap returns LVM device name in format like "/dev/mapper/VolGroup00-LogVol01".
      Function get_swap_dev_stat() uses /proc/diskstats and /proc/diskstats returns LVM device name in format like "dm-1".
      Each function matchs user inputed device name and device name which come from /proc/swap or /proc/diskstats.
      As a result, any LVM devices are unmatched and zabbix returns ZBX_NOTSUPPORTED.

        Attachments

          Activity

            People

            Assignee:
            sasha Alexander Vladishev
            Reporter:
            tsuzuki Takanori Suzuki
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: