root / man / gnt-cluster.sgml @ 04367e70
History | View | Annotate | Download (35.9 kB)
1 |
<!doctype refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN" [ |
---|---|
2 |
|
3 |
<!-- Fill in your name for FIRSTNAME and SURNAME. --> |
4 |
<!-- Please adjust the date whenever revising the manpage. --> |
5 |
<!ENTITY dhdate "<date>June 08, 2010</date>"> |
6 |
<!-- SECTION should be 1-8, maybe w/ subsection other parameters are |
7 |
allowed: see man(7), man(1). --> |
8 |
<!ENTITY dhsection "<manvolnum>8</manvolnum>"> |
9 |
<!ENTITY dhucpackage "<refentrytitle>gnt-cluster</refentrytitle>"> |
10 |
<!ENTITY dhpackage "gnt-cluster"> |
11 |
|
12 |
<!ENTITY debian "<productname>Debian</productname>"> |
13 |
<!ENTITY gnu "<acronym>GNU</acronym>"> |
14 |
<!ENTITY gpl "&gnu; <acronym>GPL</acronym>"> |
15 |
<!ENTITY footer SYSTEM "footer.sgml"> |
16 |
]> |
17 |
|
18 |
<refentry> |
19 |
<refentryinfo> |
20 |
<copyright> |
21 |
<year>2006</year> |
22 |
<year>2007</year> |
23 |
<year>2008</year> |
24 |
<year>2009</year> |
25 |
<holder>Google Inc.</holder> |
26 |
</copyright> |
27 |
&dhdate; |
28 |
</refentryinfo> |
29 |
<refmeta> |
30 |
&dhucpackage; |
31 |
|
32 |
&dhsection; |
33 |
<refmiscinfo>Ganeti 2.2</refmiscinfo> |
34 |
</refmeta> |
35 |
<refnamediv> |
36 |
<refname>&dhpackage;</refname> |
37 |
|
38 |
<refpurpose>Ganeti administration, cluster-wide</refpurpose> |
39 |
</refnamediv> |
40 |
<refsynopsisdiv> |
41 |
<cmdsynopsis> |
42 |
<command>&dhpackage; </command> |
43 |
|
44 |
<arg choice="req">command</arg> |
45 |
<arg>arguments...</arg> |
46 |
</cmdsynopsis> |
47 |
</refsynopsisdiv> |
48 |
<refsect1> |
49 |
<title>DESCRIPTION</title> |
50 |
|
51 |
<para> |
52 |
The <command>&dhpackage;</command> is used for cluster-wide |
53 |
administration in the Ganeti system. |
54 |
</para> |
55 |
|
56 |
</refsect1> |
57 |
<refsect1> |
58 |
<title>COMMANDS</title> |
59 |
|
60 |
<refsect2> |
61 |
<title>ADD-TAGS</title> |
62 |
|
63 |
<cmdsynopsis> |
64 |
<command>add-tags</command> |
65 |
<arg choice="opt">--from <replaceable>file</replaceable></arg> |
66 |
<arg choice="req" |
67 |
rep="repeat"><replaceable>tag</replaceable></arg> |
68 |
</cmdsynopsis> |
69 |
|
70 |
<para> |
71 |
Add tags to the cluster. If any of the tags contains invalid |
72 |
characters, the entire operation will abort. |
73 |
</para> |
74 |
|
75 |
<para> |
76 |
If the <option>--from</option> option is given, the list of |
77 |
tags will be extended with the contents of that file (each |
78 |
line becomes a tag). In this case, there is not need to pass |
79 |
tags on the command line (if you do, both sources will be |
80 |
used). A file name of - will be interpreted as stdin. |
81 |
</para> |
82 |
</refsect2> |
83 |
|
84 |
<refsect2> |
85 |
<title>COMMAND</title> |
86 |
|
87 |
<cmdsynopsis> |
88 |
<command>command</command> |
89 |
<arg>-n <replaceable>node</replaceable></arg> |
90 |
<arg choice="req"><replaceable>command</replaceable></arg> |
91 |
</cmdsynopsis> |
92 |
|
93 |
<para> |
94 |
Executes a command on all nodes. If the option |
95 |
<option>-n</option> is not given, the command will be executed |
96 |
on all nodes, otherwise it will be executed only on the |
97 |
node(s) specified. Use the option multiple times for running |
98 |
it on multiple nodes, like: |
99 |
|
100 |
<screen> |
101 |
# gnt-cluster command -n node1.example.com -n node2.example.com date |
102 |
</screen> |
103 |
|
104 |
</para> |
105 |
|
106 |
<para> |
107 |
The command is executed serially on the selected nodes. If the |
108 |
master node is present in the list, the command will be |
109 |
executed last on the master. Regarding the other nodes, the |
110 |
execution order is somewhat alphabetic, so that |
111 |
node2.example.com will be earlier than node10.example.com but |
112 |
after node1.example.com. |
113 |
</para> |
114 |
|
115 |
<para> |
116 |
So given the node names node1, node2, node3, node10, node11, |
117 |
with node3 being the master, the order will be: node1, node2, |
118 |
node10, node11, node3. |
119 |
</para> |
120 |
|
121 |
<para> |
122 |
The command is constructed by concatenating all other command |
123 |
line arguments. For example, to list the contents of the |
124 |
<filename class="directory">/etc</filename> directory on all |
125 |
nodes, run: |
126 |
|
127 |
<screen> |
128 |
# gnt-cluster command ls -l /etc |
129 |
</screen> |
130 |
|
131 |
and the command which will be executed will be |
132 |
<computeroutput>"ls -l /etc"</computeroutput> |
133 |
</para> |
134 |
</refsect2> |
135 |
|
136 |
<refsect2> |
137 |
<title>COPYFILE</title> |
138 |
|
139 |
<cmdsynopsis> |
140 |
<command>copyfile</command> |
141 |
<arg>--use-replication-network</arg> |
142 |
<arg>-n <replaceable>node</replaceable></arg> |
143 |
<arg choice="req"><replaceable>file</replaceable></arg> |
144 |
</cmdsynopsis> |
145 |
|
146 |
<para> |
147 |
Copies a file to all or to some nodes. The argument specifies |
148 |
the source file (on the current system), the |
149 |
<option>-n</option> argument specifies the target node, or |
150 |
nodes if the option is given multiple times. If |
151 |
<option>-n</option> is not given at all, the file will be |
152 |
copied to all nodes. |
153 |
|
154 |
Passing the <option>--use-replication-network</option> option |
155 |
will cause the copy to be done over the replication network |
156 |
(only matters if the primary/secondary IPs are different). |
157 |
|
158 |
Example: |
159 |
<screen> |
160 |
# gnt-cluster -n node1.example.com -n node2.example.com copyfile /tmp/test |
161 |
</screen> |
162 |
|
163 |
This will copy the file <filename>/tmp/test</filename> from |
164 |
the current node to the two named nodes. |
165 |
</para> |
166 |
</refsect2> |
167 |
|
168 |
<refsect2> |
169 |
<title>DESTROY</title> |
170 |
|
171 |
<cmdsynopsis> |
172 |
<command>destroy</command> |
173 |
<arg choice="req">--yes-do-it</arg> |
174 |
</cmdsynopsis> |
175 |
|
176 |
<para> |
177 |
Remove all configuration files related to the cluster, so that |
178 |
a <command>gnt-cluster init</command> can be done again |
179 |
afterwards. |
180 |
</para> |
181 |
|
182 |
<para> |
183 |
Since this is a dangerous command, you are required to pass |
184 |
the argument <replaceable>--yes-do-it.</replaceable> |
185 |
</para> |
186 |
</refsect2> |
187 |
|
188 |
<refsect2> |
189 |
<title>GETMASTER</title> |
190 |
|
191 |
<cmdsynopsis> |
192 |
<command>getmaster</command> |
193 |
</cmdsynopsis> |
194 |
|
195 |
<para> |
196 |
Displays the current master node. |
197 |
</para> |
198 |
</refsect2> |
199 |
|
200 |
<refsect2> |
201 |
<title>INFO</title> |
202 |
|
203 |
<cmdsynopsis> |
204 |
<command>info</command> |
205 |
<arg>--roman</arg> |
206 |
</cmdsynopsis> |
207 |
|
208 |
<para> |
209 |
Shows runtime cluster information: cluster name, architecture |
210 |
(32 or 64 bit), master node, node list and instance list. |
211 |
</para> |
212 |
|
213 |
<para> |
214 |
Passing the <option>--roman</option> option gnt-cluster info will try |
215 |
to print its integer fields in a latin friendly way. This allows |
216 |
further diffusion of Ganeti among ancient cultures. |
217 |
</para> |
218 |
|
219 |
</refsect2> |
220 |
|
221 |
<refsect2> |
222 |
<title>INIT</title> |
223 |
|
224 |
<cmdsynopsis> |
225 |
<command>init</command> |
226 |
<sbr> |
227 |
<arg>-s <replaceable>secondary_ip</replaceable></arg> |
228 |
<sbr> |
229 |
<arg>--vg-name <replaceable>vg-name</replaceable></arg> |
230 |
<sbr> |
231 |
<arg>--master-netdev <replaceable>interface-name</replaceable></arg> |
232 |
<sbr> |
233 |
<arg>-m <replaceable>mac-prefix</replaceable></arg> |
234 |
<sbr> |
235 |
<arg>--no-lvm-storage</arg> |
236 |
<sbr> |
237 |
<arg>--no-etc-hosts</arg> |
238 |
<sbr> |
239 |
<arg>--no-ssh-init</arg> |
240 |
<sbr> |
241 |
<arg>--file-storage-dir <replaceable>dir</replaceable></arg> |
242 |
<sbr> |
243 |
<arg>--enabled-hypervisors <replaceable>hypervisors</replaceable></arg> |
244 |
<sbr> |
245 |
<arg>-t <replaceable>hypervisor name</replaceable></arg> |
246 |
<sbr> |
247 |
<arg>--hypervisor-parameters <replaceable>hypervisor</replaceable>:<replaceable>hv-param</replaceable>=<replaceable>value</replaceable><arg rep="repeat" choice="opt">,<replaceable>hv-param</replaceable>=<replaceable>value</replaceable></arg></arg> |
248 |
<sbr> |
249 |
<arg>--backend-parameters <replaceable>be-param</replaceable>=<replaceable>value</replaceable><arg rep="repeat" choice="opt">,<replaceable>be-param</replaceable>=<replaceable>value</replaceable></arg></arg> |
250 |
<sbr> |
251 |
<arg>--nic-parameters <replaceable>nic-param</replaceable>=<replaceable>value</replaceable><arg rep="repeat" choice="opt">,<replaceable>nic-param</replaceable>=<replaceable>value</replaceable></arg></arg> |
252 |
<sbr> |
253 |
<arg>--maintain-node-health <group choice="req"><arg>yes</arg><arg>no</arg></group></arg> |
254 |
<sbr> |
255 |
<arg>--uid-pool <replaceable>user-id pool definition</replaceable></arg> |
256 |
<sbr> |
257 |
<arg>-I <replaceable>default instance allocator</replaceable></arg> |
258 |
<sbr> |
259 |
<arg>--primary-ip-version <replaceable>version</replaceable></arg> |
260 |
<sbr> |
261 |
<arg>--prealloc-wipe-disks <group choice="req"><arg>yes</arg><arg>no</arg></group></arg> |
262 |
<sbr> |
263 |
<arg choice="req"><replaceable>clustername</replaceable></arg> |
264 |
</cmdsynopsis> |
265 |
|
266 |
<para> |
267 |
This commands is only run once initially on the first node of |
268 |
the cluster. It will initialize the cluster configuration and |
269 |
setup ssh-keys and more. |
270 |
</para> |
271 |
|
272 |
<para> |
273 |
Note that the <replaceable>clustername</replaceable> is not |
274 |
any random name. It has to be resolvable to an IP address |
275 |
using DNS, and it is best if you give the fully-qualified |
276 |
domain name. This hostname must resolve to an IP address |
277 |
reserved exclusively for this purpose. |
278 |
</para> |
279 |
|
280 |
<para> |
281 |
The cluster can run in two modes: single-home or |
282 |
dual-homed. In the first case, all traffic (both public |
283 |
traffic, inter-node traffic and data replication traffic) goes |
284 |
over the same interface. In the dual-homed case, the data |
285 |
replication traffic goes over the second network. The |
286 |
<option>-s</option> option here marks the cluster as |
287 |
dual-homed and its parameter represents this node's address on |
288 |
the second network. If you initialise the cluster with |
289 |
<option>-s</option>, all nodes added must have a secondary IP |
290 |
as well. |
291 |
</para> |
292 |
|
293 |
<para> |
294 |
Note that for Ganeti it doesn't matter if the secondary |
295 |
network is actually a separate physical network, or is done |
296 |
using tunneling, etc. For performance reasons, it's |
297 |
recommended to use a separate network, of course. |
298 |
</para> |
299 |
|
300 |
<para> |
301 |
The <option>--vg-name</option> option will let you specify a volume group |
302 |
different than "xenvg" for Ganeti to use when creating instance disks. |
303 |
This volume group must have the same name on all nodes. Once the |
304 |
cluster is initialized this can be altered by using the |
305 |
<command>modify</command> command. If you don't want to use lvm |
306 |
storage at all use the <option>--no-lvm-storage</option> option. |
307 |
Once the cluster is initialized you can change this setup with the |
308 |
<command>modify</command> command. |
309 |
</para> |
310 |
|
311 |
<para> |
312 |
The <option>--master-netdev</option> option is useful for specifying a |
313 |
different interface on which the master will activate its IP address. |
314 |
It's important that all nodes have this interface because you'll need |
315 |
it for a master failover. |
316 |
</para> |
317 |
|
318 |
<para> |
319 |
The <option>-m</option> option will let you specify a three byte prefix |
320 |
under which the virtual MAC addresses of your instances will be |
321 |
generated. The prefix must be specified in the format XX:XX:XX and the |
322 |
default is aa:00:00. |
323 |
</para> |
324 |
|
325 |
<para> |
326 |
The <option>--no-lvm-storage</option> option allows you to initialize |
327 |
the cluster without lvm support. This means that only instances using |
328 |
files as storage backend will be possible to create. Once the cluster |
329 |
is initialized you can change this setup with the |
330 |
<command>modify</command> command. |
331 |
</para> |
332 |
|
333 |
<para> |
334 |
The <option>--no-etc-hosts</option> option allows you to initialize the |
335 |
cluster without modifying the <filename>/etc/hosts</filename> file. |
336 |
</para> |
337 |
|
338 |
<para> |
339 |
The <option>--no-ssh-init</option> option allows you to initialize the |
340 |
cluster without creating or distributing SSH key pairs. |
341 |
</para> |
342 |
|
343 |
<para> |
344 |
The <option>--file-storage-dir</option> option allows you |
345 |
set the directory to use for storing the instance disk |
346 |
files when using file storage as backend for instance disks. |
347 |
</para> |
348 |
|
349 |
<para> |
350 |
The <option>--enabled-hypervisors</option> option allows you |
351 |
to set the list of hypervisors that will be enabled for |
352 |
this cluster. Instance hypervisors can only be chosen from |
353 |
the list of enabled hypervisors, and the first entry of this list |
354 |
will be used by default. Currently, the following hypervisors are |
355 |
available: |
356 |
</para> |
357 |
|
358 |
<para> |
359 |
The <option>--prealloc-wipe-disks</option> sets a cluster wide |
360 |
configuration value for wiping disks prior to allocation. This |
361 |
increases security on instance level as the instance can't |
362 |
access untouched data from it's underlying storage. |
363 |
</para> |
364 |
|
365 |
<para> |
366 |
<variablelist> |
367 |
<varlistentry> |
368 |
<term>xen-pvm</term> |
369 |
<listitem> |
370 |
<para> |
371 |
Xen PVM hypervisor |
372 |
</para> |
373 |
</listitem> |
374 |
</varlistentry> |
375 |
<varlistentry> |
376 |
<term>xen-hvm</term> |
377 |
<listitem> |
378 |
<para> |
379 |
Xen HVM hypervisor |
380 |
</para> |
381 |
</listitem> |
382 |
</varlistentry> |
383 |
<varlistentry> |
384 |
<term>kvm</term> |
385 |
<listitem> |
386 |
<para> |
387 |
Linux KVM hypervisor |
388 |
</para> |
389 |
</listitem> |
390 |
</varlistentry> |
391 |
<varlistentry> |
392 |
<term>chroot</term> |
393 |
<listitem> |
394 |
<para> |
395 |
a simple chroot manager that starts chroot based on a |
396 |
script at the root of the filesystem holding the |
397 |
chroot |
398 |
<varlistentry> |
399 |
<term>fake</term> |
400 |
<listitem> |
401 |
<para> |
402 |
fake hypervisor for development/testing |
403 |
</para> |
404 |
</listitem> |
405 |
</varlistentry> |
406 |
</variablelist> |
407 |
</para> |
408 |
|
409 |
<para> |
410 |
Either a single hypervisor name or a comma-separated list of |
411 |
hypervisor names can be specified. If this option is not |
412 |
specified, only the xen-pvm hypervisor is enabled by default. |
413 |
</para> |
414 |
|
415 |
<para> |
416 |
The <option>--hypervisor-parameters</option> option allows you |
417 |
to set default hypervisor specific parameters for the |
418 |
cluster. The format of this option is the name of the |
419 |
hypervisor, followed by a colon and a comma-separated list of |
420 |
key=value pairs. The keys available for each hypervisors are |
421 |
detailed in the <citerefentry> |
422 |
<refentrytitle>gnt-instance</refentrytitle> |
423 |
<manvolnum>8</manvolnum> </citerefentry> man page, in the |
424 |
<command>add</command> command plus the following parameters |
425 |
which are only configurable globally (at cluster level): |
426 |
|
427 |
<variablelist> |
428 |
<varlistentry> |
429 |
<term>migration_port</term> |
430 |
<listitem> |
431 |
<simpara>Valid for the Xen PVM and KVM hypervisors.</simpara> |
432 |
|
433 |
<para> |
434 |
This options specifies the TCP port to use for |
435 |
live-migration. For Xen, the same port should be |
436 |
configured on all nodes in |
437 |
the <filename>/etc/xen/xend-config.sxp</filename> |
438 |
file, under the |
439 |
key <quote>xend-relocation-port</quote>. |
440 |
</para> |
441 |
</listitem> |
442 |
</varlistentry> |
443 |
<varlistentry> |
444 |
<term>migration_bandwidth</term> |
445 |
<listitem> |
446 |
<simpara>Valid for the KVM hypervisor.</simpara> |
447 |
|
448 |
<para> |
449 |
This option specifies the maximum bandwidth that KVM will |
450 |
use for instance live migrations. The value is in MiB/s. |
451 |
</para> |
452 |
|
453 |
<simpara>This option is only effective with kvm versions >= 78 |
454 |
and qemu-kvm versions >= 0.10.0. |
455 |
</simpara> |
456 |
</listitem> |
457 |
</varlistentry> |
458 |
</variablelist> |
459 |
|
460 |
</para> |
461 |
|
462 |
<para> |
463 |
The <option>--backend-parameters</option> option allows you to set |
464 |
the default backend parameters for the cluster. The parameter |
465 |
format is a comma-separated list of key=value pairs with the |
466 |
following supported keys: |
467 |
</para> |
468 |
|
469 |
<para> |
470 |
<variablelist> |
471 |
<varlistentry> |
472 |
<term>vcpus</term> |
473 |
<listitem> |
474 |
<para> |
475 |
Number of VCPUs to set for an instance by default, must |
476 |
be an integer, will be set to 1 if no specified. |
477 |
</para> |
478 |
</listitem> |
479 |
</varlistentry> |
480 |
<varlistentry> |
481 |
<term>memory</term> |
482 |
<listitem> |
483 |
<para> |
484 |
Amount of memory to allocate for an instance by default, |
485 |
can be either an integer or an integer followed by a |
486 |
unit (M for mebibytes and G for gibibytes are |
487 |
supported), will be set to 128M if not specified. |
488 |
</para> |
489 |
</listitem> |
490 |
</varlistentry> |
491 |
<varlistentry> |
492 |
<term>auto_balance</term> |
493 |
<listitem> |
494 |
<para> |
495 |
Value of the auto_balance flag for instances to use by |
496 |
default, will be set to true if not specified. |
497 |
</para> |
498 |
</listitem> |
499 |
</varlistentry> |
500 |
</variablelist> |
501 |
</para> |
502 |
|
503 |
<para> |
504 |
The <option>--nic-parameters</option> option allows you to set |
505 |
the default nic parameters for the cluster. The parameter |
506 |
format is a comma-separated list of key=value pairs with the |
507 |
following supported keys: |
508 |
<variablelist> |
509 |
<varlistentry> |
510 |
<term>mode</term> |
511 |
<listitem> |
512 |
<para> |
513 |
The default nic mode, 'routed' or 'bridged'. |
514 |
</para> |
515 |
</listitem> |
516 |
</varlistentry> |
517 |
<varlistentry> |
518 |
<term>link</term> |
519 |
<listitem> |
520 |
<para> |
521 |
In bridged mode the default NIC bridge. In routed mode it |
522 |
represents an hypervisor-vif-script dependent value to allow |
523 |
different instance groups. For example under the KVM default |
524 |
network script it is interpreted as a routing table number or |
525 |
name. |
526 |
</para> |
527 |
</listitem> |
528 |
</varlistentry> |
529 |
</variablelist> |
530 |
</para> |
531 |
|
532 |
<para> |
533 |
The option <option>--maintain-node-health</option> allows to |
534 |
enable/disable automatic maintenance actions on |
535 |
nodes. Currently these include automatic shutdown of instances |
536 |
and deactivation of DRBD devices on offline nodes; in the |
537 |
future it might be extended to automatic removal of unknown |
538 |
LVM volumes, etc. |
539 |
</para> |
540 |
|
541 |
<para> |
542 |
The <option>--uid-pool</option> option initializes the user-id pool. |
543 |
The <replaceable>user-id pool definition</replaceable> can contain a |
544 |
list of user-ids and/or a list of user-id ranges. The parameter format |
545 |
is a comma-separated list of numeric user-ids or user-id ranges. |
546 |
The ranges are defined by a lower and higher boundary, separated |
547 |
by a dash. The boundaries are inclusive. |
548 |
If the <option>--uid-pool</option> option is not supplied, the |
549 |
user-id pool is initialized to an empty list. An empty list means that |
550 |
the user-id pool feature is disabled. |
551 |
</para> |
552 |
|
553 |
<para> |
554 |
The <option>-I (--default-iallocator)</option> option specifies the |
555 |
default instance allocator. The instance allocator will be used for |
556 |
operations like instance creation, instance and node migration, etc. |
557 |
when no manual override is specified. If this option is not specified, |
558 |
the default instance allocator will be blank, which means that relevant |
559 |
operations will require the administrator to manually specify either an |
560 |
instance allocator, or a set of nodes. |
561 |
The default iallocator can be changed later using the |
562 |
<command>modify</command> command. |
563 |
</para> |
564 |
|
565 |
<para> |
566 |
The <option>--primary-ip-version</option> option specifies the |
567 |
IP version used for the primary address. Possible values are 4 and |
568 |
6 for IPv4 and IPv6, respectively. This option is used when resolving |
569 |
node names and the cluster name. |
570 |
</para> |
571 |
|
572 |
</refsect2> |
573 |
|
574 |
<refsect2> |
575 |
<title>LIST-TAGS</title> |
576 |
|
577 |
<cmdsynopsis> |
578 |
<command>list-tags</command> |
579 |
</cmdsynopsis> |
580 |
|
581 |
<para>List the tags of the cluster.</para> |
582 |
</refsect2> |
583 |
|
584 |
<refsect2> |
585 |
<title>MASTER-FAILOVER</title> |
586 |
|
587 |
<cmdsynopsis> |
588 |
<command>master-failover</command> |
589 |
<arg>--no-voting</arg> |
590 |
</cmdsynopsis> |
591 |
|
592 |
<para> |
593 |
Failover the master role to the current node. |
594 |
</para> |
595 |
|
596 |
<para> |
597 |
The <option>--no-voting</option> option skips the remote node agreement |
598 |
checks. This is dangerous, but necessary in some cases (for example |
599 |
failing over the master role in a 2 node cluster with the original |
600 |
master down). If the original master then comes up, it won't be able to |
601 |
start its master daemon because it won't have enough votes, but so |
602 |
won't the new master, if the master daemon ever needs a restart. You |
603 |
can pass <option>--no-voting</option> to |
604 |
<command>ganeti-masterd</command> on the new master to solve this |
605 |
problem, and run <command>gnt-cluster redist-conf</command> to make |
606 |
sure the cluster is consistent again. |
607 |
</para> |
608 |
|
609 |
</refsect2> |
610 |
|
611 |
<refsect2> |
612 |
<title>MASTER-PING</title> |
613 |
|
614 |
<cmdsynopsis> |
615 |
<command>master-ping</command> |
616 |
</cmdsynopsis> |
617 |
|
618 |
<para> |
619 |
Checks if the master daemon is alive. |
620 |
</para> |
621 |
|
622 |
<para> |
623 |
If the master daemon is alive and can respond to a basic query |
624 |
(the equivalent of <command>gnt-cluster info</command>), then |
625 |
the exit code of the command will be 0. If the master daemon |
626 |
is not alive (either due to a crash or because this is not the |
627 |
master node), the exit code will be 1. |
628 |
</para> |
629 |
|
630 |
</refsect2> |
631 |
|
632 |
<refsect2> |
633 |
<title>MODIFY</title> |
634 |
|
635 |
<cmdsynopsis> |
636 |
<command>modify</command> |
637 |
<sbr> |
638 |
<arg choice="opt">--vg-name <replaceable>vg-name</replaceable></arg> |
639 |
<sbr> |
640 |
<arg choice="opt">--no-lvm-storage</arg> |
641 |
<sbr> |
642 |
<arg choice="opt">--enabled-hypervisors |
643 |
<replaceable>hypervisors</replaceable></arg> |
644 |
<sbr> |
645 |
<arg choice="opt">--hypervisor-parameters <replaceable>hypervisor</replaceable>:<replaceable>hv-param</replaceable>=<replaceable>value</replaceable><arg rep="repeat" choice="opt">,<replaceable>hv-param</replaceable>=<replaceable>value</replaceable></arg></arg> |
646 |
<sbr> |
647 |
<arg choice="opt">--backend-parameters <replaceable>be-param</replaceable>=<replaceable>value</replaceable><arg rep="repeat" choice="opt">,<replaceable>be-param</replaceable>=<replaceable>value</replaceable></arg></arg> |
648 |
<sbr> |
649 |
<arg choice="opt">--nic-parameters <replaceable>nic-param</replaceable>=<replaceable>value</replaceable><arg rep="repeat" choice="opt">,<replaceable>nic-param</replaceable>=<replaceable>value</replaceable></arg></arg> |
650 |
<sbr> |
651 |
<arg choice="opt">--uid-pool <replaceable>user-id pool definition</replaceable></arg> |
652 |
<sbr> |
653 |
<arg choice="opt">--add-uids <replaceable>user-id pool definition</replaceable></arg> |
654 |
<sbr> |
655 |
<arg choice="opt">--remove-uids <replaceable>user-id pool definition</replaceable></arg> |
656 |
<sbr> |
657 |
<arg choice="opt">-C <replaceable>candidate_pool_size</replaceable></arg> |
658 |
<sbr> |
659 |
<arg>--maintain-node-health <group choice="req"><arg>yes</arg><arg>no</arg></group></arg> |
660 |
<sbr> |
661 |
<arg choice="opt">--prealloc-wipe-disks <group choice="req"><arg>yes</arg><arg>no</arg></group></arg> |
662 |
<sbr> |
663 |
<arg choice="opt">-I <replaceable>default instance allocator</replaceable></arg> |
664 |
|
665 |
<sbr> |
666 |
<arg>--reserved-lvs=<replaceable>NAMES</replaceable></arg> |
667 |
|
668 |
</cmdsynopsis> |
669 |
|
670 |
<para> |
671 |
Modify the options for the cluster. |
672 |
</para> |
673 |
|
674 |
<para> |
675 |
The <option>--vg-name</option>, <option>--no-lvm-storarge</option>, |
676 |
<option>--enabled-hypervisors</option>, |
677 |
<option>--hypervisor-parameters</option>, |
678 |
<option>--backend-parameters</option>, |
679 |
<option>--nic-parameters</option>, |
680 |
<option>--maintain-node-health</option>, |
681 |
<option>--prealloc-wipe-disks</option>, |
682 |
<option>--uid-pool</option> options are described in |
683 |
the <command>init</command> command. |
684 |
</para> |
685 |
|
686 |
<para> |
687 |
The <option>-C</option> option specifies the |
688 |
<varname>candidate_pool_size</varname> cluster parameter. This |
689 |
is the number of nodes that the master will try to keep as |
690 |
<literal>master_candidates</literal>. For more details about |
691 |
this role and other node roles, see the <citerefentry> |
692 |
<refentrytitle>ganeti</refentrytitle><manvolnum>7</manvolnum> |
693 |
</citerefentry>. If you increase the size, the master will |
694 |
automatically promote as many nodes as required and possible |
695 |
to reach the intended number. |
696 |
</para> |
697 |
|
698 |
<para> |
699 |
The <option>--add-uids</option> and <option>--remove-uids</option> |
700 |
options can be used to modify the user-id pool by adding/removing |
701 |
a list of user-ids or user-id ranges. |
702 |
</para> |
703 |
|
704 |
<para> |
705 |
The option <option>--reserved-lvs</option> specifies a list |
706 |
(comma-separated) of logical volume group names (regular |
707 |
expressions) that will be ignored by the cluster verify |
708 |
operation. This is useful if the volume group used for Ganeti |
709 |
is shared with the system for other uses. Note that it's not |
710 |
recommended to create and mark as ignored logical volume names |
711 |
which match Ganeti's own name format (starting with UUID and |
712 |
then <literal>.diskN</literal>), as this option only skips the |
713 |
verification, but not the actual use of the names given. |
714 |
</para> |
715 |
|
716 |
<para> |
717 |
To remove all reserved logical volumes, pass in an empty |
718 |
argument to the option, as in <option>--reserved-lvs=</option> |
719 |
or <option>--reserved-lvs ''</option>. |
720 |
</para> |
721 |
|
722 |
<para> |
723 |
The <option>-I</option> is described in |
724 |
the <command>init</command> command. To clear the default |
725 |
iallocator, just pass an empty string (<literal>''</literal>). |
726 |
</para> |
727 |
|
728 |
</refsect2> |
729 |
|
730 |
<refsect2> |
731 |
<title>QUEUE</title> |
732 |
|
733 |
<cmdsynopsis> |
734 |
<command>queue</command> |
735 |
<arg choice="opt">drain</arg> |
736 |
<arg choice="opt">undrain</arg> |
737 |
<arg choice="opt">info</arg> |
738 |
|
739 |
</cmdsynopsis> |
740 |
|
741 |
<para> |
742 |
Change job queue properties. |
743 |
</para> |
744 |
|
745 |
<para> |
746 |
The <option>drain</option> option sets the drain flag on the |
747 |
job queue. No new jobs will be accepted, but jobs already in |
748 |
the queue will be processed. |
749 |
</para> |
750 |
|
751 |
<para> |
752 |
The <option>undrain</option> will unset the drain flag on the |
753 |
job queue. New jobs will be accepted. |
754 |
</para> |
755 |
|
756 |
<para> |
757 |
The <option>info</option> option shows the properties of the |
758 |
job queue. |
759 |
</para> |
760 |
</refsect2> |
761 |
|
762 |
<refsect2> |
763 |
<title>WATCHER</title> |
764 |
|
765 |
<cmdsynopsis> |
766 |
<command>watcher</command> |
767 |
<group choice="req"> |
768 |
<arg>pause <replaceable>duration</replaceable></arg> |
769 |
<arg>continue</arg> |
770 |
<arg>info</arg> |
771 |
</group> |
772 |
</cmdsynopsis> |
773 |
|
774 |
<para> |
775 |
Make the watcher pause or let it continue. |
776 |
</para> |
777 |
|
778 |
<para> |
779 |
The <option>pause</option> option causes the watcher to pause for |
780 |
<replaceable>duration</replaceable> seconds. |
781 |
</para> |
782 |
|
783 |
<para> |
784 |
The <option>continue</option> option will let the watcher continue. |
785 |
</para> |
786 |
|
787 |
<para> |
788 |
The <option>info</option> option shows whether the watcher is currently |
789 |
paused. |
790 |
</para> |
791 |
</refsect2> |
792 |
|
793 |
<refsect2> |
794 |
<title>redist-conf</title> |
795 |
<cmdsynopsis> |
796 |
<command>redist-conf</command> |
797 |
<arg>--submit</arg> |
798 |
</cmdsynopsis> |
799 |
|
800 |
<para> |
801 |
This command forces a full push of configuration files from |
802 |
the master node to the other nodes in the cluster. This is |
803 |
normally not needed, but can be run if the |
804 |
<command>verify</command> complains about configuration |
805 |
mismatches. |
806 |
</para> |
807 |
|
808 |
<para> |
809 |
The <option>--submit</option> option is used to send the job |
810 |
to the master daemon but not wait for its completion. The job |
811 |
ID will be shown so that it can be examined via |
812 |
<command>gnt-job info</command>. |
813 |
</para> |
814 |
|
815 |
</refsect2> |
816 |
<refsect2> |
817 |
<title>REMOVE-TAGS</title> |
818 |
|
819 |
<cmdsynopsis> |
820 |
<command>remove-tags</command> |
821 |
<arg choice="opt">--from <replaceable>file</replaceable></arg> |
822 |
<arg choice="req" |
823 |
rep="repeat"><replaceable>tag</replaceable></arg> |
824 |
</cmdsynopsis> |
825 |
|
826 |
<para> |
827 |
Remove tags from the cluster. If any of the tags are not |
828 |
existing on the cluster, the entire operation will abort. |
829 |
</para> |
830 |
|
831 |
<para> |
832 |
If the <option>--from</option> option is given, the list of |
833 |
tags will be extended with the contents of that file (each |
834 |
line becomes a tag). In this case, there is not need to pass |
835 |
tags on the command line (if you do, both sources will be |
836 |
used). A file name of - will be interpreted as stdin. |
837 |
</para> |
838 |
</refsect2> |
839 |
|
840 |
<refsect2> |
841 |
<title>RENAME</title> |
842 |
|
843 |
<cmdsynopsis> |
844 |
<command>rename</command> |
845 |
<arg>-f</arg> |
846 |
<arg choice="req"><replaceable>name</replaceable></arg> |
847 |
</cmdsynopsis> |
848 |
|
849 |
<para> |
850 |
Renames the cluster and in the process updates the master IP |
851 |
address to the one the new name resolves to. At least one of |
852 |
either the name or the IP address must be different, otherwise |
853 |
the operation will be aborted. |
854 |
</para> |
855 |
|
856 |
<para> |
857 |
Note that since this command can be dangerous (especially when |
858 |
run over SSH), the command will require confirmation unless |
859 |
run with the <option>-f</option> option. |
860 |
</para> |
861 |
</refsect2> |
862 |
|
863 |
<refsect2> |
864 |
<title>RENEW-CRYPTO</title> |
865 |
|
866 |
<cmdsynopsis> |
867 |
<command>renew-crypto</command> |
868 |
<arg>-f</arg> |
869 |
<sbr> |
870 |
<arg choice="opt">--new-cluster-certificate</arg> |
871 |
<arg choice="opt">--new-confd-hmac-key</arg> |
872 |
<sbr> |
873 |
<arg choice="opt">--new-rapi-certificate</arg> |
874 |
<arg choice="opt">--rapi-certificate <replaceable>rapi-cert</replaceable></arg> |
875 |
<sbr> |
876 |
<arg choice="opt">--new-cluster-domain-secret</arg> |
877 |
<arg choice="opt">--cluster-domain-secret <replaceable>filename</replaceable></arg> |
878 |
</cmdsynopsis> |
879 |
|
880 |
<para> |
881 |
This command will stop all |
882 |
Ganeti daemons in the cluster and start them again once the new |
883 |
certificates and keys are replicated. The options |
884 |
<option>--new-cluster-certificate</option> and |
885 |
<option>--new-confd-hmac-key</option> can be used to regenerate the |
886 |
cluster-internal SSL certificate respective the HMAC key used by |
887 |
<citerefentry> |
888 |
<refentrytitle>ganeti-confd</refentrytitle><manvolnum>8</manvolnum> |
889 |
</citerefentry>. |
890 |
</para> |
891 |
|
892 |
<para> |
893 |
To generate a new self-signed RAPI certificate (used by <citerefentry> |
894 |
<refentrytitle>ganeti-rapi</refentrytitle><manvolnum>8</manvolnum> |
895 |
</citerefentry>) specify <option>--new-rapi-certificate</option>. If |
896 |
you want to use your own certificate, e.g. one signed by a certificate |
897 |
authority (CA), pass its filename to |
898 |
<option>--rapi-certificate</option>. |
899 |
</para> |
900 |
|
901 |
<para> |
902 |
<option>--new-cluster-domain-secret</option> generates a new, random |
903 |
cluster domain secret. <option>--cluster-domain-secret</option> reads |
904 |
the secret from a file. The cluster domain secret is used to sign |
905 |
information exchanged between separate clusters via a third party. |
906 |
</para> |
907 |
</refsect2> |
908 |
|
909 |
<refsect2> |
910 |
<title>REPAIR-DISK-SIZES</title> |
911 |
|
912 |
<cmdsynopsis> |
913 |
<command>repair-disk-sizes</command> |
914 |
<arg rep="repeat">instance</arg> |
915 |
</cmdsynopsis> |
916 |
|
917 |
<para> |
918 |
This command checks that the recorded size of the given |
919 |
instance's disks matches the actual size and updates any |
920 |
mismatches found. This is needed if the Ganeti configuration |
921 |
is no longer consistent with reality, as it will impact some |
922 |
disk operations. If no arguments are given, all instances will |
923 |
be checked. |
924 |
</para> |
925 |
|
926 |
<para> |
927 |
Note that only active disks can be checked by this command; in |
928 |
case a disk cannot be activated it's advised to use |
929 |
<command>gnt-instance activate-disks --ignore-size ...</command> to |
930 |
force activation without regard to the |
931 |
current size. |
932 |
</para> |
933 |
|
934 |
<para> |
935 |
When the all disk sizes are consistent, the command will |
936 |
return no output. Otherwise it will log details about the |
937 |
inconsistencies in the configuration. |
938 |
</para> |
939 |
</refsect2> |
940 |
|
941 |
<refsect2> |
942 |
<title>SEARCH-TAGS</title> |
943 |
|
944 |
<cmdsynopsis> |
945 |
<command>search-tags</command> |
946 |
<arg choice="req"><replaceable>pattern</replaceable></arg> |
947 |
</cmdsynopsis> |
948 |
|
949 |
<para> |
950 |
Searches the tags on all objects in the cluster (the cluster |
951 |
itself, the nodes and the instances) for a given pattern. The |
952 |
pattern is interpreted as a regular expression and a search |
953 |
will be done on it (i.e. the given pattern is not anchored to |
954 |
the beggining of the string; if you want that, prefix the |
955 |
pattern with <literal>^</literal>). |
956 |
</para> |
957 |
|
958 |
<para> |
959 |
If no tags are matching the pattern, the exit code of the |
960 |
command will be one. If there is at least one match, the exit |
961 |
code will be zero. Each match is listed on one line, the |
962 |
object and the tag separated by a space. The cluster will be |
963 |
listed as <filename>/cluster</filename>, a node will be listed |
964 |
as |
965 |
<filename>/nodes/<replaceable>name</replaceable></filename>, |
966 |
and an instance as |
967 |
<filename>/instances/<replaceable>name</replaceable></filename>. |
968 |
Example: |
969 |
</para> |
970 |
<screen> |
971 |
# gnt-cluster search-tags time |
972 |
/cluster ctime:2007-09-01 |
973 |
/nodes/node1.example.com mtime:2007-10-04 |
974 |
</screen> |
975 |
</refsect2> |
976 |
|
977 |
<refsect2> |
978 |
<title>VERIFY</title> |
979 |
|
980 |
<cmdsynopsis> |
981 |
<command>verify</command> |
982 |
<arg choice="opt">--no-nplus1-mem</arg> |
983 |
</cmdsynopsis> |
984 |
|
985 |
<para> |
986 |
Verify correctness of cluster configuration. This is safe with |
987 |
respect to running instances, and incurs no downtime of the |
988 |
instances. |
989 |
</para> |
990 |
|
991 |
<para> |
992 |
If the <option>--no-nplus1-mem</option> option is given, Ganeti won't |
993 |
check whether if it loses a node it can restart all the instances on |
994 |
their secondaries (and report an error otherwise). |
995 |
</para> |
996 |
</refsect2> |
997 |
|
998 |
<refsect2> |
999 |
<title>VERIFY-DISKS</title> |
1000 |
|
1001 |
<cmdsynopsis> |
1002 |
<command>verify-disks</command> |
1003 |
</cmdsynopsis> |
1004 |
|
1005 |
<para> |
1006 |
The command checks which instances have degraded DRBD disks |
1007 |
and activates the disks of those instances. |
1008 |
</para> |
1009 |
|
1010 |
<para> |
1011 |
This command is run from the <command>ganeti-watcher</command> |
1012 |
tool, which also has a different, complementary algorithm for |
1013 |
doing this check. Together, these two should ensure that DRBD |
1014 |
disks are kept consistent. |
1015 |
</para> |
1016 |
</refsect2> |
1017 |
|
1018 |
<refsect2> |
1019 |
<title>VERSION</title> |
1020 |
|
1021 |
<cmdsynopsis> |
1022 |
<command>version</command> |
1023 |
</cmdsynopsis> |
1024 |
|
1025 |
<para> |
1026 |
Show the cluster version. |
1027 |
</para> |
1028 |
</refsect2> |
1029 |
|
1030 |
</refsect1> |
1031 |
|
1032 |
&footer; |
1033 |
|
1034 |
</refentry> |
1035 |
|
1036 |
<!-- Keep this comment at the end of the file |
1037 |
Local variables: |
1038 |
mode: sgml |
1039 |
sgml-omittag:t |
1040 |
sgml-shorttag:t |
1041 |
sgml-minimize-attributes:nil |
1042 |
sgml-always-quote-attributes:t |
1043 |
sgml-indent-step:2 |
1044 |
sgml-indent-data:t |
1045 |
sgml-parent-document:nil |
1046 |
sgml-default-dtd-file:nil |
1047 |
sgml-exposed-tags:nil |
1048 |
sgml-local-catalogs:nil |
1049 |
sgml-local-ecat-files:nil |
1050 |
End: |
1051 |
--> |