Example #1
0
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (C) 2019 tribe29 GmbH - License: GNU General Public License v2
# This file is part of Checkmk (https://checkmk.com). It is subject to the terms and
# conditions defined in the file COPYING, which is part of this source code package.

# type: ignore

from cmk.base.plugins.agent_based.esx_vsphere_vm import parse_esx_vsphere_vm

checkname = "esx_vsphere_vm"

parsed = parse_esx_vsphere_vm([
    [
        "snapshot.rootSnapshotList", "732", "1594041788", "poweredOn",
        "FransTeil2"
    ],
    ["time_reference", "1594096464"],
])

discovery = {
    "cpu": [],
    "datastores": [],
    "guest_tools": [],
    "heartbeat": [],
    "mem_usage": [],
    "mounted_devices": [],
    "name": [],
    "running_on": [],
    "snapshots": [(None, {})],
    "snapshots_summary": [(None, {})],
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (C) 2019 tribe29 GmbH - License: GNU General Public License v2
# This file is part of Checkmk (https://checkmk.com). It is subject to the terms and
# conditions defined in the file COPYING, which is part of this source code package.

# type: ignore

from cmk.base.plugins.agent_based.esx_vsphere_vm import parse_esx_vsphere_vm

checkname = "esx_vsphere_vm"

parsed = parse_esx_vsphere_vm(
    [
        ["snapshot.rootSnapshotList", "732", "1594041788", "poweredOn", "FransTeil2"],
    ]
)

discovery = {
    "cpu": [],
    "datastores": [],
    "guest_tools": [],
    "heartbeat": [],
    "mem_usage": [],
    "mounted_devices": [],
    "name": [],
    "running_on": [],
    "snapshots": [(None, {})],
    "snapshots_summary": [(None, {})],
}
Example #3
0
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (C) 2019 tribe29 GmbH - License: GNU General Public License v2
# This file is part of Checkmk (https://checkmk.com). It is subject to the terms and
# conditions defined in the file COPYING, which is part of this source code package.

# yapf: disable
# type: ignore

from cmk.base.plugins.agent_based.esx_vsphere_vm import parse_esx_vsphere_vm

checkname = 'esx_vsphere_vm'

parsed = parse_esx_vsphere_vm([[
    'snapshot.rootSnapshotList', '1', '1363596734', 'poweredOff',
    '20130318_105600_snapshot_LinuxI|2', '1413977827', 'poweredOn', 'LinuxI', 'Testsnapshot'
]])

discovery = {
    'cpu': [],
    'datastores': [],
    'guest_tools': [],
    'heartbeat': [],
    'mem_usage': [],
    'mounted_devices': [],
    'name': [],
    'running_on': [],
    'snapshots': [(None, {})]
}

checks = {
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (C) 2019 tribe29 GmbH - License: GNU General Public License v2
# This file is part of Checkmk (https://checkmk.com). It is subject to the terms and
# conditions defined in the file COPYING, which is part of this source code package.

# type: ignore

from cmk.base.plugins.agent_based.esx_vsphere_vm import parse_esx_vsphere_vm

checkname = 'esx_vsphere_vm'

parsed = parse_esx_vsphere_vm([
    [
        'snapshot.rootSnapshotList', '732', '1594041788', 'poweredOn',
        'FransTeil2'
    ],
    ['time_reference', '1594096464'],
])

discovery = {
    'cpu': [],
    'datastores': [],
    'guest_tools': [],
    'heartbeat': [],
    'mem_usage': [],
    'mounted_devices': [],
    'name': [],
    'running_on': [],
    'snapshots': [(None, {})],
    'snapshots_summary': [(None, {})],
Example #5
0
# -*- coding: utf-8 -*-
# Copyright (C) 2019 tribe29 GmbH - License: GNU General Public License v2
# This file is part of Checkmk (https://checkmk.com). It is subject to the terms and
# conditions defined in the file COPYING, which is part of this source code package.

# yapf: disable
# type: ignore

from cmk.base.plugins.agent_based.esx_vsphere_vm import parse_esx_vsphere_vm

checkname = 'esx_vsphere_vm'

freeze_time = "2019-06-22 14:37"

parsed = parse_esx_vsphere_vm([
    ['snapshot.rootSnapshotList', '154', '1560322675', 'poweredOn', 'VM-Snapshot', '12.06.2019',
     '10:56', 'UTC+02:00'],
])

discovery = {
    'cpu': [],
    'datastores': [],
    'guest_tools': [],
    'heartbeat': [],
    'mem_usage': [],
    'mounted_devices': [],
    'name': [],
    'running_on': [],
    'snapshots': [(None, {})],
    'snapshots_summary': [(None, {})],
}
Example #6
0
parsed = parse_esx_vsphere_vm([
    [u'config.datastoreUrl',
         u'maintenanceMode',
         u'normal|url',
         u'ds:///vmfs/volumes/vsan:5239d5cbf4c95b8c-5977b0e019a35313/|uncommitted',
         u'9278987431936|name',
         u'vsanDatastore|type',
         u'vsan|accessible',
         u'true|capacity',
         u'31686121226240|freeSpace',
         u'20938787651584'],
        [u'config.hardware.device',
         u'virtualDeviceType',
         u'VirtualVmxnet3|label',
         u'Network',
         u'adapter',
         u'1|summary',
         u'DVSwitch:',
         u'49',
         u'76',
         u'2d',
         u'50',
         u'6a',
         u'ee',
         u'f6',
         u'2b-88',
         u'3f',
         u'37',
         u'1c',
         u'6c',
         u'44',
         u'cd',
         u'29|startConnected',
         u'true|allowGuestControl',
         u'true|connected',
         u'true|status',
         u'ok'],
        [u'config.hardware.memoryMB', u'16384'],
        [u'config.hardware.numCPU', u'4'],
        [u'config.hardware.numCoresPerSocket', u'4'],
        [u'config.template', u'false'],
        [u'guest.toolsVersion', u'2147483647'],
        [u'guest.toolsVersionStatus', u'guestToolsUnmanaged'],
        [u'guestHeartbeatStatus', u'green'],
        [u'name', u'scwagprc01.widag.local'],
        [u'runtime.host', u'zh1wagesx02.widag.local'],
        [u'runtime.powerState', u'poweredOn'],
        [u'summary.guest.hostName', u'ntnx-10-78-142-100-a-cvm'],
        [u'summary.quickStats.balloonedMemory', u'0'],
        [u'summary.quickStats.compressedMemory', u'0'],
        [u'summary.quickStats.consumedOverheadMemory', u'78'],
        [u'summary.quickStats.distributedCpuEntitlement', u'2936'],
        [u'summary.quickStats.distributedMemoryEntitlement', u'8049'],
        [u'summary.quickStats.guestMemoryUsage', u'4423'],
        [u'summary.quickStats.hostMemoryUsage', u'16354'],
        [u'summary.quickStats.overallCpuDemand', u'3479'],
        [u'summary.quickStats.overallCpuUsage', u'3479'],
        [u'summary.quickStats.privateMemory', u'16276'],
        [u'summary.quickStats.sharedMemory', u'102'],
        [u'summary.quickStats.staticCpuEntitlement', u'5167'],
        [u'summary.quickStats.staticMemoryEntitlement', u'16532'],
        [u'summary.quickStats.swappedMemory', u'0'],
        [u'summary.quickStats.uptimeSeconds', u'262571'],
    ],
)