Fix: using libi2ncommon LogLevel.
[pingcheck] / Readme
CommitLineData
f9c5fff0
GMF
1 Table of Contents
2=======================================
31. Introduction
afdd699d
GMF
42. Configuration File
53. Command line
64. References
f9c5fff0
GMF
7
8
9
c08bc448
GMF
101. Introduction
11=======================================
12This application provides means to check the availability of remote hosts
13through pings to them.
14
15
161.1. Rationale
17---------------------------------------
48169a4b
GMF
18The application uses ICMP echo requests messages, or TCP segments to verify
19whether a given host is available (up) or not (down).
c08bc448
GMF
20
21The host's address can be an IP or a DNS.
22
23
241.2. How to use
25---------------------------------------
26There are many ways to invoke the application, the simplest is just type:
aca0d1d7 27 ./pingcheck
12589451 28which uses the configuration values from the configuration file (described in
f9c5fff0 29the Configuration File section).
c08bc448 30
703f4d65 31
c08bc448
GMF
321.3. Resources
33---------------------------------------
f9c5fff0
GMF
34Further information about the problem domain can be found in the References
35section.
36
37
381.4. Legal Issues
39---------------------------------------
96d2fb59 40Most parts are licensed under the GPLv2 + linking exception.
c08bc448 41
12589451
GMF
42The ICMP code, bost::net::dns and the "boost pinger" are licensed under the
43boost license and include a note about this in the beginning of the source code.
c08bc448
GMF
44
45
afdd699d 462. Configuration file
c08bc448 47=======================================
12589451
GMF
48In this section are described the configuration items, along with they possible
49values and meanings. This section is organized in each major configuration
50block.
7a073300
GMF
51
52
afdd699d 532.1. General
7a073300
GMF
54---------------------------------------
55This configurations are shared among and affect all the hosts.
61e224f8
GMF
56- source-network-interface: the local network interface from where the ping
57 packages with originate.
58- nameserver: the server which the hosts names will be resolved. It is the
59 lookup server which the application will query first. If left blank or omited,
60 it will use the /etc/resolv.conf.
361552be 61 You can use the nslookup <host> to figure out the nameserver.
a341119a 62- hosts-down-limit: an absolute number, which ranges from 0 to the number of
c5e4bfa1
GMF
63 hosts available. This value represents the minimum number of hosts that have
64 to fail (i.e. do not reply to the ping) in order to alert any external system.
a341119a 65- ping-fail-limit: percentage of pings to a host that can fail. If the
c5e4bfa1
GMF
66 percentage of failed pings to a host exceed this number, then the host is
67 considered down.
d52d036a 68- status-notifier-cmd: the command line that is called when a host is down, or
c1d76f1b
GMF
69 up. Accepted variables are:
70 ${status} - down or up
1634f2a1
GMF
71- link-up-interval: how long (in minutes) the pings must be returned with
72 success in order to consider the link up, or stable.
73- link-down-interval: how long (in minutes) the pings must fail, in order to the
74 application consider the link down.
703f4d65 75
703f4d65 76
afdd699d 772.2. Host
7a073300 78---------------------------------------
d52d036a 79- name: the DNS or IP of the host to ping. Take in consideration that, if a
7a073300
GMF
80 DNS is given, the application pings all IPs in the look up table, however, if
81 IP is provide, it is the only which will be pinged.
48169a4b
GMF
82- port: when using a port based protocol, like TCP, this field specifies in
83 which port to ping the host.
d52d036a 84- interval: the host will be pinged every "interval" seconds.
42c9d872
GMF
85- ping-protocol: indicates which protocol to use to ping the destination host,
86 the currently supported protocols are TCP and ICMP.
7a073300
GMF
87
88
f9c5fff0 89
afdd699d
GMF
903. Command line
91=======================================
92The command line accepts the general configuration file options plus the
93following:
94- config-file: command line to specify a file where the hosts and other
95 configuration information are provided.
078d3cca 96- daemon: run the application as a daemon.
afdd699d
GMF
97
98
99
1004. References
f9c5fff0
GMF
101=======================================
102[1] http://tools.ietf.org/html/rfc792
103[2] http://en.wikipedia.org/wiki/Ping
104[3] http://en.wikipedia.org/wiki/Internet_Control_Message_Protocol
105[4] http://www.boost.org/doc/libs/1_45_0/doc/html/boost_asio.html
106[5] http://www.boost.org/doc/libs/1_45_0/doc/html/program_options.html
48169a4b 107[6] http://www.networkuptime.com/nmap/page4-4.shtml