Target Host Ping Check

OpsLogix.IMP.Ping.WMIPingCheck (UnitMonitor)

Knowledge Base article:

Summary

This monitor checks the availability of the target device by ICMP ping.

Causes

This could be caused by:

BadDestination

The ICMP echo request failed because the destination IP address cannot receive ICMP echo requests or should never appear in the destination address field of any IP datagram. For example, calling  Send and specifying IP address "000.0.0.0" returns this status.

BadHeader

The ICMP echo request failed because the header is invalid.

BadOption

The ICMP echo request failed because it contains an invalid option.

BadRoute

The ICMP echo request failed because there is no valid route between the source and destination computers.

DestinationHostUnreachable

The ICMP echo request failed because the destination computer is not reachable.

DestinationNetworkUnreachable

The ICMP echo request failed because the network that contains the destination computer is not reachable.

DestinationPortUnreachable

The ICMP echo request failed because the port on the destination computer is not available.

DestinationProhibited

The ICMPv6 echo request failed because contact with the destination computer is administratively prohibited. This value applies only to IPv6.

DestinationProtocolUnreachable

The ICMP echo request failed because the destination computer that is specified in an ICMP echo message is not reachable, because it does not support the packet's protocol. This value applies only to IPv4. This value is described in IETF RFC 1812 as Communication Administratively Prohibited.

DestinationScopeMismatch

The ICMP echo request failed because the source address and destination address that are specified in an ICMP echo message are not in the same scope. This is typically caused by a router forwarding a packet using an interface that is outside the scope of the source address. Address scopes (link-local, site-local, and global scope) determine where on the network an address is valid.

DestinationUnreachable

The ICMP echo request failed because the destination computer that is specified in an ICMP echo message is not reachable; the exact cause of problem is unknown.

HardwareError

The ICMP echo request failed because of a hardware error.

IcmpError

The ICMP echo request failed because of an ICMP protocol error.

NoResources

The ICMP echo request failed because of insufficient network resources.

PacketTooBig

The ICMP echo request failed because the packet containing the request is larger than the maximum transmission unit (MTU) of a node (router or gateway) located between the source and destination. The MTU defines the maximum size of a transmittable packet.

ParameterProblem

The ICMP echo request failed because a node (router or gateway) encountered problems while processing the packet header. This is the status if, for example, the header contains invalid field data or an unrecognized option.

SourceQuench

The ICMP echo request failed because the packet was discarded. This occurs when the source computer's output queue has insufficient storage space, or when packets arrive at the destination too quickly to be processed.

Success

The ICMP echo request succeeded; an ICMP echo reply was received. When you get this status code, the other  PingReply properties contain valid data.

TimedOut

The ICMP echo Reply was not received within the allotted time. The default time allowed for replies is 5 seconds. You can change this value using the  Send or  SendAsync methods that take a timeout parameter.

TimeExceeded

The ICMP echo request failed because its Time to Live (TTL) value reached zero, causing the forwarding node (router or gateway) to discard the packet.

TtlExpired

The ICMP echo request failed because its Time to Live (TTL) value reached zero, causing the forwarding node (router or gateway) to discard the packet.

TtlReassemblyTimeExceeded

The ICMP echo request failed because the packet was divided into fragments for transmission and all of the fragments were not received within the time allotted for reassembly. RFC 2460 (available at www.ietf.org) specifies 60 seconds as the time limit within which all packet fragments must be received.

Unknown

The ICMP echo request failed for an unknown reason.

UnrecognizedNextHeader

The ICMP echo request failed because the Next Header field does not contain a recognized value. The Next Header field indicates the extension header type (if present) or the protocol above the IP layer, for example, TCP or UDP.

https://msdn.microsoft.com/en-us/library/system.net.networkinformation.ipstatus(v=vs.110).aspx

 

Resolutions

Perform any of the following:

 

Element properties:

TargetOpsLogix.IMP.Ping.Target
Parent MonitorSystem.Health.AvailabilityState
CategoryAvailabilityHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityMatchMonitorHealth
Alert PriorityNormal
Alert Auto ResolveTrue
Monitor TypeOpsLogix.IMP.Ping.Availability.MonitorType
RemotableTrue
AccessibilityPublic
Alert Message
No ping reply
Device {0} ({1}) did not respond to a ping reply, the status message is: {2}
RunAsDefault

Source Code:

<UnitMonitor ID="OpsLogix.IMP.Ping.WMIPingCheck" Accessibility="Public" Enabled="true" Target="OpsLogix.IMP.Ping.Target" ParentMonitorID="Health!System.Health.AvailabilityState" Remotable="true" Priority="Normal" TypeID="OpsLogix.IMP.Ping.Availability.MonitorType" ConfirmDelivery="true">
<Category>AvailabilityHealth</Category>
<AlertSettings AlertMessage="OpsLogix.IMP.Ping.WMIPingCheck_AlertMessageResourceID">
<AlertOnState>Error</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>MatchMonitorHealth</AlertSeverity>
<AlertParameters>
<AlertParameter1>$Target/Property[Type="System!System.Entity"]/DisplayName$</AlertParameter1>
<AlertParameter2>$Target/Property[Type="OpsLogix.IMP.Ping.Target"]/TargetHost$</AlertParameter2>
<AlertParameter3>$Data/Context/Status$</AlertParameter3>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="Healthy" MonitorTypeStateID="Healthy" HealthState="Success"/>
<OperationalState ID="Critical" MonitorTypeStateID="Critical" HealthState="Error"/>
</OperationalStates>
<Configuration>
<Interval>60</Interval>
<query/>
<InstanceName>$Target/Property[Type="OpsLogix.IMP.Ping.Target"]/TargetHost$</InstanceName>
<NumberOfBadPings>1</NumberOfBadPings>
<Ttl>59</Ttl>
<DatapointThreshold>5</DatapointThreshold>
<TimeOut>30</TimeOut>
<PayloadSize>32</PayloadSize>
<DontFragment>false</DontFragment>
</Configuration>
</UnitMonitor>