NANNY(8)NANNY(8)NAME
nanny - tool to monitor status of services in a cluster
SYNOPSIS
nanny has two forms, depending on whether it is being used to monitor
virtual server services running on real servers, or failover services
running on a primary or backup cluster node.
Using nanny to monitor virtual server services:
nanny [-t|--interval=ARG] [-I|--ipvsadm=ARG]
[-M|--method=ARG] [-U|--loadcmd=ARG]
[-n|--nodaemon] [-c|--nofork] [--test-start] [--norun]
[-p|--port=ARG] [-a|--reentrytime=ARG] [-h|--server=ARG]
[-f|--fwmark=ARG] [-r|--rport=ARG]
[-v|--verbose] [-V|--virtaddress=ARG] [-w|--weight=ARG]
[-S|--scale=ARG] [-s|--send_string=ARG]
[-e|--send_program=ARG[-x|--expect_string=ARG]
[-q|--quiesce-server] [-u|--UDP] [-T|--suppress] [-?|--help]
[--usage] [--version]
Using nanny to monitor failover services:
nanny [-t|--interval=ARG] [-U|--loadcmd=ARG]
[-n|--nodaemon] [-c|--nofork] [--test-start] [--norun]
[-p|--port=ARG] [-h|--server=ARG] [-r|--rport=ARG] [-v|--verbose]
[-V|--virtaddress=ARG] [-s|--send_string=ARG]
[-x|--expect_string=ARG] [-R|--startup=ARG]
[-D|--shutdown=ARG] [-u|--UDP] [-T|--suppress] [-?|--help]
[--usage] [--version]
DESCRIPTION
nanny is a daemon used by pulse to monitor the running status of the
specified services on clustered servers. This tool has NO error check‐
ing and should not be run without the direct supervision of pulse!
OPTIONS-t ARG|--interval= ARG
ARG specifies the number of seconds to wait between connection
attempts to the server/service.
-I ARG|--ipvsadm= ARG
This s the path to the ipvsadm tool, which is normally
/sbin/ipvsadm. This parameter is not used in failover service
monitoring.
-M ARG|--method= ARG
This option specifies the routing method for the real server
(this parameter is not used in monitoring failover services).
Allowable choices are:
g - Use gatewaying (direct routing).
m - Use masquerading (network access translation, or NAT).
t - Use ipip encapsulation (tunneling).
-U|--loadcmd=ARG
Command to get remote load average and/or perform file transfers
with (rup, rsh, ssh).
-n|--nodaemon
Normally, nanny runs as a daemon but with this option runs in
the foreground. When running in this mode, nanny sends all out‐
put to STDOUT instead of to syslog.
-c|--nofork
This mode forces nanny to disassociate from the terminal, but
don't fork off into a daemon.
--test-start
Runs nanny in a test mode. Reports, but does not start, other
daemon processes.
--norun
Same as "--test-start".
-p|--port= ARG
Port used on the virtual IP address of the service to be moni‐
tored (fos), or the port used on the address of the virtual ser‐
vice to be monitored (lvsd). If omitted, port 80 (http) is
assumed.
-a|--reentrytime= ARG
The number of seconds a failed service must remain alive before
allowing the service/node back into the cluster. The main pur‐
pose of this time delay is to avoid having a service or node
ping-ponging. As a general rule of thumb, if the service is
available uninterupted for 60-120 seconds, then it is generally
ok to let it back into the cluster. This parameter is ignored
for failover services.
-S|--scale= ARG
This is a factor used to adjust the sensitivity of the real
server loading algorythm. By increasing this factor, the CPU
load on the server must be much higher before the weighting of
the server will be affected in the LVS routing table. This
parameter is ignored for failover services.
-h|--server= ARG
This is the IP address of the server that is to be monitored.
MUST BE SPECIFIED.
-f|--fwmark= ARG
This is the firewalling mark of the virtual service to be moni‐
tored (lvsd). If this option is set, the --virtaddress option
will be ignored.
-r|--rport= ARG
Port for nanny to monitor on the real server to check for ser‐
vice availability. If omitted, port 80 (http) is assumed.
-V|--virtaddress= ARG
This is the virtual IP address of the service to be monitored
(fos), or the address of the virtual service to be monitored
(lvsd).
-w|--weight= ARG
The relative weighting of the real servers can be adjusted by
changing this setting to a higher number. For example, if one
server has a weighting of 1 and another one has a weight of 2,
the second one will get twice as many requests redirected to it.
The user-assigned weight of the server is adjusted dynamically
based the cpu load average and by the scale factor. This parame‐
ter is ignored for failover services.
-e|--send_program = FILE
This option depreciates the -s option when used. It's fuction is
to allow the use of an external program or script in preferance
to the static -s argument against each of the real servers
defined in the lvs.cf config file. The special token %h is
replaced with the IP of each of the defined real servers and can
be used more than once though it will carry the same IP of the
defined real server that has been selected. The special token
%p is replaced with the port of each of the defined real servers
and can be used more than once though it too will carry the same
port value of the defined real server that has been selected.
eg. 'ping -c1 %h'
-s|--send_str= ARG
Optional text string to send to the port in order to test
whether the service is functioning. Length is limited to 255
printable, quoteable text characters (\n, \r, \t, \\, and \' are
also permitted). If the send_str option is omitted altogether,
then no attempt to send data will occur EXCEPT if port = 80 and
expect_str is also omitted, in which case a web service is
assumed and an http test string will be sent and expected (for
backwards compatibility with earlier releases of piranha).
If both --send_str and --expect_str are specified, then the
send_str string will be sent first, before the expect_str string
is received and tested. If neither are specified (and port is
not 80), then the service will only be tested by the success
and/or failure of connecting to the port. No other I/O will be
performed.
-x|--expect_str= ARG
Optional text response string expected from the port in order to
test whether the service is functioning. Length is limited to
255 printable, quotable text characters (\n, \r, \t, \\, and \'
are also permitted). If expect_str="*", then any characters are
accepted (but SOMETHING must be received). This is different
than not specifying any expect string, which means do not even
attempt the receive operation.
If this option is omitted then no attempt to receive data will
occur EXCEPT if port = 80 and send_str is also omitted, in which
case a web service is assumed and an http test string will be
sent and expected (for backwards compatibility with earlier
releases of piranha).
If both --send_str and --expect_str are specified, then the
send_str string will be sent first, before the expect_str string
is received and tested. If neither are specified, the service
will only be tested by the success and/or failure of connecting
to the port. No other I/O will be performed.
-T|--suppress
Suppress translation of '\' characters in send/expect strings.
Try this if your send/expect strings are not being handled prop‐
erly. It will prevent the nanny program from performing its own
translations.
-R|--startup=ARG
This parameter is mandatory for monitoring failover services,
and must be omitted for monitoring real servers. The specified
value is the command or script to execute to start the monitored
service and a single optional parameter separated by a space.
Failover services are started and stopped by nanny as part of
the failover process, and nanny determines whether the service
it is monitoring is a failover service (instead of a virtual
server) by the presence or absence of this parameter.
The command used should be repeatable; meaning that it should be
harmless (other than a possible returned error value) to execute
the command multiple times in a row.
-D|--shutdown=ARG
This parameter is mandatory for monitoring failover services,
and must be omitted for monitoring real servers. The specified
value is the command or script to execute to stop the monitored
service and a single optional parameter separated by a space.
Failover services are started and stopped by nanny as part of
the failover process, and nanny determines whether the service
it is monitoring is a failover service (instead of a virtual
server) by the presence or absence of this parameter.
The command used should be repeatable; meaning that it should be
harmless (other than a possible returned error value) to execute
the command multiple times in a row.
-q|--quiesce-server
Quiesce server when service monitoring timeouts. It is useful
when a server is too busy to serve new requests, nanny will qui‐
esce this server by setting its weight zero, so that established
connections still get served by this server and no new requests
will be sent to this server.
-u|--UDP
Use the UDP protocol instead of TCP for monitor communications.
-v|--verbose
Give *lots* of debugging information to either syslog or STDOUT.
-?|--help
Shows a verbose usage listing.
--usage
Outputs a terse argument summary.
--version
Displays program version.
SEE ALSOlvs.cf(5), ipvsadm(8), lvsd(8), pulse(8).
AUTHOR
Philip Copeland <bryce@redhat.com>
Erik Troan <ewt@redhat.com>
Keith Barrett <kbarrett@redhat.com>
4th Berkeley Distribution Sat Aug 18 2001 NANNY(8)