Statistics
| Branch: | Tag: | Revision:

root / man / gnt-instance.sgml @ 7e9366f7

History | View | Annotate | Download (48 kB)

1 a8083063 Iustin Pop
<!doctype refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN" [
2 a8083063 Iustin Pop
3 a8083063 Iustin Pop
  <!-- Fill in your name for FIRSTNAME and SURNAME. -->
4 a8083063 Iustin Pop
  <!-- Please adjust the date whenever revising the manpage. -->
5 a53a1b18 Michael Hanselmann
  <!ENTITY dhdate      "<date>May 29, 2008</date>">
6 a8083063 Iustin Pop
  <!-- SECTION should be 1-8, maybe w/ subsection other parameters are
7 a8083063 Iustin Pop
       allowed: see man(7), man(1). -->
8 a8083063 Iustin Pop
  <!ENTITY dhsection   "<manvolnum>8</manvolnum>">
9 a8083063 Iustin Pop
  <!ENTITY dhucpackage "<refentrytitle>gnt-instance</refentrytitle>">
10 a8083063 Iustin Pop
  <!ENTITY dhpackage   "gnt-instance">
11 a8083063 Iustin Pop
12 a8083063 Iustin Pop
  <!ENTITY debian      "<productname>Debian</productname>">
13 a8083063 Iustin Pop
  <!ENTITY gnu         "<acronym>GNU</acronym>">
14 a8083063 Iustin Pop
  <!ENTITY gpl         "&gnu; <acronym>GPL</acronym>">
15 a8083063 Iustin Pop
  <!ENTITY footer SYSTEM "footer.sgml">
16 a8083063 Iustin Pop
]>
17 a8083063 Iustin Pop
18 a8083063 Iustin Pop
<refentry>
19 a8083063 Iustin Pop
  <refentryinfo>
20 a8083063 Iustin Pop
    <copyright>
21 a8083063 Iustin Pop
      <year>2006</year>
22 a8083063 Iustin Pop
      <year>2007</year>
23 a53a1b18 Michael Hanselmann
      <year>2008</year>
24 a8083063 Iustin Pop
      <holder>Google Inc.</holder>
25 a8083063 Iustin Pop
    </copyright>
26 a8083063 Iustin Pop
    &dhdate;
27 a8083063 Iustin Pop
  </refentryinfo>
28 a8083063 Iustin Pop
  <refmeta>
29 a8083063 Iustin Pop
    &dhucpackage;
30 a8083063 Iustin Pop
31 a8083063 Iustin Pop
    &dhsection;
32 a8083063 Iustin Pop
    <refmiscinfo>ganeti 1.2</refmiscinfo>
33 a8083063 Iustin Pop
  </refmeta>
34 a8083063 Iustin Pop
  <refnamediv>
35 a8083063 Iustin Pop
    <refname>&dhpackage;</refname>
36 a8083063 Iustin Pop
37 a8083063 Iustin Pop
    <refpurpose>ganeti instance administration</refpurpose>
38 a8083063 Iustin Pop
  </refnamediv>
39 a8083063 Iustin Pop
  <refsynopsisdiv>
40 a8083063 Iustin Pop
    <cmdsynopsis>
41 a8083063 Iustin Pop
      <command>&dhpackage; </command>
42 a8083063 Iustin Pop
43 a8083063 Iustin Pop
      <arg choice="req">command</arg>
44 a8083063 Iustin Pop
      <arg>arguments...</arg>
45 a8083063 Iustin Pop
    </cmdsynopsis>
46 a8083063 Iustin Pop
  </refsynopsisdiv>
47 a8083063 Iustin Pop
  <refsect1>
48 a8083063 Iustin Pop
    <title>DESCRIPTION</title>
49 a8083063 Iustin Pop
50 a8083063 Iustin Pop
    <para>
51 a8083063 Iustin Pop
      The <command>&dhpackage;</command> is used for instance
52 a8083063 Iustin Pop
      administration in the ganeti system.
53 a8083063 Iustin Pop
    </para>
54 a8083063 Iustin Pop
55 a8083063 Iustin Pop
  </refsect1>
56 a8083063 Iustin Pop
  <refsect1>
57 a8083063 Iustin Pop
    <title>COMMANDS</title>
58 a8083063 Iustin Pop
59 a8083063 Iustin Pop
    <refsect2>
60 a8083063 Iustin Pop
      <title>Creation/removal/querying</title>
61 a8083063 Iustin Pop
62 a8083063 Iustin Pop
      <refsect3>
63 a8083063 Iustin Pop
        <title>ADD</title>
64 a8083063 Iustin Pop
        <cmdsynopsis>
65 a8083063 Iustin Pop
          <command>add</command>
66 a8083063 Iustin Pop
          <arg>-s <replaceable>disksize</replaceable></arg>
67 b9ac33e9 Iustin Pop
          <arg>--swap-size <replaceable>disksize</replaceable></arg>
68 a8083063 Iustin Pop
          <arg>-m <replaceable>memsize</replaceable></arg>
69 b9ac33e9 Iustin Pop
          <sbr>
70 bdb7d4e8 Michael Hanselmann
71 a8083063 Iustin Pop
          <arg>-b <replaceable>bridge</replaceable></arg>
72 f3a55c90 Alexander Schreiber
          <arg>--mac <replaceable>MAC-address</replaceable></arg>
73 bdb7d4e8 Michael Hanselmann
          <sbr>
74 bdb7d4e8 Michael Hanselmann
75 25c5878d Alexander Schreiber
          <arg>--hvm-boot-order <replaceable>boot-order</replaceable></arg>
76 ca9c49d5 Iustin Pop
          <arg>--hvm-acpi <replaceable>ACPI-support</replaceable></arg>
77 783583e9 Michael Hanselmann
          <sbr>
78 783583e9 Michael Hanselmann
79 ca9c49d5 Iustin Pop
          <arg>--hvm-pae <replaceable>PAE-support</replaceable></arg>
80 783583e9 Michael Hanselmann
          <sbr>
81 783583e9 Michael Hanselmann
82 ca9c49d5 Iustin Pop
          <arg>--hvm-cdrom-image-path
83 ca9c49d5 Iustin Pop
            <replaceable>cdrom-image-path</replaceable></arg>
84 783583e9 Michael Hanselmann
          <sbr>
85 783583e9 Michael Hanselmann
86 02d2adf4 Alexander Schreiber
          <arg>--hvm-nic-type <replaceable>NICTYPE</replaceable></arg>
87 02d2adf4 Alexander Schreiber
          <sbr>
88 02d2adf4 Alexander Schreiber
89 02d2adf4 Alexander Schreiber
          <arg>--hvm-disk-type
90 87765cb0 Guido Trotter
          <replaceable>DISKTYPE</replaceable></arg>
91 02d2adf4 Alexander Schreiber
          <sbr>
92 02d2adf4 Alexander Schreiber
93 ca9c49d5 Iustin Pop
          <arg>--vnc-bind-address
94 ca9c49d5 Iustin Pop
            <replaceable>vnc-bind-address</replaceable></arg>
95 a8083063 Iustin Pop
          <sbr>
96 bdb7d4e8 Michael Hanselmann
97 bdb7d4e8 Michael Hanselmann
          <arg>--kernel<group choice="req">
98 00f98619 Iustin Pop
              <arg>default</arg>
99 00f98619 Iustin Pop
              <arg><replaceable>kernel_path</replaceable></arg>
100 00f98619 Iustin Pop
            </group></arg>
101 00f98619 Iustin Pop
          <sbr>
102 bdb7d4e8 Michael Hanselmann
103 bdb7d4e8 Michael Hanselmann
          <arg>--initrd<group choice="req">
104 00f98619 Iustin Pop
              <arg>default</arg>
105 00f98619 Iustin Pop
              <arg>none</arg>
106 00f98619 Iustin Pop
              <arg><replaceable>initrd_path</replaceable></arg>
107 bdb7d4e8 Michael Hanselmann
            </group></arg>
108 00f98619 Iustin Pop
          <sbr>
109 bdb7d4e8 Michael Hanselmann
110 495beb42 Manuel Franceschini
          <arg>--file-storage-dir <replaceable>dir_path</replaceable></arg>
111 bdb7d4e8 Michael Hanselmann
          <arg>--file-driver<group choice="req">
112 495beb42 Manuel Franceschini
              <arg>loop</arg>
113 495beb42 Manuel Franceschini
              <arg>blktap</arg>
114 495beb42 Manuel Franceschini
            </group></arg>
115 495beb42 Manuel Franceschini
          <sbr>
116 bdb7d4e8 Michael Hanselmann
117 bdb7d4e8 Michael Hanselmann
          <arg choice="req">-t<group choice="req">
118 a8083063 Iustin Pop
              <arg>diskless</arg>
119 495beb42 Manuel Franceschini
              <arg>file</arg>
120 a8083063 Iustin Pop
              <arg>plain</arg>
121 f69dab6d Iustin Pop
              <arg>drbd</arg>
122 bdb7d4e8 Michael Hanselmann
            </group></arg>
123 b9ac33e9 Iustin Pop
          <sbr>
124 bdb7d4e8 Michael Hanselmann
125 a53a1b18 Michael Hanselmann
          <group choice="req">
126 a53a1b18 Michael Hanselmann
            <arg>-n <replaceable>node<optional>:secondary-node</optional></replaceable></arg>
127 a53a1b18 Michael Hanselmann
            <arg>--iallocator <replaceable>name</replaceable></arg>
128 a53a1b18 Michael Hanselmann
          </group>
129 a53a1b18 Michael Hanselmann
          <sbr>
130 a53a1b18 Michael Hanselmann
131 bdb7d4e8 Michael Hanselmann
          <arg choice="req">-o <replaceable>os-type</replaceable></arg>
132 bdb7d4e8 Michael Hanselmann
          <sbr>
133 bdb7d4e8 Michael Hanselmann
134 a8083063 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
135 a8083063 Iustin Pop
        </cmdsynopsis>
136 00f98619 Iustin Pop
137 a8083063 Iustin Pop
        <para>
138 a8083063 Iustin Pop
          Creates a new instance on the specified
139 a8083063 Iustin Pop
          host. <replaceable>instance</replaceable> must be in DNS and
140 a8083063 Iustin Pop
          resolve to a IP in the same network as the nodes in the
141 a8083063 Iustin Pop
          cluster.
142 a8083063 Iustin Pop
        </para>
143 a8083063 Iustin Pop
144 a8083063 Iustin Pop
        <para>
145 a8083063 Iustin Pop
          The <option>-s</option> option specifies the disk size for
146 b9ac33e9 Iustin Pop
          the instance, in mebibytes (defaults to
147 b9ac33e9 Iustin Pop
          <constant>20480MiB</constant> =
148 b9ac33e9 Iustin Pop
          <constant>20GiB</constant>). You can also use one of the
149 b9ac33e9 Iustin Pop
          suffixes <literal>m</literal>, <literal>g</literal> or
150 b9ac33e9 Iustin Pop
          <literal>t</literal> to specificy the exact the units used;
151 b9ac33e9 Iustin Pop
          these suffixes map to mebibytes, gibibytes and tebibytes.
152 a8083063 Iustin Pop
        </para>
153 a8083063 Iustin Pop
154 a8083063 Iustin Pop
        <para>
155 b9ac33e9 Iustin Pop
          The <option>--swap-size</option> option specifies the swap
156 b9ac33e9 Iustin Pop
          disk size (in mebibytes) for the instance (the one presented
157 b9ac33e9 Iustin Pop
          as <filename class="devicefile">/dev/sdb</filename>). The
158 b9ac33e9 Iustin Pop
          default is <constant>4096MiB</constant>. As for the disk
159 b9ac33e9 Iustin Pop
          size, you can specify other suffixes.
160 a8083063 Iustin Pop
        </para>
161 a8083063 Iustin Pop
162 a8083063 Iustin Pop
        <para>
163 a8083063 Iustin Pop
          The <option>-m</option> option specifies the memory size for
164 b9ac33e9 Iustin Pop
          the instance, in mebibytes (defaults to 128 MiB). Again, you
165 b9ac33e9 Iustin Pop
          can use other suffixes (e.g. <userinput>2g</userinput>).
166 b9ac33e9 Iustin Pop
        </para>
167 b9ac33e9 Iustin Pop
168 b9ac33e9 Iustin Pop
        <para>
169 b9ac33e9 Iustin Pop
          The <option>-o</option> options specifies the operating
170 b9ac33e9 Iustin Pop
          system to be installed. The available operating systems can
171 b9ac33e9 Iustin Pop
          be listed with <command>gnt-os list</command>.
172 a8083063 Iustin Pop
        </para>
173 a8083063 Iustin Pop
174 a8083063 Iustin Pop
        <para>
175 a8083063 Iustin Pop
          The <option>-b</option> option specifies the bridge to which the
176 a8083063 Iustin Pop
          instance will be connected. (defaults to the cluster-wide default
177 7e84d392 Michael Hanselmann
          bridge specified at cluster initialization time).
178 a8083063 Iustin Pop
        </para>
179 a8083063 Iustin Pop
180 a8083063 Iustin Pop
        <para>
181 f3a55c90 Alexander Schreiber
          The <option>--mac</option> option specifies the MAC address
182 f3a55c90 Alexander Schreiber
          of the ethernet interface for the instance. If this option
183 f3a55c90 Alexander Schreiber
          is not specified, a new MAC address is generated randomly with
184 f3a55c90 Alexander Schreiber
          the configured MAC prefix. The randomly generated MAC
185 f3a55c90 Alexander Schreiber
          address is guaranteed to be unique among the instances of
186 f3a55c90 Alexander Schreiber
          this cluster.
187 f3a55c90 Alexander Schreiber
        </para>
188 f3a55c90 Alexander Schreiber
189 f3a55c90 Alexander Schreiber
        <para>
190 25c5878d Alexander Schreiber
          The <option>--hvm-boot-order</option> option specifies the
191 25c5878d Alexander Schreiber
          boot device order for Xen HVM instances. The boot order is a
192 25c5878d Alexander Schreiber
          string of letters listing the boot devices, with valid
193 25c5878d Alexander Schreiber
          device letters being:
194 25c5878d Alexander Schreiber
        </para>
195 25c5878d Alexander Schreiber
196 25c5878d Alexander Schreiber
        <para>
197 25c5878d Alexander Schreiber
          <variablelist>
198 25c5878d Alexander Schreiber
            <varlistentry>
199 25c5878d Alexander Schreiber
              <term>a</term>
200 25c5878d Alexander Schreiber
              <listitem>
201 25c5878d Alexander Schreiber
                <para>
202 25c5878d Alexander Schreiber
                  floppy drive
203 25c5878d Alexander Schreiber
                </para>
204 25c5878d Alexander Schreiber
              </listitem>
205 25c5878d Alexander Schreiber
            </varlistentry>
206 25c5878d Alexander Schreiber
            <varlistentry>
207 25c5878d Alexander Schreiber
              <term>c</term>
208 25c5878d Alexander Schreiber
              <listitem>
209 25c5878d Alexander Schreiber
                <para>
210 25c5878d Alexander Schreiber
                  hard disk
211 25c5878d Alexander Schreiber
                </para>
212 25c5878d Alexander Schreiber
              </listitem>
213 25c5878d Alexander Schreiber
            </varlistentry>
214 25c5878d Alexander Schreiber
            <varlistentry>
215 25c5878d Alexander Schreiber
              <term>d</term>
216 25c5878d Alexander Schreiber
              <listitem>
217 25c5878d Alexander Schreiber
                <para>
218 25c5878d Alexander Schreiber
                  CDROM drive
219 25c5878d Alexander Schreiber
                </para>
220 25c5878d Alexander Schreiber
              </listitem>
221 25c5878d Alexander Schreiber
            </varlistentry>
222 25c5878d Alexander Schreiber
            <varlistentry>
223 25c5878d Alexander Schreiber
              <term>n</term>
224 25c5878d Alexander Schreiber
              <listitem>
225 25c5878d Alexander Schreiber
                <para>
226 25c5878d Alexander Schreiber
                  network boot (PXE)
227 25c5878d Alexander Schreiber
                </para>
228 25c5878d Alexander Schreiber
              </listitem>
229 25c5878d Alexander Schreiber
            </varlistentry>
230 25c5878d Alexander Schreiber
          </variablelist>
231 25c5878d Alexander Schreiber
        </para>
232 25c5878d Alexander Schreiber
233 25c5878d Alexander Schreiber
        <para>
234 c6520286 Alexander Schreiber
          The default is not to set an HVM boot order which is
235 c6520286 Alexander Schreiber
          interpreted as 'dc'. This option, like all options starting
236 c6520286 Alexander Schreiber
          with 'hvm', is only relevant for Xen HVM instances and
237 c6520286 Alexander Schreiber
          ignored by all other instance types.
238 25c5878d Alexander Schreiber
        </para>
239 25c5878d Alexander Schreiber
240 25c5878d Alexander Schreiber
        <para>
241 ca9c49d5 Iustin Pop
          The <option>--hvm-acpi</option> option specifies if Xen
242 ca9c49d5 Iustin Pop
          should enable ACPI support for this HVM instance. Valid
243 c6520286 Alexander Schreiber
          values are true or false. The default value is false,
244 c6520286 Alexander Schreiber
          disabling ACPI support for this instance.
245 ca9c49d5 Iustin Pop
        </para>
246 ca9c49d5 Iustin Pop
247 ca9c49d5 Iustin Pop
        <para>
248 ca9c49d5 Iustin Pop
          The <option>--hvm-pae</option> option specifies if Xen
249 ca9c49d5 Iustin Pop
          should enabled PAE support for this HVM instance. Valid
250 c6520286 Alexander Schreiber
          values are true or false. The default is false, disabling
251 c6520286 Alexander Schreiber
          PAE support for this instance.
252 ca9c49d5 Iustin Pop
        </para>
253 ca9c49d5 Iustin Pop
254 ca9c49d5 Iustin Pop
        <para>
255 a53a1b18 Michael Hanselmann
          The <option>--hvm-cdrom-image-path</option> option specifies the
256 c6520286 Alexander Schreiber
          path to the file Xen uses to emulate a virtual CDROM drive
257 ca9c49d5 Iustin Pop
          for this HVM instance. Valid values are either an
258 ca9c49d5 Iustin Pop
          absolute path to an existing file or None, which disables
259 c6520286 Alexander Schreiber
          virtual CDROM support for this instance. The default is
260 c6520286 Alexander Schreiber
          None, disabling virtual CDROM support.
261 ca9c49d5 Iustin Pop
        </para>
262 ca9c49d5 Iustin Pop
263 ca9c49d5 Iustin Pop
        <para>
264 02d2adf4 Alexander Schreiber
          The <option>--hvm-nic-type</option> specifies the NIC type
265 02d2adf4 Alexander Schreiber
          Xen should use for this HVM instance. Valid choices are
266 02d2adf4 Alexander Schreiber
          rtl8139, ne2k_pci, ne2k_isa and paravirtual with rtl8139
267 02d2adf4 Alexander Schreiber
          as the default. The paravirtual setting is intended for use
268 02d2adf4 Alexander Schreiber
          with the GPL PV drivers inside HVM Windows instances.
269 02d2adf4 Alexander Schreiber
        </para>
270 02d2adf4 Alexander Schreiber
271 02d2adf4 Alexander Schreiber
        <para>
272 02d2adf4 Alexander Schreiber
          The <option>--hvm-disk-type</option> specifies the disk type
273 02d2adf4 Alexander Schreiber
          Xen should use for the HVM instance. Valid choices are ioemu
274 02d2adf4 Alexander Schreiber
          and paravirtual with ioemu as the default. The paravirtual
275 02d2adf4 Alexander Schreiber
          setting is intended for use with the GPL PV drivers inside
276 02d2adf4 Alexander Schreiber
          HVM Windows instances.
277 02d2adf4 Alexander Schreiber
        </para>
278 02d2adf4 Alexander Schreiber
279 02d2adf4 Alexander Schreiber
        <para>
280 a53a1b18 Michael Hanselmann
          The <option>--vnc-bind-address</option> option specifies the
281 ca9c49d5 Iustin Pop
          address that the VNC listener for this instance should bind
282 ca9c49d5 Iustin Pop
          to. Valid values are IPv4 addresses. Use the address 0.0.0.0
283 c6520286 Alexander Schreiber
          to bind to all available interfaces (this is the default)
284 c6520286 Alexander Schreiber
          or specify the address of one of the interfaces on the node
285 c6520286 Alexander Schreiber
          to restrict listening to that interface.
286 ca9c49d5 Iustin Pop
        </para>
287 ca9c49d5 Iustin Pop
288 ca9c49d5 Iustin Pop
        <para>
289 a53a1b18 Michael Hanselmann
          The <option>--iallocator</option> option specifies the instance
290 a53a1b18 Michael Hanselmann
          allocator plugin to use. If you pass in this option the allocator
291 a53a1b18 Michael Hanselmann
          will select nodes for this instance automatically, so you don't need
292 a53a1b18 Michael Hanselmann
          to pass them with the <option>-n</option> option. For more
293 a53a1b18 Michael Hanselmann
          information please refer to the instance allocator documentation.
294 a53a1b18 Michael Hanselmann
        </para>
295 a53a1b18 Michael Hanselmann
296 a53a1b18 Michael Hanselmann
        <para>
297 a53a1b18 Michael Hanselmann
          The <option>--kernel</option> option allows the instance to
298 00f98619 Iustin Pop
          use a custom kernel (if a filename is passed) or to use the
299 00f98619 Iustin Pop
          default kernel (<filename>@CUSTOM_XEN_KERNEL@</filename>), if the
300 00f98619 Iustin Pop
          string <constant>default</constant> is passed.
301 00f98619 Iustin Pop
        </para>
302 00f98619 Iustin Pop
303 00f98619 Iustin Pop
        <para>
304 00f98619 Iustin Pop
          The <option>--initrd</option> option is similar: it allows
305 00f98619 Iustin Pop
          the instance to use a custom initrd (if a filename is
306 00f98619 Iustin Pop
          passed) or to use the default initrd
307 00f98619 Iustin Pop
          (<filename>@CUSTOM_XEN_INITRD@</filename>), if the string
308 00f98619 Iustin Pop
          <constant>default</constant> is passed, or to disable the
309 00f98619 Iustin Pop
          use of an initrd, if the string <constant>none</constant> is
310 00f98619 Iustin Pop
          passed. Note that in the case the instance is set to use the
311 00f98619 Iustin Pop
          default initrd and it doesn't exist, it will be silently
312 00f98619 Iustin Pop
          ignored; if the instance is set to use a custom initrd and
313 00f98619 Iustin Pop
          it doesn't exist, this will be treated as an error and will
314 00f98619 Iustin Pop
          prevent the startup of the instance.
315 00f98619 Iustin Pop
        </para>
316 00f98619 Iustin Pop
317 00f98619 Iustin Pop
        <para>
318 a8083063 Iustin Pop
          The <option>-t</option> options specifies the disk layout type for
319 a8083063 Iustin Pop
          the instance. The available choices are:
320 a8083063 Iustin Pop
          <variablelist>
321 a8083063 Iustin Pop
            <varlistentry>
322 a8083063 Iustin Pop
              <term>diskless</term>
323 a8083063 Iustin Pop
              <listitem>
324 a8083063 Iustin Pop
                <para>
325 a8083063 Iustin Pop
                  This creates an instance with no disks. Its useful for
326 a8083063 Iustin Pop
                  testing only (or other special cases).
327 a8083063 Iustin Pop
                </para>
328 a8083063 Iustin Pop
              </listitem>
329 a8083063 Iustin Pop
            </varlistentry>
330 a8083063 Iustin Pop
            <varlistentry>
331 495beb42 Manuel Franceschini
              <term>file</term>
332 495beb42 Manuel Franceschini
              <listitem>
333 495beb42 Manuel Franceschini
                <para>Disk devices will be regular files.</para>
334 495beb42 Manuel Franceschini
              </listitem>
335 495beb42 Manuel Franceschini
            </varlistentry>
336 495beb42 Manuel Franceschini
            <varlistentry>
337 a8083063 Iustin Pop
              <term>plain</term>
338 a8083063 Iustin Pop
              <listitem>
339 a8083063 Iustin Pop
                <para>Disk devices will be logical volumes.</para>
340 a8083063 Iustin Pop
              </listitem>
341 a8083063 Iustin Pop
            </varlistentry>
342 a8083063 Iustin Pop
            <varlistentry>
343 f69dab6d Iustin Pop
              <term>drbd</term>
344 f69dab6d Iustin Pop
              <listitem>
345 f69dab6d Iustin Pop
                <para>
346 f69dab6d Iustin Pop
                  Disk devices will be drbd (version 8.x) on top of
347 f9193417 Iustin Pop
                  lvm volumes.
348 a8083063 Iustin Pop
                </para>
349 a8083063 Iustin Pop
              </listitem>
350 a8083063 Iustin Pop
            </varlistentry>
351 a8083063 Iustin Pop
          </variablelist>
352 a8083063 Iustin Pop
        </para>
353 a8083063 Iustin Pop
354 a8083063 Iustin Pop
        <para>
355 4677a909 Michael Hanselmann
          The optional second value of the <option>--node</option> is used for
356 bd028152 Iustin Pop
          the drbd template type and specifies the remote node.
357 a8083063 Iustin Pop
        </para>
358 a8083063 Iustin Pop
359 a8083063 Iustin Pop
        <para>
360 a8083063 Iustin Pop
          If you do not want gnt-instance to wait for the disk mirror
361 a8083063 Iustin Pop
          to be synced, use the <option>--no-wait-for-sync</option>
362 a8083063 Iustin Pop
          option.
363 a8083063 Iustin Pop
        </para>
364 a8083063 Iustin Pop
365 a8083063 Iustin Pop
        <para>
366 495beb42 Manuel Franceschini
          The <option>--file-storage-dir</option> specifies the relative path
367 495beb42 Manuel Franceschini
          under the cluster-wide file storage directory to store file-based
368 495beb42 Manuel Franceschini
          disks. It is useful for having different subdirectories for
369 495beb42 Manuel Franceschini
          different instances. The full path of the directory where the disk
370 495beb42 Manuel Franceschini
          files are stored will consist of cluster-wide file storage directory
371 495beb42 Manuel Franceschini
          + optional subdirectory + instance name. Example:
372 495beb42 Manuel Franceschini
          /srv/ganeti/file-storage/mysubdir/instance1.example.com. This option
373 495beb42 Manuel Franceschini
          is only relevant for instances using the file storage backend.
374 495beb42 Manuel Franceschini
        </para>
375 495beb42 Manuel Franceschini
376 495beb42 Manuel Franceschini
        <para>
377 495beb42 Manuel Franceschini
          The <option>--file-driver</option> specifies the driver to use for
378 495beb42 Manuel Franceschini
          file-based disks. Note that currently these drivers work with the
379 495beb42 Manuel Franceschini
          xen hypervisor only. This option is only relevant for instances using
380 495beb42 Manuel Franceschini
          the file storage backend. The available choices are:
381 495beb42 Manuel Franceschini
          <variablelist>
382 495beb42 Manuel Franceschini
            <varlistentry>
383 495beb42 Manuel Franceschini
              <term>loop</term>
384 495beb42 Manuel Franceschini
              <listitem>
385 495beb42 Manuel Franceschini
                <para>Kernel loopback driver.</para>
386 495beb42 Manuel Franceschini
              </listitem>
387 495beb42 Manuel Franceschini
            </varlistentry>
388 495beb42 Manuel Franceschini
            <varlistentry>
389 495beb42 Manuel Franceschini
              <term>blktap</term>
390 495beb42 Manuel Franceschini
              <listitem>
391 495beb42 Manuel Franceschini
                <para>blktap driver.</para>
392 495beb42 Manuel Franceschini
              </listitem>
393 495beb42 Manuel Franceschini
            </varlistentry>
394 67470f58 Iustin Pop
          </variablelist>
395 495beb42 Manuel Franceschini
        </para>
396 495beb42 Manuel Franceschini
397 495beb42 Manuel Franceschini
        <para>
398 495beb42 Manuel Franceschini
          The loop driver uses loopback devices to access the filesystem
399 495beb42 Manuel Franceschini
          within the file. However, running I/O intensive applications
400 495beb42 Manuel Franceschini
          in your instance using the loop driver might result in slowdowns.
401 495beb42 Manuel Franceschini
          Furthermore, if you use the loopback driver consider increasing
402 495beb42 Manuel Franceschini
          the maximum amount of loopback devices (on most systems it's 8)
403 495beb42 Manuel Franceschini
          using the max_loop param.
404 495beb42 Manuel Franceschini
        </para>
405 495beb42 Manuel Franceschini
406 495beb42 Manuel Franceschini
        <para>
407 495beb42 Manuel Franceschini
          In order to be able to use the blktap driver you should check
408 495beb42 Manuel Franceschini
          if the 'blktapctrl' user space disk agent is running (usually
409 495beb42 Manuel Franceschini
          automatically started via xend). This user-level disk I/O
410 495beb42 Manuel Franceschini
          interface has the advantage of better performance. Especially
411 495beb42 Manuel Franceschini
          if you use a network file system (e.g. NFS) to store your instances
412 495beb42 Manuel Franceschini
          this is the recommended choice.
413 bd028152 Iustin Pop
        </para>
414 495beb42 Manuel Franceschini
415 495beb42 Manuel Franceschini
        <para>
416 a8083063 Iustin Pop
          Example:
417 a8083063 Iustin Pop
          <screen>
418 495beb42 Manuel Franceschini
# gnt-instance add -t file -s 30g -m 512 -o debian-etch \
419 495beb42 Manuel Franceschini
  -n node1.example.com --file-storage-dir=mysubdir instance1.example.com
420 b9ac33e9 Iustin Pop
# gnt-instance add -t plain -s 30g -m 512 -o debian-etch \
421 b9ac33e9 Iustin Pop
  -n node1.example.com instance1.example.com
422 f9193417 Iustin Pop
# gnt-instance add -t drbd -s 30g -m 512 -o debian-etch \
423 4677a909 Michael Hanselmann
  -n node1.example.com:node2.example.com instance2.example.com
424 a8083063 Iustin Pop
          </screen>
425 a8083063 Iustin Pop
        </para>
426 a8083063 Iustin Pop
      </refsect3>
427 a8083063 Iustin Pop
428 a8083063 Iustin Pop
      <refsect3>
429 a8083063 Iustin Pop
        <title>REMOVE</title>
430 a8083063 Iustin Pop
431 a8083063 Iustin Pop
        <cmdsynopsis>
432 a8083063 Iustin Pop
          <command>remove</command>
433 1d67656e Iustin Pop
          <arg>--ignore-failures</arg>
434 a8083063 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
435 a8083063 Iustin Pop
        </cmdsynopsis>
436 a8083063 Iustin Pop
437 a8083063 Iustin Pop
        <para>
438 a8083063 Iustin Pop
          Remove an instance. This will remove all data from the
439 a8083063 Iustin Pop
          instance and there is <emphasis>no way back</emphasis>. If
440 a8083063 Iustin Pop
          you are not sure if you use an instance again, use
441 a8083063 Iustin Pop
          <command>shutdown</command> first and leave it in the
442 a8083063 Iustin Pop
          shutdown state for a while.
443 1d67656e Iustin Pop
444 1d67656e Iustin Pop
        </para>
445 1d67656e Iustin Pop
446 1d67656e Iustin Pop
        <para>
447 1d67656e Iustin Pop
          The <option>--ignore-failures</option> option will cause the
448 1d67656e Iustin Pop
          removal to proceed even in the presence of errors during the
449 1d67656e Iustin Pop
          removal of the instance (e.g. during the shutdown or the
450 1d67656e Iustin Pop
          disk removal). If this option is not given, the command will
451 1d67656e Iustin Pop
          stop at the first error.
452 a8083063 Iustin Pop
        </para>
453 a8083063 Iustin Pop
454 a8083063 Iustin Pop
        <para>
455 a8083063 Iustin Pop
          Example:
456 a8083063 Iustin Pop
          <screen>
457 a8083063 Iustin Pop
# gnt-instance remove instance1.example.com
458 a8083063 Iustin Pop
          </screen>
459 a8083063 Iustin Pop
        </para>
460 a8083063 Iustin Pop
      </refsect3>
461 a8083063 Iustin Pop
462 a8083063 Iustin Pop
      <refsect3>
463 a8083063 Iustin Pop
        <title>LIST</title>
464 a8083063 Iustin Pop
465 a8083063 Iustin Pop
        <cmdsynopsis>
466 a8083063 Iustin Pop
          <command>list</command>
467 a8083063 Iustin Pop
          <arg>--no-headers</arg>
468 a8083063 Iustin Pop
          <arg>--separator=<replaceable>SEPARATOR</replaceable></arg>
469 48c4dfa8 Iustin Pop
          <arg>-o <replaceable>[+]FIELD,...</replaceable></arg>
470 a8083063 Iustin Pop
        </cmdsynopsis>
471 a8083063 Iustin Pop
472 a8083063 Iustin Pop
        <para>
473 a8083063 Iustin Pop
          Shows the currently configured instances with memory usage,
474 a8083063 Iustin Pop
          disk usage, the node they are running on, and the CPU time,
475 a8083063 Iustin Pop
          counted in seconds, used by each instance since its latest
476 a8083063 Iustin Pop
          restart.
477 a8083063 Iustin Pop
        </para>
478 a8083063 Iustin Pop
479 a8083063 Iustin Pop
        <para>
480 a8083063 Iustin Pop
          The <option>--no-headers</option> option will skip the
481 a8083063 Iustin Pop
          initial header line. The <option>--separator</option> option
482 a8083063 Iustin Pop
          takes an argument which denotes what will be used between
483 a8083063 Iustin Pop
          the output fields. Both these options are to help scripting.
484 a8083063 Iustin Pop
        </para>
485 a8083063 Iustin Pop
486 a8083063 Iustin Pop
        <para>
487 a8083063 Iustin Pop
          The <option>-o</option> option takes a comma-separated list
488 a8083063 Iustin Pop
          of output fields. The available fields and their meaning
489 a8083063 Iustin Pop
          are:
490 a8083063 Iustin Pop
          <variablelist>
491 a8083063 Iustin Pop
            <varlistentry>
492 a8083063 Iustin Pop
              <term>name</term>
493 a8083063 Iustin Pop
              <listitem>
494 a8083063 Iustin Pop
                <simpara>the instance name</simpara>
495 a8083063 Iustin Pop
              </listitem>
496 a8083063 Iustin Pop
            </varlistentry>
497 a8083063 Iustin Pop
            <varlistentry>
498 a8083063 Iustin Pop
              <term>os</term>
499 a8083063 Iustin Pop
              <listitem>
500 a8083063 Iustin Pop
                <simpara>the OS of the instance</simpara>
501 a8083063 Iustin Pop
              </listitem>
502 a8083063 Iustin Pop
            </varlistentry>
503 a8083063 Iustin Pop
            <varlistentry>
504 a8083063 Iustin Pop
              <term>pnode</term>
505 a8083063 Iustin Pop
              <listitem>
506 a8083063 Iustin Pop
                <simpara>the primary node of the instance</simpara>
507 a8083063 Iustin Pop
              </listitem>
508 a8083063 Iustin Pop
            </varlistentry>
509 a8083063 Iustin Pop
            <varlistentry>
510 a8083063 Iustin Pop
              <term>snodes</term>
511 a8083063 Iustin Pop
              <listitem>
512 4677a909 Michael Hanselmann
                <simpara>comma-separated list of secondary nodes for the
513 a8083063 Iustin Pop
                  instance; usually this will be just one node</simpara>
514 a8083063 Iustin Pop
              </listitem>
515 a8083063 Iustin Pop
            </varlistentry>
516 a8083063 Iustin Pop
            <varlistentry>
517 a8083063 Iustin Pop
              <term>admin_state</term>
518 a8083063 Iustin Pop
              <listitem>
519 a8083063 Iustin Pop
                <simpara>the desired state of the instance (either "yes"
520 a8083063 Iustin Pop
                  or "no" denoting the instance should run or
521 a8083063 Iustin Pop
                  not)</simpara>
522 a8083063 Iustin Pop
              </listitem>
523 a8083063 Iustin Pop
            </varlistentry>
524 a8083063 Iustin Pop
            <varlistentry>
525 a8083063 Iustin Pop
              <term>admin_ram</term>
526 a8083063 Iustin Pop
              <listitem>
527 a8083063 Iustin Pop
                <simpara>the desired memory for the instance</simpara>
528 a8083063 Iustin Pop
              </listitem>
529 a8083063 Iustin Pop
            </varlistentry>
530 a8083063 Iustin Pop
            <varlistentry>
531 a8083063 Iustin Pop
              <term>disk_template</term>
532 a8083063 Iustin Pop
              <listitem>
533 a8083063 Iustin Pop
                <simpara>the disk template of the instance</simpara>
534 a8083063 Iustin Pop
              </listitem>
535 a8083063 Iustin Pop
            </varlistentry>
536 a8083063 Iustin Pop
            <varlistentry>
537 a8083063 Iustin Pop
              <term>oper_state</term>
538 a8083063 Iustin Pop
              <listitem>
539 d8052456 Iustin Pop
                <simpara>the actual state of the instance; can be
540 d8052456 Iustin Pop
                one of the values "running", "stopped", "(node
541 d8052456 Iustin Pop
                down)"</simpara>
542 d8052456 Iustin Pop
              </listitem>
543 d8052456 Iustin Pop
            </varlistentry>
544 d8052456 Iustin Pop
            <varlistentry>
545 d8052456 Iustin Pop
              <term>status</term>
546 d8052456 Iustin Pop
              <listitem>
547 d8052456 Iustin Pop
                <simpara>combined form of admin_state and oper_stat;
548 d8052456 Iustin Pop
                this can be one of:
549 d8052456 Iustin Pop
                <computeroutput>ERROR_nodedown</computeroutput> if the
550 d8052456 Iustin Pop
                node of the instance is down,
551 d8052456 Iustin Pop
                <computeroutput>ERROR_down</computeroutput> if the
552 d8052456 Iustin Pop
                instance should run but is down,
553 d8052456 Iustin Pop
                <computeroutput>ERROR_up</computeroutput> if the
554 d8052456 Iustin Pop
                instance should be stopped but is actually running,
555 d8052456 Iustin Pop
                <computeroutput>ADMIN_down</computeroutput> if the
556 d8052456 Iustin Pop
                instance has been stopped (and is stopped) and
557 d8052456 Iustin Pop
                <computeroutput>running</computeroutput> if the
558 d8052456 Iustin Pop
                instance is set to be running (and is
559 d8052456 Iustin Pop
                running)</simpara>
560 a8083063 Iustin Pop
              </listitem>
561 a8083063 Iustin Pop
            </varlistentry>
562 a8083063 Iustin Pop
            <varlistentry>
563 a8083063 Iustin Pop
              <term>oper_ram</term>
564 a8083063 Iustin Pop
              <listitem>
565 a8083063 Iustin Pop
                <simpara>the actual memory usage of the instance as seen
566 a8083063 Iustin Pop
                  by the hypervisor</simpara>
567 a8083063 Iustin Pop
              </listitem>
568 a8083063 Iustin Pop
            </varlistentry>
569 a8083063 Iustin Pop
            <varlistentry>
570 a8083063 Iustin Pop
              <term>ip</term>
571 a8083063 Iustin Pop
              <listitem>
572 a8083063 Iustin Pop
                <simpara>the ip address ganeti recognizes as associated with
573 a8083063 Iustin Pop
                the instance interface</simpara>
574 a8083063 Iustin Pop
              </listitem>
575 a8083063 Iustin Pop
            </varlistentry>
576 a8083063 Iustin Pop
            <varlistentry>
577 a8083063 Iustin Pop
              <term>mac</term>
578 a8083063 Iustin Pop
              <listitem>
579 a8083063 Iustin Pop
                <simpara>the instance interface MAC address</simpara>
580 a8083063 Iustin Pop
              </listitem>
581 a8083063 Iustin Pop
            </varlistentry>
582 a8083063 Iustin Pop
            <varlistentry>
583 a8083063 Iustin Pop
              <term>bridge</term>
584 a8083063 Iustin Pop
              <listitem>
585 a8083063 Iustin Pop
                <simpara>bridge the instance is connected to
586 a8083063 Iustin Pop
                </simpara>
587 a8083063 Iustin Pop
              </listitem>
588 a8083063 Iustin Pop
            </varlistentry>
589 d8a4b51d Iustin Pop
            <varlistentry>
590 d8a4b51d Iustin Pop
              <term>sda_size</term>
591 d8a4b51d Iustin Pop
              <listitem>
592 d8a4b51d Iustin Pop
                <simpara>the size of the instance's first disk</simpara>
593 d8a4b51d Iustin Pop
              </listitem>
594 d8a4b51d Iustin Pop
            </varlistentry>
595 d8a4b51d Iustin Pop
            <varlistentry>
596 d8a4b51d Iustin Pop
              <term>sdb_size</term>
597 d8a4b51d Iustin Pop
              <listitem>
598 d8a4b51d Iustin Pop
                <simpara>the size of the instance's second disk</simpara>
599 d8a4b51d Iustin Pop
              </listitem>
600 d8a4b51d Iustin Pop
            </varlistentry>
601 d8a4b51d Iustin Pop
            <varlistentry>
602 d8a4b51d Iustin Pop
              <term>vcpus</term>
603 d8a4b51d Iustin Pop
              <listitem>
604 d8a4b51d Iustin Pop
                <simpara>the number of VCPUs allocated to the
605 d8a4b51d Iustin Pop
                instance</simpara>
606 d8a4b51d Iustin Pop
              </listitem>
607 d8a4b51d Iustin Pop
            </varlistentry>
608 130a6a6f Iustin Pop
            <varlistentry>
609 130a6a6f Iustin Pop
              <term>tags</term>
610 130a6a6f Iustin Pop
              <listitem>
611 130a6a6f Iustin Pop
                <simpara>comma-separated list of the instances's
612 130a6a6f Iustin Pop
                tags</simpara>
613 130a6a6f Iustin Pop
              </listitem>
614 130a6a6f Iustin Pop
            </varlistentry>
615 38d7239a Iustin Pop
            <varlistentry>
616 38d7239a Iustin Pop
              <term>serial_no</term>
617 38d7239a Iustin Pop
              <listitem>
618 38d7239a Iustin Pop
                <simpara>the so called 'serial number' of the
619 38d7239a Iustin Pop
                instance; this is a numeric field that is incremented
620 38d7239a Iustin Pop
                each time the instance is modified, and it can be used
621 38d7239a Iustin Pop
                to detect modifications</simpara>
622 38d7239a Iustin Pop
              </listitem>
623 38d7239a Iustin Pop
            </varlistentry>
624 a8083063 Iustin Pop
          </variablelist>
625 a8083063 Iustin Pop
        </para>
626 a8083063 Iustin Pop
627 a8083063 Iustin Pop
        <para>
628 48c4dfa8 Iustin Pop
          If the value of the option starts with the character
629 48c4dfa8 Iustin Pop
          <constant>+</constant>, the new fields will be added to the
630 48c4dfa8 Iustin Pop
          default list. This allows to quickly see the default list
631 48c4dfa8 Iustin Pop
          plus a few other fields, instead of retyping the entire list
632 48c4dfa8 Iustin Pop
          of fields.
633 48c4dfa8 Iustin Pop
        </para>
634 48c4dfa8 Iustin Pop
635 48c4dfa8 Iustin Pop
        <para>
636 a8083063 Iustin Pop
          There is a subtle grouping about the available output
637 872c949f Iustin Pop
          fields: all fields except for <option>oper_state</option>,
638 872c949f Iustin Pop
          <option>oper_ram</option> and <option>status</option> are
639 872c949f Iustin Pop
          configuration value and not run-time values. So if you don't
640 872c949f Iustin Pop
          select any of the these fields, the query will be satisfied
641 a8083063 Iustin Pop
          instantly from the cluster configuration, without having to
642 a8083063 Iustin Pop
          ask the remote nodes for the data. This can be helpful for
643 a8083063 Iustin Pop
          big clusters when you only want some data and it makes sense
644 a8083063 Iustin Pop
          to specify a reduced set of output fields.
645 a8083063 Iustin Pop
        </para>
646 a8083063 Iustin Pop
647 a8083063 Iustin Pop
        <para>The default output field list is:
648 a8083063 Iustin Pop
          <simplelist type="inline">
649 a8083063 Iustin Pop
            <member>name</member>
650 a8083063 Iustin Pop
            <member>os</member>
651 a8083063 Iustin Pop
            <member>pnode</member>
652 a8083063 Iustin Pop
            <member>admin_state</member>
653 a8083063 Iustin Pop
            <member>oper_state</member>
654 a8083063 Iustin Pop
            <member>oper_ram</member>
655 a8083063 Iustin Pop
          </simplelist>.
656 a8083063 Iustin Pop
        </para>
657 a8083063 Iustin Pop
      </refsect3>
658 a8083063 Iustin Pop
659 a8083063 Iustin Pop
      <refsect3>
660 a8083063 Iustin Pop
        <title>INFO</title>
661 a8083063 Iustin Pop
662 a8083063 Iustin Pop
        <cmdsynopsis>
663 a8083063 Iustin Pop
          <command>info</command>
664 57821cac Iustin Pop
          <group>
665 57821cac Iustin Pop
            <arg>-s</arg>
666 57821cac Iustin Pop
            <arg>--static</arg>
667 57821cac Iustin Pop
          </group>
668 a8083063 Iustin Pop
          <arg rep="repeat"><replaceable>instance</replaceable></arg>
669 a8083063 Iustin Pop
        </cmdsynopsis>
670 a8083063 Iustin Pop
671 a8083063 Iustin Pop
        <para>
672 a8083063 Iustin Pop
          Show detailed information about the (given) instances. This
673 a8083063 Iustin Pop
          is different from <command>list</command> as it shows
674 a8083063 Iustin Pop
          detailed data about the instance's disks (especially useful
675 bd028152 Iustin Pop
          for drbd disk template).
676 a8083063 Iustin Pop
        </para>
677 57821cac Iustin Pop
678 57821cac Iustin Pop
        <para>
679 57821cac Iustin Pop
          If the option <option>-s</option> is used, only information
680 57821cac Iustin Pop
          available in the configuration file is returned, without
681 57821cac Iustin Pop
          querying nodes, making the operation faster.
682 57821cac Iustin Pop
        </para>
683 a8083063 Iustin Pop
      </refsect3>
684 a8083063 Iustin Pop
685 a8083063 Iustin Pop
      <refsect3>
686 a8083063 Iustin Pop
        <title>MODIFY</title>
687 a8083063 Iustin Pop
688 a8083063 Iustin Pop
        <cmdsynopsis>
689 a8083063 Iustin Pop
          <command>modify</command>
690 a8083063 Iustin Pop
          <arg choice="opt">-m <replaceable>memsize</replaceable></arg>
691 a8083063 Iustin Pop
          <arg choice="opt">-p <replaceable>vcpus</replaceable></arg>
692 a8083063 Iustin Pop
          <arg choice="opt">-i <replaceable>ip</replaceable></arg>
693 a8083063 Iustin Pop
          <arg choice="opt">-b <replaceable>bridge</replaceable></arg>
694 61854511 Iustin Pop
          <arg choice="opt">--mac <replaceable>MAC-address</replaceable></arg>
695 25c5878d Alexander Schreiber
          <arg>--hvm-boot-order <replaceable>boot-order</replaceable></arg>
696 ca9c49d5 Iustin Pop
          <arg>--hvm-acpi <replaceable>ACPI-support</replaceable></arg>
697 ca9c49d5 Iustin Pop
          <arg>--hvm-pae <replaceable>PAE-support</replaceable></arg>
698 ca9c49d5 Iustin Pop
          <arg>--hvm-cdrom-image-path
699 ca9c49d5 Iustin Pop
            <replaceable>cdrom-image-path</replaceable></arg>
700 02d2adf4 Alexander Schreiber
          <arg>--hvm-nic-type <replaceable>NICTYPE</replaceable></arg>
701 02d2adf4 Alexander Schreiber
          <arg>--hvm-disk-type <replaceable>DISKTYPE</replaceable></arg>
702 ca9c49d5 Iustin Pop
          <arg>--vnc-bind-address
703 ca9c49d5 Iustin Pop
            <replaceable>vnc-bind-address</replaceable></arg>
704 ca9c49d5 Iustin Pop
705 00f98619 Iustin Pop
          <sbr>
706 00f98619 Iustin Pop
          <arg>--kernel <group choice="req">
707 00f98619 Iustin Pop
              <arg>default</arg>
708 00f98619 Iustin Pop
              <arg><replaceable>kernel_path</replaceable></arg>
709 00f98619 Iustin Pop
            </group></arg>
710 00f98619 Iustin Pop
          <sbr>
711 00f98619 Iustin Pop
          <arg>--initrd <group choice="req">
712 00f98619 Iustin Pop
              <arg>default</arg>
713 00f98619 Iustin Pop
              <arg>none</arg>
714 00f98619 Iustin Pop
              <arg><replaceable>initrd_path</replaceable></arg>
715 00f98619 Iustin Pop
            </group> </arg>
716 00f98619 Iustin Pop
          <sbr>
717 a8083063 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
718 a8083063 Iustin Pop
        </cmdsynopsis>
719 a8083063 Iustin Pop
720 a8083063 Iustin Pop
        <para>
721 f3a55c90 Alexander Schreiber
          Modify the memory size, number of vcpus, ip address, MAC
722 f3a55c90 Alexander Schreiber
          address and/or bridge for an instance.
723 a8083063 Iustin Pop
        </para>
724 a8083063 Iustin Pop
725 a8083063 Iustin Pop
        <para>
726 a8083063 Iustin Pop
          The memory size is given in MiB. Note that you need to give
727 a8083063 Iustin Pop
          at least one of the arguments, otherwise the command
728 a8083063 Iustin Pop
          complains.
729 a8083063 Iustin Pop
        </para>
730 a8083063 Iustin Pop
731 a8083063 Iustin Pop
        <para>
732 25c5878d Alexander Schreiber
          The <option>--kernel</option>, <option>--initrd</option>
733 25c5878d Alexander Schreiber
          and <option>--hvm-boot-order</option>
734 00f98619 Iustin Pop
          options are described in the <command>add</command> command.
735 00f98619 Iustin Pop
        </para>
736 00f98619 Iustin Pop
737 00f98619 Iustin Pop
        <para>
738 25c5878d Alexander Schreiber
          Additionally, the HVM boot order can be reset to the default
739 25c5878d Alexander Schreiber
          values by using <option>--hvm-boot-order=default</option>.
740 25c5878d Alexander Schreiber
        </para>
741 25c5878d Alexander Schreiber
742 25c5878d Alexander Schreiber
        <para>
743 ca9c49d5 Iustin Pop
          The <option>--hvm-acpi</option> option specifies if Xen
744 ca9c49d5 Iustin Pop
          should enable ACPI support for this HVM instance. Valid
745 ca9c49d5 Iustin Pop
          values are true or false.
746 ca9c49d5 Iustin Pop
        </para>
747 ca9c49d5 Iustin Pop
748 ca9c49d5 Iustin Pop
        <para>
749 ca9c49d5 Iustin Pop
          The <option>--hvm-pae</option> option specifies if Xen
750 ca9c49d5 Iustin Pop
          should enabled PAE support for this HVM instance. Valid
751 ca9c49d5 Iustin Pop
          values are true or false.
752 ca9c49d5 Iustin Pop
        </para>
753 ca9c49d5 Iustin Pop
754 ca9c49d5 Iustin Pop
        <para>
755 ca9c49d5 Iustin Pop
          The <option>--hvm-cdrom-image-path</option> specifies the
756 ca9c49d5 Iustin Pop
          path to the file xen uses to emulate a virtual CDROM drive
757 ca9c49d5 Iustin Pop
          for this HVM instance. Valid values are either an
758 ca9c49d5 Iustin Pop
          absolute path to an existing file or None, which disables
759 ca9c49d5 Iustin Pop
          virtual CDROM support for this instance.
760 ca9c49d5 Iustin Pop
        </para>
761 ca9c49d5 Iustin Pop
762 ca9c49d5 Iustin Pop
        <para>
763 02d2adf4 Alexander Schreiber
          The <option>--hvm-nic-type</option> specifies the NIC type
764 02d2adf4 Alexander Schreiber
          Xen should use for this HVM instance. Valid choices are
765 02d2adf4 Alexander Schreiber
          rtl8139, ne2k_pci, ne2k_isa and paravirtual with rtl8139
766 02d2adf4 Alexander Schreiber
          as the default. The paravirtual setting is intended for use
767 02d2adf4 Alexander Schreiber
          with the GPL PV drivers inside HVM Windows instances.
768 02d2adf4 Alexander Schreiber
        </para>
769 02d2adf4 Alexander Schreiber
770 02d2adf4 Alexander Schreiber
        <para>
771 02d2adf4 Alexander Schreiber
          The <option>--hvm-disk-type</option> specifies the disk type
772 02d2adf4 Alexander Schreiber
          Xen should use for the HVM instance. Valid choices are ioemu
773 02d2adf4 Alexander Schreiber
          and paravirtual with ioemu as the default. The paravirtual
774 02d2adf4 Alexander Schreiber
          setting is intended for use with the GPL PV drivers inside
775 02d2adf4 Alexander Schreiber
          HVM Windows instances.
776 02d2adf4 Alexander Schreiber
        </para>
777 02d2adf4 Alexander Schreiber
778 02d2adf4 Alexander Schreiber
        <para>
779 ca9c49d5 Iustin Pop
          The <option>--vnc-bind-address</option> specifies the
780 ca9c49d5 Iustin Pop
          address that the VNC listener for this instance should bind
781 ca9c49d5 Iustin Pop
          to. Valid values are IPv4 addresses. Use the address 0.0.0.0
782 ca9c49d5 Iustin Pop
          to bind to all available interfaces.
783 ca9c49d5 Iustin Pop
        </para>
784 ca9c49d5 Iustin Pop
785 ca9c49d5 Iustin Pop
        <para>
786 a8083063 Iustin Pop
          All the changes take effect at the next restart. If the
787 a8083063 Iustin Pop
          instance is running, there is no effect on the instance.
788 a8083063 Iustin Pop
        </para>
789 a8083063 Iustin Pop
      </refsect3>
790 a8083063 Iustin Pop
791 d0834de3 Michael Hanselmann
      <refsect3>
792 d0834de3 Michael Hanselmann
        <title>REINSTALL</title>
793 d0834de3 Michael Hanselmann
794 d0834de3 Michael Hanselmann
        <cmdsynopsis>
795 d0834de3 Michael Hanselmann
          <command>reinstall</command>
796 d0834de3 Michael Hanselmann
          <arg choice="opt">-o <replaceable>os-type</replaceable></arg>
797 d0834de3 Michael Hanselmann
          <arg choice="opt">-f <replaceable>force</replaceable></arg>
798 20e23543 Alexander Schreiber
          <arg>--select-os</arg>
799 d0834de3 Michael Hanselmann
          <arg choice="req"><replaceable>instance</replaceable></arg>
800 d0834de3 Michael Hanselmann
        </cmdsynopsis>
801 d0834de3 Michael Hanselmann
802 d0834de3 Michael Hanselmann
        <para>
803 d0834de3 Michael Hanselmann
          Reinstalls the operating system on the given instance. The instance
804 d0834de3 Michael Hanselmann
          must be stopped when running this command. If the
805 d0834de3 Michael Hanselmann
          <option>--os-type</option> is specified, the operating system is
806 d0834de3 Michael Hanselmann
          changed.
807 d0834de3 Michael Hanselmann
        </para>
808 20e23543 Alexander Schreiber
809 20e23543 Alexander Schreiber
        <para>
810 20e23543 Alexander Schreiber
          The <option>--select-os</option> option switches to an
811 20e23543 Alexander Schreiber
          interactive OS reinstall. The user is prompted to select the OS
812 20e23543 Alexander Schreiber
          template from the list of available OS templates.
813 20e23543 Alexander Schreiber
        </para>
814 d0834de3 Michael Hanselmann
      </refsect3>
815 d0834de3 Michael Hanselmann
816 decd5f45 Iustin Pop
      <refsect3>
817 decd5f45 Iustin Pop
        <title>RENAME</title>
818 decd5f45 Iustin Pop
819 decd5f45 Iustin Pop
        <cmdsynopsis>
820 decd5f45 Iustin Pop
          <command>rename</command>
821 decd5f45 Iustin Pop
          <arg>--no-ip-check</arg>
822 decd5f45 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
823 decd5f45 Iustin Pop
          <arg choice="req"><replaceable>new_name</replaceable></arg>
824 decd5f45 Iustin Pop
        </cmdsynopsis>
825 decd5f45 Iustin Pop
826 decd5f45 Iustin Pop
        <para>
827 decd5f45 Iustin Pop
          Renames the given instance. The instance must be stopped
828 decd5f45 Iustin Pop
          when running this command. The requirements for the new name
829 decd5f45 Iustin Pop
          are the same as for adding an instance: the new name must be
830 decd5f45 Iustin Pop
          resolvable and the IP it resolves to must not be reachable
831 decd5f45 Iustin Pop
          (in order to prevent duplicate IPs the next time the
832 decd5f45 Iustin Pop
          instance is started). The IP test can be skipped if the
833 decd5f45 Iustin Pop
          <option>--no-ip-check</option> option is passed.
834 decd5f45 Iustin Pop
        </para>
835 decd5f45 Iustin Pop
      </refsect3>
836 decd5f45 Iustin Pop
837 a8083063 Iustin Pop
    </refsect2>
838 a8083063 Iustin Pop
839 a8083063 Iustin Pop
    <refsect2>
840 a8083063 Iustin Pop
      <title>Starting/stopping/connecting to console</title>
841 a8083063 Iustin Pop
842 a8083063 Iustin Pop
      <refsect3>
843 a8083063 Iustin Pop
        <title>STARTUP</title>
844 a8083063 Iustin Pop
845 a8083063 Iustin Pop
        <cmdsynopsis>
846 a8083063 Iustin Pop
          <command>startup</command>
847 a8083063 Iustin Pop
          <arg>--extra=<replaceable>PARAMS</replaceable></arg>
848 3bd5f059 Michael Hanselmann
          <arg>--force</arg>
849 312ac745 Iustin Pop
          <sbr>
850 312ac745 Iustin Pop
          <group choice="opt">
851 312ac745 Iustin Pop
            <arg>--instance</arg>
852 312ac745 Iustin Pop
            <arg>--node</arg>
853 312ac745 Iustin Pop
            <arg>--primary</arg>
854 312ac745 Iustin Pop
            <arg>--secondary</arg>
855 312ac745 Iustin Pop
            <arg>--all</arg>
856 312ac745 Iustin Pop
          </group>
857 312ac745 Iustin Pop
          <sbr>
858 312ac745 Iustin Pop
          <arg choice="opt"
859 312ac745 Iustin Pop
          rep="repeat"><replaceable>name</replaceable></arg>
860 a8083063 Iustin Pop
        </cmdsynopsis>
861 a8083063 Iustin Pop
862 a8083063 Iustin Pop
        <para>
863 bcee9cb4 Iustin Pop
          Starts one or more instances, depending on the following
864 bcee9cb4 Iustin Pop
          options. The four available modes are:
865 312ac745 Iustin Pop
          <variablelist>
866 312ac745 Iustin Pop
            <varlistentry>
867 312ac745 Iustin Pop
              <term><option>--instance</option></term>
868 312ac745 Iustin Pop
              <listitem>
869 312ac745 Iustin Pop
                <simpara>will start the instances given as arguments
870 312ac745 Iustin Pop
                (at least one argument required); this is the default
871 312ac745 Iustin Pop
                selection</simpara>
872 312ac745 Iustin Pop
              </listitem>
873 312ac745 Iustin Pop
            </varlistentry>
874 312ac745 Iustin Pop
            <varlistentry>
875 312ac745 Iustin Pop
              <term>--node</term>
876 312ac745 Iustin Pop
              <listitem>
877 312ac745 Iustin Pop
                <simpara>will start the instances who have the given
878 312ac745 Iustin Pop
                node as either primary or secondary</simpara>
879 312ac745 Iustin Pop
              </listitem>
880 312ac745 Iustin Pop
            </varlistentry>
881 312ac745 Iustin Pop
            <varlistentry>
882 312ac745 Iustin Pop
              <term><option>--primary</option></term>
883 312ac745 Iustin Pop
              <listitem>
884 312ac745 Iustin Pop
                <simpara>will start all instances whose primary node
885 312ac745 Iustin Pop
                is in the list of nodes passed as arguments (at least
886 312ac745 Iustin Pop
                one node required)</simpara>
887 312ac745 Iustin Pop
              </listitem>
888 312ac745 Iustin Pop
            </varlistentry>
889 312ac745 Iustin Pop
            <varlistentry>
890 312ac745 Iustin Pop
              <term><option>--secondary</option></term>
891 312ac745 Iustin Pop
              <listitem>
892 312ac745 Iustin Pop
                <simpara>will start all instances whose secondary node
893 312ac745 Iustin Pop
                is in the list of nodes passed as arguments (at least
894 312ac745 Iustin Pop
                one node required)</simpara>
895 312ac745 Iustin Pop
              </listitem>
896 312ac745 Iustin Pop
            </varlistentry>
897 312ac745 Iustin Pop
            <varlistentry>
898 312ac745 Iustin Pop
              <term>--all</term>
899 312ac745 Iustin Pop
              <listitem>
900 312ac745 Iustin Pop
                <simpara>will start all instances in the cluster (no
901 312ac745 Iustin Pop
                arguments accepted)</simpara>
902 312ac745 Iustin Pop
              </listitem>
903 312ac745 Iustin Pop
            </varlistentry>
904 312ac745 Iustin Pop
          </variablelist>
905 312ac745 Iustin Pop
        </para>
906 312ac745 Iustin Pop
907 312ac745 Iustin Pop
        <para>
908 bcee9cb4 Iustin Pop
          Note that although you can pass more than one selection
909 bcee9cb4 Iustin Pop
          option, the last one wins, so in order to guarantee the
910 bcee9cb4 Iustin Pop
          desired result, don't pass more than one such option.
911 a8083063 Iustin Pop
        </para>
912 a8083063 Iustin Pop
913 a8083063 Iustin Pop
        <para>
914 a8083063 Iustin Pop
          The <option>--extra</option> option is used to pass
915 a8083063 Iustin Pop
          additional argument to the instance's kernel for this start
916 a8083063 Iustin Pop
          only. Currently there is no way to specify a persistent set
917 a8083063 Iustin Pop
          of arguments (beside the one hardcoded). Note that this may
918 a8083063 Iustin Pop
          not apply to all virtualization types.
919 a8083063 Iustin Pop
        </para>
920 a8083063 Iustin Pop
921 3bd5f059 Michael Hanselmann
        <para>
922 3bd5f059 Michael Hanselmann
          Use <option>--force</option> to start even if secondary disks are
923 3bd5f059 Michael Hanselmann
          failing.
924 3bd5f059 Michael Hanselmann
        </para>
925 a8083063 Iustin Pop
926 a8083063 Iustin Pop
        <para>
927 a8083063 Iustin Pop
          Example:
928 a8083063 Iustin Pop
          <screen>
929 a8083063 Iustin Pop
# gnt-instance start instance1.example.com
930 a8083063 Iustin Pop
# gnt-instance start --extra single test1.example.com
931 bcee9cb4 Iustin Pop
# gnt-instance start --node node1.example.com node2.example.com
932 bcee9cb4 Iustin Pop
# gnt-instance start --all
933 a8083063 Iustin Pop
          </screen>
934 a8083063 Iustin Pop
        </para>
935 a8083063 Iustin Pop
      </refsect3>
936 a8083063 Iustin Pop
937 a8083063 Iustin Pop
      <refsect3>
938 a8083063 Iustin Pop
        <title>SHUTDOWN</title>
939 a8083063 Iustin Pop
940 a8083063 Iustin Pop
        <cmdsynopsis>
941 a8083063 Iustin Pop
          <command>shutdown</command>
942 312ac745 Iustin Pop
          <sbr>
943 312ac745 Iustin Pop
          <group choice="opt">
944 312ac745 Iustin Pop
            <arg>--instance</arg>
945 312ac745 Iustin Pop
            <arg>--node</arg>
946 312ac745 Iustin Pop
            <arg>--primary</arg>
947 312ac745 Iustin Pop
            <arg>--secondary</arg>
948 312ac745 Iustin Pop
            <arg>--all</arg>
949 312ac745 Iustin Pop
          </group>
950 312ac745 Iustin Pop
          <sbr>
951 312ac745 Iustin Pop
952 312ac745 Iustin Pop
          <arg choice="opt"
953 312ac745 Iustin Pop
          rep="repeat"><replaceable>name</replaceable></arg>
954 a8083063 Iustin Pop
        </cmdsynopsis>
955 a8083063 Iustin Pop
956 a8083063 Iustin Pop
        <para>
957 312ac745 Iustin Pop
          Stops one or more instances. If the instance cannot be
958 312ac745 Iustin Pop
          cleanly stopped during a hardcoded interval (currently 2
959 312ac745 Iustin Pop
          minutes), it will forcibly stop the instance (equivalent to
960 312ac745 Iustin Pop
          switching off the power on a physical machine).
961 312ac745 Iustin Pop
        </para>
962 312ac745 Iustin Pop
963 312ac745 Iustin Pop
        <para>
964 312ac745 Iustin Pop
          The <option>--instance</option>, <option>--node</option>,
965 312ac745 Iustin Pop
          <option>--primary</option>, <option>--secondary</option> and
966 312ac745 Iustin Pop
          <option>--all</option> options are similar as for the
967 312ac745 Iustin Pop
          <command>startup</command> command and they influence the
968 86b8c6ae Alexander Schreiber
          actual instances being shutdown.
969 a8083063 Iustin Pop
        </para>
970 a8083063 Iustin Pop
971 a8083063 Iustin Pop
        <para>
972 a8083063 Iustin Pop
          Example:
973 a8083063 Iustin Pop
          <screen>
974 a8083063 Iustin Pop
# gnt-instance shutdown instance1.example.com
975 bcee9cb4 Iustin Pop
# gnt-instance shutdown --all
976 a8083063 Iustin Pop
          </screen>
977 a8083063 Iustin Pop
        </para>
978 a8083063 Iustin Pop
      </refsect3>
979 a8083063 Iustin Pop
980 a8083063 Iustin Pop
      <refsect3>
981 579d4337 Alexander Schreiber
        <title>REBOOT</title>
982 579d4337 Alexander Schreiber
983 579d4337 Alexander Schreiber
        <cmdsynopsis>
984 579d4337 Alexander Schreiber
          <command>reboot</command>
985 579d4337 Alexander Schreiber
          <sbr>
986 579d4337 Alexander Schreiber
          <arg>--extra=<replaceable>PARAMS</replaceable></arg>
987 579d4337 Alexander Schreiber
          <sbr>
988 579d4337 Alexander Schreiber
          <arg>--type=<replaceable>REBOOT-TYPE</replaceable></arg>
989 579d4337 Alexander Schreiber
          <sbr>
990 579d4337 Alexander Schreiber
          <arg>--ignore-secondaries</arg>
991 579d4337 Alexander Schreiber
          <sbr>
992 579d4337 Alexander Schreiber
          <arg>--force-multiple</arg>
993 579d4337 Alexander Schreiber
          <sbr>
994 579d4337 Alexander Schreiber
          <group choice="opt">
995 579d4337 Alexander Schreiber
            <arg>--instance</arg>
996 579d4337 Alexander Schreiber
            <arg>--node</arg>
997 579d4337 Alexander Schreiber
            <arg>--primary</arg>
998 579d4337 Alexander Schreiber
            <arg>--secondary</arg>
999 579d4337 Alexander Schreiber
            <arg>--all</arg>
1000 579d4337 Alexander Schreiber
          </group>
1001 579d4337 Alexander Schreiber
          <sbr>
1002 579d4337 Alexander Schreiber
1003 579d4337 Alexander Schreiber
          <arg choice="opt"
1004 579d4337 Alexander Schreiber
          rep="repeat"><replaceable>name</replaceable></arg>
1005 579d4337 Alexander Schreiber
        </cmdsynopsis>
1006 579d4337 Alexander Schreiber
1007 579d4337 Alexander Schreiber
        <para>
1008 579d4337 Alexander Schreiber
          Reboots one or more instances. The type of reboot depends on
1009 579d4337 Alexander Schreiber
          the value of <option>--type</option>. A soft reboot does a
1010 579d4337 Alexander Schreiber
          hypervisor reboot, a hard reboot does a instance stop,
1011 579d4337 Alexander Schreiber
          recreates the hypervisor config for the instance and
1012 579d4337 Alexander Schreiber
          starts the instance. A full reboot does the equivalent
1013 579d4337 Alexander Schreiber
          of <command>gnt-instance shutdown &amp;&amp; gnt-instance
1014 bf2fd71e Alexander Schreiber
          startup</command>. The default is hard reboot.
1015 579d4337 Alexander Schreiber
        </para>
1016 579d4337 Alexander Schreiber
1017 579d4337 Alexander Schreiber
        <para>
1018 579d4337 Alexander Schreiber
          For the hard reboot the option
1019 579d4337 Alexander Schreiber
          <option>--ignore-secondaries</option> ignores errors for the
1020 579d4337 Alexander Schreiber
          secondary node while re-assembling the instance disks.
1021 579d4337 Alexander Schreiber
        </para>
1022 579d4337 Alexander Schreiber
1023 579d4337 Alexander Schreiber
        <para>
1024 579d4337 Alexander Schreiber
          The <option>--instance</option>, <option>--node</option>,
1025 579d4337 Alexander Schreiber
          <option>--primary</option>, <option>--secondary</option> and
1026 579d4337 Alexander Schreiber
          <option>--all</option> options are similar as for the
1027 579d4337 Alexander Schreiber
          <command>startup</command> command and they influence the
1028 579d4337 Alexander Schreiber
          actual instances being rebooted.
1029 579d4337 Alexander Schreiber
        </para>
1030 36c87212 Iustin Pop
1031 579d4337 Alexander Schreiber
        <para>
1032 3bd5f059 Michael Hanselmann
          Use the <option>--force-multiple</option> option to keep
1033 579d4337 Alexander Schreiber
          gnt-instance from asking for confirmation when more than one
1034 579d4337 Alexander Schreiber
          instance is affected.
1035 579d4337 Alexander Schreiber
        </para>
1036 579d4337 Alexander Schreiber
1037 579d4337 Alexander Schreiber
        <para>
1038 579d4337 Alexander Schreiber
          Example:
1039 579d4337 Alexander Schreiber
          <screen>
1040 579d4337 Alexander Schreiber
# gnt-instance reboot instance1.example.com
1041 579d4337 Alexander Schreiber
# gnt-instance reboot --type=full instance1.example.com
1042 579d4337 Alexander Schreiber
          </screen>
1043 579d4337 Alexander Schreiber
        </para>
1044 579d4337 Alexander Schreiber
      </refsect3>
1045 579d4337 Alexander Schreiber
1046 579d4337 Alexander Schreiber
      <refsect3>
1047 a8083063 Iustin Pop
        <title>CONSOLE</title>
1048 a8083063 Iustin Pop
        <cmdsynopsis>
1049 a8083063 Iustin Pop
          <command>console</command>
1050 51c6e7b5 Michael Hanselmann
          <arg choice="opt">--show-cmd</arg>
1051 a8083063 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
1052 a8083063 Iustin Pop
        </cmdsynopsis>
1053 a8083063 Iustin Pop
1054 a8083063 Iustin Pop
        <para>
1055 a8083063 Iustin Pop
          Connects to the console of the given instance. If the instance
1056 51c6e7b5 Michael Hanselmann
          is not up, an error is returned. Use the <option>--show-cmd</option>
1057 51c6e7b5 Michael Hanselmann
          option to display the command instead of executing it.
1058 a8083063 Iustin Pop
        </para>
1059 a8083063 Iustin Pop
1060 a8083063 Iustin Pop
        <para>
1061 16034f1f Alexander Schreiber
          For HVM instances, this will attempt to connect to the serial
1062 16034f1f Alexander Schreiber
          console of the instance. To connect to the virtualized
1063 16034f1f Alexander Schreiber
          "physical" console of a HVM instance, use a VNC client with
1064 16034f1f Alexander Schreiber
          the connection info from gnt-instance info.
1065 16034f1f Alexander Schreiber
        </para>
1066 16034f1f Alexander Schreiber
1067 16034f1f Alexander Schreiber
        <para>
1068 a8083063 Iustin Pop
          Example:
1069 a8083063 Iustin Pop
          <screen>
1070 a8083063 Iustin Pop
# gnt-instance console instance1.example.com
1071 a8083063 Iustin Pop
          </screen>
1072 a8083063 Iustin Pop
        </para>
1073 a8083063 Iustin Pop
      </refsect3>
1074 a8083063 Iustin Pop
1075 a8083063 Iustin Pop
    </refsect2>
1076 a8083063 Iustin Pop
1077 a8083063 Iustin Pop
    <refsect2>
1078 a8083063 Iustin Pop
      <title>Disk management</title>
1079 a8083063 Iustin Pop
1080 a8083063 Iustin Pop
      <refsect3>
1081 a8083063 Iustin Pop
        <title>REPLACE-DISKS</title>
1082 a8083063 Iustin Pop
1083 a8083063 Iustin Pop
        <cmdsynopsis>
1084 a8083063 Iustin Pop
          <command>replace-disks</command>
1085 7e9366f7 Iustin Pop
          <arg choice="req">-p</arg>
1086 7e9366f7 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
1087 7e9366f7 Iustin Pop
        </cmdsynopsis>
1088 a53a1b18 Michael Hanselmann
1089 7e9366f7 Iustin Pop
        <cmdsynopsis>
1090 7e9366f7 Iustin Pop
          <command>replace-disks</command>
1091 a53a1b18 Michael Hanselmann
1092 7e9366f7 Iustin Pop
          <arg choice="req">-s</arg>
1093 a8083063 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
1094 a8083063 Iustin Pop
        </cmdsynopsis>
1095 a8083063 Iustin Pop
1096 0b0dea6a Iustin Pop
        <cmdsynopsis>
1097 0b0dea6a Iustin Pop
          <command>replace-disks</command>
1098 a53a1b18 Michael Hanselmann
1099 7e9366f7 Iustin Pop
          <group choice="req">
1100 7e9366f7 Iustin Pop
            <arg>--iallocator <replaceable>name</replaceable></arg>
1101 7e9366f7 Iustin Pop
            <arg>--new-secondary <replaceable>NODE</replaceable></arg>
1102 0b0dea6a Iustin Pop
          </group>
1103 7e9366f7 Iustin Pop
1104 0b0dea6a Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
1105 0b0dea6a Iustin Pop
        </cmdsynopsis>
1106 0b0dea6a Iustin Pop
1107 a8083063 Iustin Pop
        <para>
1108 0b0dea6a Iustin Pop
          This command is a generalized form for adding and replacing
1109 bd028152 Iustin Pop
          disks. It is currently only valid for the mirrored (DRBD)
1110 bd028152 Iustin Pop
          disk template.
1111 a8083063 Iustin Pop
        </para>
1112 0b0dea6a Iustin Pop
1113 0b0dea6a Iustin Pop
        <para>
1114 7e9366f7 Iustin Pop
          The first form (when passing the <option>-p</option> option)
1115 7e9366f7 Iustin Pop
          will replace the disks on the primary, while the second form
1116 7e9366f7 Iustin Pop
          (when passing the <option>-s</option> option will replace
1117 7e9366f7 Iustin Pop
          the disks on the secondary node.
1118 0b0dea6a Iustin Pop
        </para>
1119 0b0dea6a Iustin Pop
1120 a53a1b18 Michael Hanselmann
        <para>
1121 7e9366f7 Iustin Pop
          The third form (when passing either the
1122 7e9366f7 Iustin Pop
          <option>--iallocator</option> or the
1123 7e9366f7 Iustin Pop
          <option>--new-secondary</option> option) is designed to
1124 7e9366f7 Iustin Pop
          change secondary node of the instance.  Specifying
1125 7e9366f7 Iustin Pop
          <option>--iallocator</option> makes the new secondary be
1126 7e9366f7 Iustin Pop
          selected automatically by the specified allocator plugin,
1127 7e9366f7 Iustin Pop
          otherwise the new secondary node will be the one chosen
1128 7e9366f7 Iustin Pop
          manually via the <option>--new-secondary</option> option.
1129 a53a1b18 Michael Hanselmann
        </para>
1130 a8083063 Iustin Pop
      </refsect3>
1131 a8083063 Iustin Pop
1132 a8083063 Iustin Pop
      <refsect3>
1133 a8083063 Iustin Pop
        <title>ACTIVATE-DISKS</title>
1134 a8083063 Iustin Pop
1135 a8083063 Iustin Pop
        <cmdsynopsis>
1136 a8083063 Iustin Pop
          <command>activate-disks</command>
1137 a8083063 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
1138 a8083063 Iustin Pop
        </cmdsynopsis>
1139 a8083063 Iustin Pop
        <para>
1140 a8083063 Iustin Pop
          Activates the block devices of the given instance. If
1141 a8083063 Iustin Pop
          successful, the command will show the location and name of
1142 a8083063 Iustin Pop
          the block devices:
1143 a8083063 Iustin Pop
          <screen>
1144 bd028152 Iustin Pop
node1.example.com:sda:/dev/drbd0
1145 bd028152 Iustin Pop
node1.example.com:sdb:/dev/drbd1
1146 a8083063 Iustin Pop
          </screen>
1147 a8083063 Iustin Pop
1148 a8083063 Iustin Pop
          In this example, <emphasis>node1.example.com</emphasis> is
1149 a8083063 Iustin Pop
          the name of the node on which the devices have been
1150 a8083063 Iustin Pop
          activated. The <emphasis>sda</emphasis> and
1151 a8083063 Iustin Pop
          <emphasis>sdb</emphasis> are the names of the block devices
1152 bd028152 Iustin Pop
          inside the instance. <emphasis>/dev/drbd0</emphasis> and
1153 bd028152 Iustin Pop
          <emphasis>/dev/drbd1</emphasis> are the names of the block
1154 a8083063 Iustin Pop
          devices as visible on the node.
1155 a8083063 Iustin Pop
        </para>
1156 a8083063 Iustin Pop
1157 a8083063 Iustin Pop
        <para>
1158 a8083063 Iustin Pop
          Note that it is safe to run this command while the instance
1159 a8083063 Iustin Pop
          is already running.
1160 a8083063 Iustin Pop
        </para>
1161 a8083063 Iustin Pop
      </refsect3>
1162 a8083063 Iustin Pop
1163 a8083063 Iustin Pop
      <refsect3>
1164 a8083063 Iustin Pop
        <title>DEACTIVATE-DISKS</title>
1165 a8083063 Iustin Pop
1166 a8083063 Iustin Pop
        <cmdsynopsis>
1167 a8083063 Iustin Pop
          <command>deactivate-disks</command>
1168 a8083063 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
1169 a8083063 Iustin Pop
        </cmdsynopsis>
1170 a8083063 Iustin Pop
        <para>
1171 a8083063 Iustin Pop
          De-activates the block devices of the given instance. Note
1172 bd028152 Iustin Pop
          that if you run this command for an instance with a drbd
1173 bd028152 Iustin Pop
          disk template, while it is running, it will not be able to
1174 bd028152 Iustin Pop
          shutdown the block devices on the primary node, but it will
1175 bd028152 Iustin Pop
          shutdown the block devices on the secondary nodes, thus
1176 bd028152 Iustin Pop
          breaking the replication.
1177 a8083063 Iustin Pop
        </para>
1178 a8083063 Iustin Pop
1179 a8083063 Iustin Pop
      </refsect3>
1180 a8083063 Iustin Pop
1181 eb65d354 Iustin Pop
      <refsect3>
1182 eb65d354 Iustin Pop
        <title>GROW-DISK</title>
1183 eb65d354 Iustin Pop
        <cmdsynopsis>
1184 eb65d354 Iustin Pop
          <command>grow-disk</command>
1185 6605411d Iustin Pop
          <arg>--no-wait-for-sync</arg>
1186 eb65d354 Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
1187 eb65d354 Iustin Pop
          <arg choice="req"><replaceable>disk</replaceable></arg>
1188 eb65d354 Iustin Pop
          <arg choice="req"><replaceable>amount</replaceable></arg>
1189 eb65d354 Iustin Pop
        </cmdsynopsis>
1190 eb65d354 Iustin Pop
1191 eb65d354 Iustin Pop
        <para>
1192 eb65d354 Iustin Pop
          Grows an instance's disk. This is only possible for
1193 eb65d354 Iustin Pop
          instances having a <literal>plain</literal> or
1194 eb65d354 Iustin Pop
          <literal>drbd</literal> disk template.
1195 eb65d354 Iustin Pop
        </para>
1196 eb65d354 Iustin Pop
1197 eb65d354 Iustin Pop
        <para>
1198 eb65d354 Iustin Pop
          Note that this command only change the block device size; it
1199 eb65d354 Iustin Pop
          will not grow the actual filesystems, partitions, etc. that
1200 eb65d354 Iustin Pop
          live on that disk. Usually, you will need to:
1201 eb65d354 Iustin Pop
          <orderedlist>
1202 eb65d354 Iustin Pop
            <listitem>
1203 eb65d354 Iustin Pop
              <simpara>use <command>gnt-instance grow-disk</command></simpara>
1204 eb65d354 Iustin Pop
            </listitem>
1205 eb65d354 Iustin Pop
            <listitem>
1206 eb65d354 Iustin Pop
              <simpara>reboot the instance (later, at a convenient
1207 eb65d354 Iustin Pop
              time)</simpara>
1208 eb65d354 Iustin Pop
            </listitem>
1209 eb65d354 Iustin Pop
            <listitem>
1210 eb65d354 Iustin Pop
              <simpara>use a filesystem resizer, such as
1211 eb65d354 Iustin Pop
              <citerefentry> <refentrytitle>ext2online</refentrytitle>
1212 eb65d354 Iustin Pop
              <manvolnum>8</manvolnum> </citerefentry> or
1213 eb65d354 Iustin Pop
              <citerefentry> <refentrytitle>xfs_growfs</refentrytitle>
1214 eb65d354 Iustin Pop
              <manvolnum>8</manvolnum> </citerefentry> to resize the
1215 eb65d354 Iustin Pop
              filesystem, or use <citerefentry>
1216 eb65d354 Iustin Pop
              <refentrytitle>fdisk</refentrytitle>
1217 eb65d354 Iustin Pop
              <manvolnum>8</manvolnum> </citerefentry> to change the
1218 eb65d354 Iustin Pop
              partition table on the disk
1219 eb65d354 Iustin Pop
              </simpara>
1220 eb65d354 Iustin Pop
            </listitem>
1221 eb65d354 Iustin Pop
          </orderedlist>
1222 eb65d354 Iustin Pop
        </para>
1223 eb65d354 Iustin Pop
1224 eb65d354 Iustin Pop
1225 eb65d354 Iustin Pop
        <para>
1226 eb65d354 Iustin Pop
          The <replaceable>disk</replaceable> argument is either
1227 eb65d354 Iustin Pop
          <literal>sda</literal> or <literal>sdb</literal>. The
1228 eb65d354 Iustin Pop
          <replaceable>amount</replaceable> argument is given either
1229 eb65d354 Iustin Pop
          as a number (and it represents the amount to increase the
1230 eb65d354 Iustin Pop
          disk with in mebibytes) or can be given similar to the
1231 eb65d354 Iustin Pop
          arguments in the create instance operation, with a suffix
1232 eb65d354 Iustin Pop
          denoting the unit.
1233 eb65d354 Iustin Pop
        </para>
1234 eb65d354 Iustin Pop
1235 eb65d354 Iustin Pop
        <para>
1236 eb65d354 Iustin Pop
          Note that the disk grow operation might complete on one node
1237 eb65d354 Iustin Pop
          but fail on the other; this will leave the instance with
1238 eb65d354 Iustin Pop
          different-sized LVs on the two nodes, but this will not
1239 eb65d354 Iustin Pop
          create problems (except for unused space).
1240 eb65d354 Iustin Pop
        </para>
1241 eb65d354 Iustin Pop
1242 6605411d Iustin Pop
        <para>
1243 6605411d Iustin Pop
          If you do not want gnt-instance to wait for the new disk
1244 6605411d Iustin Pop
          region to be synced, use the
1245 6605411d Iustin Pop
          <option>--no-wait-for-sync</option> option.
1246 6605411d Iustin Pop
        </para>
1247 6605411d Iustin Pop
1248 6605411d Iustin Pop
1249 6605411d Iustin Pop
        <para>Example (increase sda for instance1 by 16GiB):
1250 eb65d354 Iustin Pop
          <screen>
1251 eb65d354 Iustin Pop
# gnt-instance grow-disk instance1.example.com sda 16g
1252 eb65d354 Iustin Pop
          </screen>
1253 eb65d354 Iustin Pop
        </para>
1254 eb65d354 Iustin Pop
1255 eb65d354 Iustin Pop
        <para>
1256 eb65d354 Iustin Pop
          Also note that disk shrinking will not be supported; use
1257 eb65d354 Iustin Pop
          <command>gnt-backup export</command> and then
1258 eb65d354 Iustin Pop
          <command>gnt-backup import</command> to reduce the disk size
1259 eb65d354 Iustin Pop
          of an instance.
1260 eb65d354 Iustin Pop
        </para>
1261 eb65d354 Iustin Pop
      </refsect3>
1262 eb65d354 Iustin Pop
1263 a8083063 Iustin Pop
    </refsect2>
1264 a8083063 Iustin Pop
1265 a8083063 Iustin Pop
    <refsect2>
1266 a8083063 Iustin Pop
      <title>Recovery</title>
1267 a8083063 Iustin Pop
1268 a8083063 Iustin Pop
      <refsect3>
1269 a8083063 Iustin Pop
        <title>FAILOVER</title>
1270 a8083063 Iustin Pop
1271 a8083063 Iustin Pop
        <cmdsynopsis>
1272 a8083063 Iustin Pop
          <command>failover</command>
1273 a8083063 Iustin Pop
          <arg>-f</arg>
1274 a8083063 Iustin Pop
          <arg>--ignore-consistency</arg>
1275 80de0e3f Iustin Pop
          <arg choice="req"><replaceable>instance</replaceable></arg>
1276 a8083063 Iustin Pop
        </cmdsynopsis>
1277 a8083063 Iustin Pop
1278 a8083063 Iustin Pop
        <para>
1279 80de0e3f Iustin Pop
          Failover will fail the instance over its secondary
1280 bd028152 Iustin Pop
          node. This works only for instances having a drbd disk
1281 bd028152 Iustin Pop
          template.
1282 a8083063 Iustin Pop
        </para>
1283 a8083063 Iustin Pop
1284 a8083063 Iustin Pop
        <para>
1285 a8083063 Iustin Pop
          Normally the failover will check the consistency of the
1286 80de0e3f Iustin Pop
          disks before failing over the instance. If you are trying to
1287 a8083063 Iustin Pop
          migrate instances off a dead node, this will fail. Use the
1288 a8083063 Iustin Pop
          <option>--ignore-consistency</option> option for this
1289 24a40d57 Iustin Pop
          purpose. Note that this option can be dangerous as errors in
1290 24a40d57 Iustin Pop
          shutting down the instance will be ignored, resulting in
1291 24a40d57 Iustin Pop
          possibly having the instance running on two machines in
1292 24a40d57 Iustin Pop
          parallel (on disconnected DRBD drives).
1293 a8083063 Iustin Pop
        </para>
1294 a8083063 Iustin Pop
1295 a8083063 Iustin Pop
        <para>
1296 a8083063 Iustin Pop
          Example:
1297 a8083063 Iustin Pop
          <screen>
1298 a8083063 Iustin Pop
# gnt-instance failover instance1.example.com
1299 a8083063 Iustin Pop
          </screen>
1300 a8083063 Iustin Pop
        </para>
1301 a8083063 Iustin Pop
      </refsect3>
1302 a8083063 Iustin Pop
1303 a8083063 Iustin Pop
    </refsect2>
1304 a8083063 Iustin Pop
1305 cc425644 Iustin Pop
    <refsect2>
1306 cc425644 Iustin Pop
      <title>TAGS</title>
1307 cc425644 Iustin Pop
1308 cc425644 Iustin Pop
    <refsect3>
1309 cc425644 Iustin Pop
        <title>ADD-TAGS</title>
1310 cc425644 Iustin Pop
1311 cc425644 Iustin Pop
        <cmdsynopsis>
1312 cc425644 Iustin Pop
          <command>add-tags</command>
1313 810c50b7 Iustin Pop
          <arg choice="opt">--from <replaceable>file</replaceable></arg>
1314 cc425644 Iustin Pop
          <arg choice="req"><replaceable>instancename</replaceable></arg>
1315 cc425644 Iustin Pop
          <arg choice="req"
1316 cc425644 Iustin Pop
            rep="repeat"><replaceable>tag</replaceable></arg>
1317 cc425644 Iustin Pop
        </cmdsynopsis>
1318 cc425644 Iustin Pop
1319 cc425644 Iustin Pop
        <para>
1320 cc425644 Iustin Pop
          Add tags to the given instance. If any of the tags contains
1321 cc425644 Iustin Pop
          invalid characters, the entire operation will abort.
1322 cc425644 Iustin Pop
        </para>
1323 810c50b7 Iustin Pop
        <para>
1324 810c50b7 Iustin Pop
          If the <option>--from</option> option is given, the list of
1325 810c50b7 Iustin Pop
          tags will be extended with the contents of that file (each
1326 810c50b7 Iustin Pop
          line becomes a tag). In this case, there is not need to pass
1327 810c50b7 Iustin Pop
          tags on the command line (if you do, both sources will be
1328 810c50b7 Iustin Pop
          used). A file name of - will be interpreted as stdin.
1329 810c50b7 Iustin Pop
        </para>
1330 cc425644 Iustin Pop
      </refsect3>
1331 cc425644 Iustin Pop
1332 cc425644 Iustin Pop
      <refsect3>
1333 cc425644 Iustin Pop
        <title>LIST-TAGS</title>
1334 cc425644 Iustin Pop
1335 cc425644 Iustin Pop
        <cmdsynopsis>
1336 cc425644 Iustin Pop
          <command>list-tags</command>
1337 cc425644 Iustin Pop
          <arg choice="req"><replaceable>instancename</replaceable></arg>
1338 cc425644 Iustin Pop
        </cmdsynopsis>
1339 cc425644 Iustin Pop
1340 cc425644 Iustin Pop
        <para>List the tags of the given instance.</para>
1341 cc425644 Iustin Pop
      </refsect3>
1342 cc425644 Iustin Pop
1343 cc425644 Iustin Pop
      <refsect3>
1344 cc425644 Iustin Pop
        <title>REMOVE-TAGS</title>
1345 cc425644 Iustin Pop
        <cmdsynopsis>
1346 cc425644 Iustin Pop
          <command>remove-tags</command>
1347 810c50b7 Iustin Pop
          <arg choice="opt">--from <replaceable>file</replaceable></arg>
1348 cc425644 Iustin Pop
          <arg choice="req"><replaceable>instancename</replaceable></arg>
1349 cc425644 Iustin Pop
          <arg choice="req"
1350 cc425644 Iustin Pop
            rep="repeat"><replaceable>tag</replaceable></arg>
1351 cc425644 Iustin Pop
        </cmdsynopsis>
1352 cc425644 Iustin Pop
1353 cc425644 Iustin Pop
        <para>
1354 cc425644 Iustin Pop
          Remove tags from the given instance. If any of the tags are
1355 cc425644 Iustin Pop
          not existing on the node, the entire operation will abort.
1356 cc425644 Iustin Pop
        </para>
1357 810c50b7 Iustin Pop
1358 810c50b7 Iustin Pop
        <para>
1359 810c50b7 Iustin Pop
          If the <option>--from</option> option is given, the list of
1360 810c50b7 Iustin Pop
          tags will be extended with the contents of that file (each
1361 810c50b7 Iustin Pop
          line becomes a tag). In this case, there is not need to pass
1362 810c50b7 Iustin Pop
          tags on the command line (if you do, both sources will be
1363 810c50b7 Iustin Pop
          used). A file name of - will be interpreted as stdin.
1364 810c50b7 Iustin Pop
        </para>
1365 cc425644 Iustin Pop
      </refsect3>
1366 cc425644 Iustin Pop
1367 cc425644 Iustin Pop
    </refsect2>
1368 cc425644 Iustin Pop
1369 a8083063 Iustin Pop
  </refsect1>
1370 a8083063 Iustin Pop
1371 a8083063 Iustin Pop
  &footer;
1372 a8083063 Iustin Pop
1373 a8083063 Iustin Pop
</refentry>
1374 a8083063 Iustin Pop
1375 a8083063 Iustin Pop
<!-- Keep this comment at the end of the file
1376 a8083063 Iustin Pop
Local variables:
1377 a8083063 Iustin Pop
mode: sgml
1378 a8083063 Iustin Pop
sgml-omittag:t
1379 a8083063 Iustin Pop
sgml-shorttag:t
1380 a8083063 Iustin Pop
sgml-minimize-attributes:nil
1381 a8083063 Iustin Pop
sgml-always-quote-attributes:t
1382 a8083063 Iustin Pop
sgml-indent-step:2
1383 a8083063 Iustin Pop
sgml-indent-data:t
1384 a8083063 Iustin Pop
sgml-parent-document:nil
1385 a8083063 Iustin Pop
sgml-default-dtd-file:nil
1386 a8083063 Iustin Pop
sgml-exposed-tags:nil
1387 a8083063 Iustin Pop
sgml-local-catalogs:nil
1388 a8083063 Iustin Pop
sgml-local-ecat-files:nil
1389 a8083063 Iustin Pop
End:
1390 a8083063 Iustin Pop
-->