title: Number of free addresses in DHCP pools on Windows DHCP servers
agents: windows
catalog: os/services
license: GPL
distribution: check_mk
description:
 This check uses the output of "netsh dhcp server show mibinfo" as sent by the
 Check_MK windows agent when using the appropriate agent plugin.
 The check uses the values "free", "used" and "pending" leases to monitor the
 usage of the DHCP pools.

 Each DHCP pool will result in one service on the DHCP server.

 The check will raise WARNING/CRITICAL states when the thresholds of free or
 used addresses are reached. The thresholds need to be given as percentage
 or absolute values.

item:
 The name of the DHCP pool as configured on the DHCP server.

examples:
 # Set warning to 5 percent of free leases and critical to 2 percent
 win_dhcp_pools_default_levels = (5, 2)

perfdata:
 Three variables: The number of free leases {free}, used leases {used} and
 pending leases {pending}.

inventory:
 Each DHCP pool will result in one service on the DHCP server.

[parameters]
warning (int): Percentage of free leases to be left in the pool to issue a warning.
critical (int): Percentage of free leases to be left in the pool to issue a critical.

[configuration]
win_dhcp_pools_default_levels (float, float): The global default levels for all checks
 of this type. This is preset to {(10, 5)} (which means that the check
 gets critical if the pool has less than 5 percent of free leases left).
win_dhcp_pools_inventorize_empty (bool): Set to {True} if you want to inventorize
 pools without any IP Address in it.
