1 <!doctype refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN" [
3 <!-- Fill in your name for FIRSTNAME and SURNAME. -->
4 <!-- Please adjust the date whenever revising the manpage. -->
5 <!ENTITY dhdate "<date>May 29, 2008</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-instance</refentrytitle>">
10 <!ENTITY dhpackage "gnt-instance">
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">
24 <holder>Google Inc.</holder>
32 <refmiscinfo>ganeti 1.2</refmiscinfo>
35 <refname>&dhpackage;</refname>
37 <refpurpose>ganeti instance administration</refpurpose>
41 <command>&dhpackage; </command>
43 <arg choice="req">command</arg>
44 <arg>arguments...</arg>
48 <title>DESCRIPTION</title>
51 The <command>&dhpackage;</command> is used for instance
52 administration in the ganeti system.
57 <title>COMMANDS</title>
60 <title>Creation/removal/querying</title>
65 <command>add</command>
66 <arg>-s <replaceable>disksize</replaceable></arg>
67 <arg>--swap-size <replaceable>disksize</replaceable></arg>
68 <arg>-m <replaceable>memsize</replaceable></arg>
71 <arg>-b <replaceable>bridge</replaceable></arg>
72 <arg>--mac <replaceable>MAC-address</replaceable></arg>
75 <arg>--hvm-boot-order <replaceable>boot-order</replaceable></arg>
76 <arg>--hvm-acpi <replaceable>ACPI-support</replaceable></arg>
79 <arg>--hvm-pae <replaceable>PAE-support</replaceable></arg>
82 <arg>--hvm-cdrom-image-path
83 <replaceable>cdrom-image-path</replaceable></arg>
86 <arg>--hvm-nic-type <replaceable>NICTYPE</replaceable></arg>
90 <replaceable>DISKTYPE</replaceable></arg>
93 <arg>--vnc-bind-address
94 <replaceable>vnc-bind-address</replaceable></arg>
97 <arg>--kernel<group choice="req">
99 <arg><replaceable>kernel_path</replaceable></arg>
103 <arg>--initrd<group choice="req">
106 <arg><replaceable>initrd_path</replaceable></arg>
110 <arg>--file-storage-dir <replaceable>dir_path</replaceable></arg>
111 <arg>--file-driver<group choice="req">
117 <arg choice="req">-t<group choice="req">
126 <arg>-n <replaceable>node<optional>:secondary-node</optional></replaceable></arg>
127 <arg>--iallocator <replaceable>name</replaceable></arg>
131 <arg choice="req">-o <replaceable>os-type</replaceable></arg>
134 <arg choice="req"><replaceable>instance</replaceable></arg>
138 Creates a new instance on the specified
139 host. <replaceable>instance</replaceable> must be in DNS and
140 resolve to a IP in the same network as the nodes in the
145 The <option>-s</option> option specifies the disk size for
146 the instance, in mebibytes (defaults to
147 <constant>20480MiB</constant> =
148 <constant>20GiB</constant>). You can also use one of the
149 suffixes <literal>m</literal>, <literal>g</literal> or
150 <literal>t</literal> to specificy the exact the units used;
151 these suffixes map to mebibytes, gibibytes and tebibytes.
155 The <option>--swap-size</option> option specifies the swap
156 disk size (in mebibytes) for the instance (the one presented
157 as <filename class="devicefile">/dev/sdb</filename>). The
158 default is <constant>4096MiB</constant>. As for the disk
159 size, you can specify other suffixes.
163 The <option>-m</option> option specifies the memory size for
164 the instance, in mebibytes (defaults to 128 MiB). Again, you
165 can use other suffixes (e.g. <userinput>2g</userinput>).
169 The <option>-o</option> options specifies the operating
170 system to be installed. The available operating systems can
171 be listed with <command>gnt-os list</command>.
175 The <option>-b</option> option specifies the bridge to which the
176 instance will be connected. (defaults to the cluster-wide default
177 bridge specified at cluster initialization time).
181 The <option>--mac</option> option specifies the MAC address
182 of the ethernet interface for the instance. If this option
183 is not specified, a new MAC address is generated randomly with
184 the configured MAC prefix. The randomly generated MAC
185 address is guaranteed to be unique among the instances of
190 The <option>--hvm-boot-order</option> option specifies the
191 boot device order for Xen HVM instances. The boot order is a
192 string of letters listing the boot devices, with valid
193 device letters being:
234 The default is not to set an HVM boot order which is
235 interpreted as 'dc'. This option, like all options starting
236 with 'hvm', is only relevant for Xen HVM instances and
237 ignored by all other instance types.
241 The <option>--hvm-acpi</option> option specifies if Xen
242 should enable ACPI support for this HVM instance. Valid
243 values are true or false. The default value is false,
244 disabling ACPI support for this instance.
248 The <option>--hvm-pae</option> option specifies if Xen
249 should enabled PAE support for this HVM instance. Valid
250 values are true or false. The default is false, disabling
251 PAE support for this instance.
255 The <option>--hvm-cdrom-image-path</option> option specifies the
256 path to the file Xen uses to emulate a virtual CDROM drive
257 for this HVM instance. Valid values are either an
258 absolute path to an existing file or None, which disables
259 virtual CDROM support for this instance. The default is
260 None, disabling virtual CDROM support.
264 The <option>--hvm-nic-type</option> specifies the NIC type
265 Xen should use for this HVM instance. Valid choices are
266 rtl8139, ne2k_pci, ne2k_isa and paravirtual with rtl8139
267 as the default. The paravirtual setting is intended for use
268 with the GPL PV drivers inside HVM Windows instances.
272 The <option>--hvm-disk-type</option> specifies the disk type
273 Xen should use for the HVM instance. Valid choices are ioemu
274 and paravirtual with ioemu as the default. The paravirtual
275 setting is intended for use with the GPL PV drivers inside
276 HVM Windows instances.
280 The <option>--vnc-bind-address</option> option specifies the
281 address that the VNC listener for this instance should bind
282 to. Valid values are IPv4 addresses. Use the address 0.0.0.0
283 to bind to all available interfaces (this is the default)
284 or specify the address of one of the interfaces on the node
285 to restrict listening to that interface.
289 The <option>--iallocator</option> option specifies the instance
290 allocator plugin to use. If you pass in this option the allocator
291 will select nodes for this instance automatically, so you don't need
292 to pass them with the <option>-n</option> option. For more
293 information please refer to the instance allocator documentation.
297 The <option>--kernel</option> option allows the instance to
298 use a custom kernel (if a filename is passed) or to use the
299 default kernel (<filename>@CUSTOM_XEN_KERNEL@</filename>), if the
300 string <constant>default</constant> is passed.
304 The <option>--initrd</option> option is similar: it allows
305 the instance to use a custom initrd (if a filename is
306 passed) or to use the default initrd
307 (<filename>@CUSTOM_XEN_INITRD@</filename>), if the string
308 <constant>default</constant> is passed, or to disable the
309 use of an initrd, if the string <constant>none</constant> is
310 passed. Note that in the case the instance is set to use the
311 default initrd and it doesn't exist, it will be silently
312 ignored; if the instance is set to use a custom initrd and
313 it doesn't exist, this will be treated as an error and will
314 prevent the startup of the instance.
318 The <option>-t</option> options specifies the disk layout type for
319 the instance. The available choices are:
322 <term>diskless</term>
325 This creates an instance with no disks. Its useful for
326 testing only (or other special cases).
333 <para>Disk devices will be regular files.</para>
339 <para>Disk devices will be logical volumes.</para>
346 Disk devices will be drbd (version 8.x) on top of
355 The optional second value of the <option>--node</option> is used for
356 the drbd template type and specifies the remote node.
360 If you do not want gnt-instance to wait for the disk mirror
361 to be synced, use the <option>--no-wait-for-sync</option>
366 The <option>--file-storage-dir</option> specifies the relative path
367 under the cluster-wide file storage directory to store file-based
368 disks. It is useful for having different subdirectories for
369 different instances. The full path of the directory where the disk
370 files are stored will consist of cluster-wide file storage directory
371 + optional subdirectory + instance name. Example:
372 /srv/ganeti/file-storage/mysubdir/instance1.example.com. This option
373 is only relevant for instances using the file storage backend.
377 The <option>--file-driver</option> specifies the driver to use for
378 file-based disks. Note that currently these drivers work with the
379 xen hypervisor only. This option is only relevant for instances using
380 the file storage backend. The available choices are:
385 <para>Kernel loopback driver.</para>
391 <para>blktap driver.</para>
398 The loop driver uses loopback devices to access the filesystem
399 within the file. However, running I/O intensive applications
400 in your instance using the loop driver might result in slowdowns.
401 Furthermore, if you use the loopback driver consider increasing
402 the maximum amount of loopback devices (on most systems it's 8)
403 using the max_loop param.
407 In order to be able to use the blktap driver you should check
408 if the 'blktapctrl' user space disk agent is running (usually
409 automatically started via xend). This user-level disk I/O
410 interface has the advantage of better performance. Especially
411 if you use a network file system (e.g. NFS) to store your instances
412 this is the recommended choice.
418 # gnt-instance add -t file -s 30g -m 512 -o debian-etch \
419 -n node1.example.com --file-storage-dir=mysubdir instance1.example.com
420 # gnt-instance add -t plain -s 30g -m 512 -o debian-etch \
421 -n node1.example.com instance1.example.com
422 # gnt-instance add -t drbd -s 30g -m 512 -o debian-etch \
423 -n node1.example.com:node2.example.com instance2.example.com
429 <title>REMOVE</title>
432 <command>remove</command>
433 <arg>--ignore-failures</arg>
434 <arg choice="req"><replaceable>instance</replaceable></arg>
438 Remove an instance. This will remove all data from the
439 instance and there is <emphasis>no way back</emphasis>. If
440 you are not sure if you use an instance again, use
441 <command>shutdown</command> first and leave it in the
442 shutdown state for a while.
447 The <option>--ignore-failures</option> option will cause the
448 removal to proceed even in the presence of errors during the
449 removal of the instance (e.g. during the shutdown or the
450 disk removal). If this option is not given, the command will
451 stop at the first error.
457 # gnt-instance remove instance1.example.com
466 <command>list</command>
467 <arg>--no-headers</arg>
468 <arg>--separator=<replaceable>SEPARATOR</replaceable></arg>
469 <arg>-o <replaceable>[+]FIELD,...</replaceable></arg>
473 Shows the currently configured instances with memory usage,
474 disk usage, the node they are running on, and the CPU time,
475 counted in seconds, used by each instance since its latest
480 The <option>--no-headers</option> option will skip the
481 initial header line. The <option>--separator</option> option
482 takes an argument which denotes what will be used between
483 the output fields. Both these options are to help scripting.
487 The <option>-o</option> option takes a comma-separated list
488 of output fields. The available fields and their meaning
494 <simpara>the instance name</simpara>
500 <simpara>the OS of the instance</simpara>
506 <simpara>the primary node of the instance</simpara>
512 <simpara>comma-separated list of secondary nodes for the
513 instance; usually this will be just one node</simpara>
517 <term>admin_state</term>
519 <simpara>the desired state of the instance (either "yes"
520 or "no" denoting the instance should run or
525 <term>admin_ram</term>
527 <simpara>the desired memory for the instance</simpara>
531 <term>disk_template</term>
533 <simpara>the disk template of the instance</simpara>
537 <term>oper_state</term>
539 <simpara>the actual state of the instance; can be
540 one of the values "running", "stopped", "(node
547 <simpara>combined form of admin_state and oper_stat;
549 <computeroutput>ERROR_nodedown</computeroutput> if the
550 node of the instance is down,
551 <computeroutput>ERROR_down</computeroutput> if the
552 instance should run but is down,
553 <computeroutput>ERROR_up</computeroutput> if the
554 instance should be stopped but is actually running,
555 <computeroutput>ADMIN_down</computeroutput> if the
556 instance has been stopped (and is stopped) and
557 <computeroutput>running</computeroutput> if the
558 instance is set to be running (and is
563 <term>oper_ram</term>
565 <simpara>the actual memory usage of the instance as seen
566 by the hypervisor</simpara>
572 <simpara>the ip address ganeti recognizes as associated with
573 the instance interface</simpara>
579 <simpara>the instance interface MAC address</simpara>
585 <simpara>bridge the instance is connected to
590 <term>sda_size</term>
592 <simpara>the size of the instance's first disk</simpara>
596 <term>sdb_size</term>
598 <simpara>the size of the instance's second disk</simpara>
604 <simpara>the number of VCPUs allocated to the
611 <simpara>comma-separated list of the instances's
616 <term>serial_no</term>
618 <simpara>the so called 'serial number' of the
619 instance; this is a numeric field that is incremented
620 each time the instance is modified, and it can be used
621 to detect modifications</simpara>
628 If the value of the option starts with the character
629 <constant>+</constant>, the new fields will be added to the
630 default list. This allows to quickly see the default list
631 plus a few other fields, instead of retyping the entire list
636 There is a subtle grouping about the available output
637 fields: all fields except for <option>oper_state</option>,
638 <option>oper_ram</option> and <option>status</option> are
639 configuration value and not run-time values. So if you don't
640 select any of the these fields, the query will be satisfied
641 instantly from the cluster configuration, without having to
642 ask the remote nodes for the data. This can be helpful for
643 big clusters when you only want some data and it makes sense
644 to specify a reduced set of output fields.
647 <para>The default output field list is:
648 <simplelist type="inline">
649 <member>name</member>
651 <member>pnode</member>
652 <member>admin_state</member>
653 <member>oper_state</member>
654 <member>oper_ram</member>
663 <command>info</command>
664 <arg rep="repeat"><replaceable>instance</replaceable></arg>
668 Show detailed information about the (given) instances. This
669 is different from <command>list</command> as it shows
670 detailed data about the instance's disks (especially useful
671 for drbd disk template).
676 <title>MODIFY</title>
679 <command>modify</command>
680 <arg choice="opt">-m <replaceable>memsize</replaceable></arg>
681 <arg choice="opt">-p <replaceable>vcpus</replaceable></arg>
682 <arg choice="opt">-i <replaceable>ip</replaceable></arg>
683 <arg choice="opt">-b <replaceable>bridge</replaceable></arg>
684 <arg choice="opt">--mac <replaceable>MAC-address</replaceable></arg>
685 <arg>--hvm-boot-order <replaceable>boot-order</replaceable></arg>
686 <arg>--hvm-acpi <replaceable>ACPI-support</replaceable></arg>
687 <arg>--hvm-pae <replaceable>PAE-support</replaceable></arg>
688 <arg>--hvm-cdrom-image-path
689 <replaceable>cdrom-image-path</replaceable></arg>
690 <arg>--hvm-nic-type <replaceable>NICTYPE</replaceable></arg>
691 <arg>--hvm-disk-type <replaceable>DISKTYPE</replaceable></arg>
692 <arg>--vnc-bind-address
693 <replaceable>vnc-bind-address</replaceable></arg>
696 <arg>--kernel <group choice="req">
698 <arg><replaceable>kernel_path</replaceable></arg>
701 <arg>--initrd <group choice="req">
704 <arg><replaceable>initrd_path</replaceable></arg>
707 <arg choice="req"><replaceable>instance</replaceable></arg>
711 Modify the memory size, number of vcpus, ip address, MAC
712 address and/or bridge for an instance.
716 The memory size is given in MiB. Note that you need to give
717 at least one of the arguments, otherwise the command
722 The <option>--kernel</option>, <option>--initrd</option>
723 and <option>--hvm-boot-order</option>
724 options are described in the <command>add</command> command.
728 Additionally, the HVM boot order can be reset to the default
729 values by using <option>--hvm-boot-order=default</option>.
733 The <option>--hvm-acpi</option> option specifies if Xen
734 should enable ACPI support for this HVM instance. Valid
735 values are true or false.
739 The <option>--hvm-pae</option> option specifies if Xen
740 should enabled PAE support for this HVM instance. Valid
741 values are true or false.
745 The <option>--hvm-cdrom-image-path</option> specifies the
746 path to the file xen uses to emulate a virtual CDROM drive
747 for this HVM instance. Valid values are either an
748 absolute path to an existing file or None, which disables
749 virtual CDROM support for this instance.
753 The <option>--hvm-nic-type</option> specifies the NIC type
754 Xen should use for this HVM instance. Valid choices are
755 rtl8139, ne2k_pci, ne2k_isa and paravirtual with rtl8139
756 as the default. The paravirtual setting is intended for use
757 with the GPL PV drivers inside HVM Windows instances.
761 The <option>--hvm-disk-type</option> specifies the disk type
762 Xen should use for the HVM instance. Valid choices are ioemu
763 and paravirtual with ioemu as the default. The paravirtual
764 setting is intended for use with the GPL PV drivers inside
765 HVM Windows instances.
769 The <option>--vnc-bind-address</option> specifies the
770 address that the VNC listener for this instance should bind
771 to. Valid values are IPv4 addresses. Use the address 0.0.0.0
772 to bind to all available interfaces.
776 All the changes take effect at the next restart. If the
777 instance is running, there is no effect on the instance.
782 <title>REINSTALL</title>
785 <command>reinstall</command>
786 <arg choice="opt">-o <replaceable>os-type</replaceable></arg>
787 <arg choice="opt">-f <replaceable>force</replaceable></arg>
788 <arg>--select-os</arg>
789 <arg choice="req"><replaceable>instance</replaceable></arg>
793 Reinstalls the operating system on the given instance. The instance
794 must be stopped when running this command. If the
795 <option>--os-type</option> is specified, the operating system is
800 The <option>--select-os</option> option switches to an
801 interactive OS reinstall. The user is prompted to select the OS
802 template from the list of available OS templates.
807 <title>RENAME</title>
810 <command>rename</command>
811 <arg>--no-ip-check</arg>
812 <arg choice="req"><replaceable>instance</replaceable></arg>
813 <arg choice="req"><replaceable>new_name</replaceable></arg>
817 Renames the given instance. The instance must be stopped
818 when running this command. The requirements for the new name
819 are the same as for adding an instance: the new name must be
820 resolvable and the IP it resolves to must not be reachable
821 (in order to prevent duplicate IPs the next time the
822 instance is started). The IP test can be skipped if the
823 <option>--no-ip-check</option> option is passed.
830 <title>Starting/stopping/connecting to console</title>
833 <title>STARTUP</title>
836 <command>startup</command>
837 <arg>--extra=<replaceable>PARAMS</replaceable></arg>
841 <arg>--instance</arg>
844 <arg>--secondary</arg>
849 rep="repeat"><replaceable>name</replaceable></arg>
853 Starts one or more instances, depending on the following
854 options. The four available modes are:
857 <term><option>--instance</option></term>
859 <simpara>will start the instances given as arguments
860 (at least one argument required); this is the default
867 <simpara>will start the instances who have the given
868 node as either primary or secondary</simpara>
872 <term><option>--primary</option></term>
874 <simpara>will start all instances whose primary node
875 is in the list of nodes passed as arguments (at least
876 one node required)</simpara>
880 <term><option>--secondary</option></term>
882 <simpara>will start all instances whose secondary node
883 is in the list of nodes passed as arguments (at least
884 one node required)</simpara>
890 <simpara>will start all instances in the cluster (no
891 arguments accepted)</simpara>
898 Note that although you can pass more than one selection
899 option, the last one wins, so in order to guarantee the
900 desired result, don't pass more than one such option.
904 The <option>--extra</option> option is used to pass
905 additional argument to the instance's kernel for this start
906 only. Currently there is no way to specify a persistent set
907 of arguments (beside the one hardcoded). Note that this may
908 not apply to all virtualization types.
912 Use <option>--force</option> to start even if secondary disks are
919 # gnt-instance start instance1.example.com
920 # gnt-instance start --extra single test1.example.com
921 # gnt-instance start --node node1.example.com node2.example.com
922 # gnt-instance start --all
928 <title>SHUTDOWN</title>
931 <command>shutdown</command>
934 <arg>--instance</arg>
937 <arg>--secondary</arg>
943 rep="repeat"><replaceable>name</replaceable></arg>
947 Stops one or more instances. If the instance cannot be
948 cleanly stopped during a hardcoded interval (currently 2
949 minutes), it will forcibly stop the instance (equivalent to
950 switching off the power on a physical machine).
954 The <option>--instance</option>, <option>--node</option>,
955 <option>--primary</option>, <option>--secondary</option> and
956 <option>--all</option> options are similar as for the
957 <command>startup</command> command and they influence the
958 actual instances being shutdown.
964 # gnt-instance shutdown instance1.example.com
965 # gnt-instance shutdown --all
971 <title>REBOOT</title>
974 <command>reboot</command>
976 <arg>--extra=<replaceable>PARAMS</replaceable></arg>
978 <arg>--type=<replaceable>REBOOT-TYPE</replaceable></arg>
980 <arg>--ignore-secondaries</arg>
982 <arg>--force-multiple</arg>
985 <arg>--instance</arg>
988 <arg>--secondary</arg>
994 rep="repeat"><replaceable>name</replaceable></arg>
998 Reboots one or more instances. The type of reboot depends on
999 the value of <option>--type</option>. A soft reboot does a
1000 hypervisor reboot, a hard reboot does a instance stop,
1001 recreates the hypervisor config for the instance and
1002 starts the instance. A full reboot does the equivalent
1003 of <command>gnt-instance shutdown && gnt-instance
1004 startup</command>. The default is hard reboot.
1008 For the hard reboot the option
1009 <option>--ignore-secondaries</option> ignores errors for the
1010 secondary node while re-assembling the instance disks.
1014 The <option>--instance</option>, <option>--node</option>,
1015 <option>--primary</option>, <option>--secondary</option> and
1016 <option>--all</option> options are similar as for the
1017 <command>startup</command> command and they influence the
1018 actual instances being rebooted.
1022 Use the <option>--force-multiple</option> option to keep
1023 gnt-instance from asking for confirmation when more than one
1024 instance is affected.
1030 # gnt-instance reboot instance1.example.com
1031 # gnt-instance reboot --type=full instance1.example.com
1037 <title>CONSOLE</title>
1039 <command>console</command>
1040 <arg choice="opt">--show-cmd</arg>
1041 <arg choice="req"><replaceable>instance</replaceable></arg>
1045 Connects to the console of the given instance. If the instance
1046 is not up, an error is returned. Use the <option>--show-cmd</option>
1047 option to display the command instead of executing it.
1051 For HVM instances, this will attempt to connect to the serial
1052 console of the instance. To connect to the virtualized
1053 "physical" console of a HVM instance, use a VNC client with
1054 the connection info from gnt-instance info.
1060 # gnt-instance console instance1.example.com
1068 <title>Disk management</title>
1071 <title>REPLACE-DISKS</title>
1074 <command>replace-disks</command>
1076 <group choice="req">
1077 <arg>--iallocator <replaceable>name</replaceable></arg>
1078 <arg>--new-secondary <replaceable>NODE</replaceable></arg>
1082 <arg choice="opt">-s</arg>
1083 <arg choice="req"><replaceable>instance</replaceable></arg>
1087 <command>replace-disks</command>
1090 <arg choice="req">-s</arg>
1091 <arg choice="req">-p</arg>
1093 <arg choice="req"><replaceable>instance</replaceable></arg>
1097 This command is a generalized form for adding and replacing
1098 disks. It is currently only valid for the mirrored (DRBD)
1103 The first form will do a secondary node change, while the
1104 second form will replace the disks on either the primary
1105 (<option>-p</option>) or the secondary (<option>-s</option>)
1106 node of the instance only, without changing the node.
1110 Specifying <option>--iallocator</option> enables secondary node
1111 replacement and and makes the new secondary be selected automatically
1112 by the specified allocator plugin.
1117 <title>ACTIVATE-DISKS</title>
1120 <command>activate-disks</command>
1121 <arg choice="req"><replaceable>instance</replaceable></arg>
1124 Activates the block devices of the given instance. If
1125 successful, the command will show the location and name of
1128 node1.example.com:sda:/dev/drbd0
1129 node1.example.com:sdb:/dev/drbd1
1132 In this example, <emphasis>node1.example.com</emphasis> is
1133 the name of the node on which the devices have been
1134 activated. The <emphasis>sda</emphasis> and
1135 <emphasis>sdb</emphasis> are the names of the block devices
1136 inside the instance. <emphasis>/dev/drbd0</emphasis> and
1137 <emphasis>/dev/drbd1</emphasis> are the names of the block
1138 devices as visible on the node.
1142 Note that it is safe to run this command while the instance
1148 <title>DEACTIVATE-DISKS</title>
1151 <command>deactivate-disks</command>
1152 <arg choice="req"><replaceable>instance</replaceable></arg>
1155 De-activates the block devices of the given instance. Note
1156 that if you run this command for an instance with a drbd
1157 disk template, while it is running, it will not be able to
1158 shutdown the block devices on the primary node, but it will
1159 shutdown the block devices on the secondary nodes, thus
1160 breaking the replication.
1166 <title>GROW-DISK</title>
1168 <command>grow-disk</command>
1169 <arg choice="req"><replaceable>instance</replaceable></arg>
1170 <arg choice="req"><replaceable>disk</replaceable></arg>
1171 <arg choice="req"><replaceable>amount</replaceable></arg>
1175 Grows an instance's disk. This is only possible for
1176 instances having a <literal>plain</literal> or
1177 <literal>drbd</literal> disk template.
1181 Note that this command only change the block device size; it
1182 will not grow the actual filesystems, partitions, etc. that
1183 live on that disk. Usually, you will need to:
1186 <simpara>use <command>gnt-instance grow-disk</command></simpara>
1189 <simpara>reboot the instance (later, at a convenient
1193 <simpara>use a filesystem resizer, such as
1194 <citerefentry> <refentrytitle>ext2online</refentrytitle>
1195 <manvolnum>8</manvolnum> </citerefentry> or
1196 <citerefentry> <refentrytitle>xfs_growfs</refentrytitle>
1197 <manvolnum>8</manvolnum> </citerefentry> to resize the
1198 filesystem, or use <citerefentry>
1199 <refentrytitle>fdisk</refentrytitle>
1200 <manvolnum>8</manvolnum> </citerefentry> to change the
1201 partition table on the disk
1209 The <replaceable>disk</replaceable> argument is either
1210 <literal>sda</literal> or <literal>sdb</literal>. The
1211 <replaceable>amount</replaceable> argument is given either
1212 as a number (and it represents the amount to increase the
1213 disk with in mebibytes) or can be given similar to the
1214 arguments in the create instance operation, with a suffix
1219 Note that the disk grow operation might complete on one node
1220 but fail on the other; this will leave the instance with
1221 different-sized LVs on the two nodes, but this will not
1222 create problems (except for unused space).
1225 <para>Example (increasing sda for instance1 with 16GiB):
1227 # gnt-instance grow-disk instance1.example.com sda 16g
1232 Also note that disk shrinking will not be supported; use
1233 <command>gnt-backup export</command> and then
1234 <command>gnt-backup import</command> to reduce the disk size
1242 <title>Recovery</title>
1245 <title>FAILOVER</title>
1248 <command>failover</command>
1250 <arg>--ignore-consistency</arg>
1251 <arg choice="req"><replaceable>instance</replaceable></arg>
1255 Failover will fail the instance over its secondary
1256 node. This works only for instances having a drbd disk
1261 Normally the failover will check the consistency of the
1262 disks before failing over the instance. If you are trying to
1263 migrate instances off a dead node, this will fail. Use the
1264 <option>--ignore-consistency</option> option for this
1265 purpose. Note that this option can be dangerous as errors in
1266 shutting down the instance will be ignored, resulting in
1267 possibly having the instance running on two machines in
1268 parallel (on disconnected DRBD drives).
1274 # gnt-instance failover instance1.example.com
1285 <title>ADD-TAGS</title>
1288 <command>add-tags</command>
1289 <arg choice="opt">--from <replaceable>file</replaceable></arg>
1290 <arg choice="req"><replaceable>instancename</replaceable></arg>
1292 rep="repeat"><replaceable>tag</replaceable></arg>
1296 Add tags to the given instance. If any of the tags contains
1297 invalid characters, the entire operation will abort.
1300 If the <option>--from</option> option is given, the list of
1301 tags will be extended with the contents of that file (each
1302 line becomes a tag). In this case, there is not need to pass
1303 tags on the command line (if you do, both sources will be
1304 used). A file name of - will be interpreted as stdin.
1309 <title>LIST-TAGS</title>
1312 <command>list-tags</command>
1313 <arg choice="req"><replaceable>instancename</replaceable></arg>
1316 <para>List the tags of the given instance.</para>
1320 <title>REMOVE-TAGS</title>
1322 <command>remove-tags</command>
1323 <arg choice="opt">--from <replaceable>file</replaceable></arg>
1324 <arg choice="req"><replaceable>instancename</replaceable></arg>
1326 rep="repeat"><replaceable>tag</replaceable></arg>
1330 Remove tags from the given instance. If any of the tags are
1331 not existing on the node, the entire operation will abort.
1335 If the <option>--from</option> option is given, the list of
1336 tags will be extended with the contents of that file (each
1337 line becomes a tag). In this case, there is not need to pass
1338 tags on the command line (if you do, both sources will be
1339 used). A file name of - will be interpreted as stdin.
1351 <!-- Keep this comment at the end of the file
1356 sgml-minimize-attributes:nil
1357 sgml-always-quote-attributes:t
1360 sgml-parent-document:nil
1361 sgml-default-dtd-file:nil
1362 sgml-exposed-tags:nil
1363 sgml-local-catalogs:nil
1364 sgml-local-ecat-files:nil