Statistics
| Branch: | Tag: | Revision:

root / man / ganeti-watcher.rst @ 77ecfa82

History | View | Annotate | Download (2.6 kB)

1
ganeti-watcher(8) Ganeti | Version @GANETI_VERSION@
2
===================================================
3

    
4
Name
5
----
6

    
7
ganeti-watcher - Ganeti cluster watcher
8

    
9
Synopsis
10
--------
11

    
12
**ganeti-watcher** [``--debug``]
13
[``--job-age=``*age*]
14
[``--ignore-pause``]
15

    
16
DESCRIPTION
17
-----------
18

    
19
The **ganeti-watcher** is a periodically run script which is
20
responsible for keeping the instances in the correct status. It has
21
two separate functions, one for the master node and another one
22
that runs on every node.
23

    
24
If the watcher is disabled at cluster level (via the
25
**gnt-cluster watcher pause** command), it will exit without doing
26
anything. The cluster-level pause can be overridden via the
27
``--ignore-pause`` option, for example if during a maintenance the
28
watcher needs to be disabled in general, but the administrator
29
wants to run it just once.
30

    
31
The ``--debug`` option will increase the verbosity of the watcher
32
and also activate logging to the standard error.
33

    
34
Master operations
35
~~~~~~~~~~~~~~~~~
36

    
37
Its primary function is to try to keep running all instances which
38
are marked as *up* in the configuration file, by trying to start
39
them a limited number of times.
40

    
41
Another function is to "repair" DRBD links by reactivating the
42
block devices of instances which have secondaries on nodes that
43
have been rebooted.
44

    
45
The watcher will also archive old jobs (older than the age given
46
via the ``--job-age`` option, which defaults to 6 hours), in order
47
to keep the job queue manageable.
48

    
49
Node operations
50
~~~~~~~~~~~~~~~
51

    
52
The watcher will restart any down daemons that are appropriate for
53
the current node.
54

    
55
In addition, it will execute any scripts which exist under the
56
"watcher" directory in the Ganeti hooks directory
57
(``@SYSCONFDIR@/ganeti/hooks``). This should be used for lightweight
58
actions, like starting any extra daemons.
59

    
60
If the cluster parameter ``maintain_node_health`` is enabled, then the
61
watcher will also shutdown instances and DRBD devices if the node is
62
declared as offline by known master candidates.
63

    
64
The watcher does synchronous queries but will submit jobs for
65
executing the changes. Due to locking, it could be that the jobs
66
execute much later than the watcher submits them.
67

    
68
FILES
69
-----
70

    
71
The command has a state file located at
72
``@LOCALSTATEDIR@/lib/ganeti/watcher.data`` (only used on the master)
73
and a log file at ``@LOCALSTATEDIR@/log/ganeti/watcher.log``. Removal
74
of either file will not affect correct operation; the removal of the
75
state file will just cause the restart counters for the instances to
76
reset to zero.
77

    
78
.. vim: set textwidth=72 :
79
.. Local Variables:
80
.. mode: rst
81
.. fill-column: 72
82
.. End: