Statistics
| Branch: | Tag: | Revision:

root / man / gnt-backup.sgml @ bdb7d4e8

History | View | Annotate | Download (8.5 kB)

1
<!doctype refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN" [
2

    
3
  <!-- Fill in your name for FIRSTNAME and SURNAME. -->
4
  <!-- Please adjust the date whenever revising the manpage. -->
5
  <!ENTITY dhdate      "<date>Jul 6, 2007</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-backup</refentrytitle>">
10
  <!ENTITY dhpackage   "gnt-backup">
11

    
12
  <!ENTITY debian      "<productname>Debian</productname>">
13
  <!ENTITY gnu         "<acronym>GNU</acronym>">
14
  <!ENTITY gpl         "&gnu; <acronym>GPL</acronym>">
15
  <!ENTITY footer SYSTEM "footer.sgml">
16
]>
17

    
18
<refentry>
19
  <refentryinfo>
20
    <copyright>
21
      <year>2007</year>
22
      <holder>Google Inc.</holder>
23
    </copyright>
24
    &dhdate;
25
  </refentryinfo>
26
  <refmeta>
27
    &dhucpackage;
28

    
29
    &dhsection;
30
    <refmiscinfo>ganeti 1.2</refmiscinfo>
31
  </refmeta>
32
  <refnamediv>
33
    <refname>&dhpackage;</refname>
34

    
35
    <refpurpose>ganeti instance import/export</refpurpose>
36
  </refnamediv>
37
  <refsynopsisdiv>
38
    <cmdsynopsis>
39
      <command>&dhpackage; </command>
40

    
41
      <arg choice="req">command</arg>
42
      <arg>arguments...</arg>
43
    </cmdsynopsis>
44
  </refsynopsisdiv>
45
  <refsect1>
46
    <title>DESCRIPTION</title>
47

    
48
    <para>
49
      The <command>&dhpackage;</command> is used for importing and exporting
50
      instances and their configuration from a ganeti system. It is useful for
51
      backing instances up and also to migrate them between clusters.
52
    </para>
53

    
54
  </refsect1>
55
  <refsect1>
56
    <title>COMMANDS</title>
57

    
58
    <refsect2>
59
      <title>EXPORT</title>
60

    
61
      <cmdsynopsis>
62
        <command>export</command>
63
        <arg choice="req">-n <replaceable>node</replaceable></arg>
64
        <arg>--noshutdown</arg>
65
        <arg choice="req"><replaceable>instance</replaceable></arg>
66
      </cmdsynopsis>
67

    
68
      <para>
69
        Exports an instance to the target node. All the instance data
70
        and its configuration will be exported under the
71
        /srv/ganeti/exports/<replaceable>instance</replaceable>
72
        directory on the target node.
73
      </para>
74

    
75
      <para>
76
        The <option>--noshutdown</option> option will create a
77
        snapshot disk of the instance without shutting it down first.
78
        While this is faster and involves no downtime, it cannot be
79
        guaranteed that the instance data will be in a consistent state
80
        in the exported dump.
81
      </para>
82

    
83
      <para>
84
        Example:
85
        <screen>
86
# gnt-backup export -n node1.example.com instance3.example.com
87
        </screen>
88
      </para>
89
    </refsect2>
90

    
91
    <refsect2>
92
      <title>IMPORT</title>
93
      <cmdsynopsis>
94
        <command>import</command>
95
        <arg choice="req">-n <replaceable>node<optional>:secondary-node</optional></replaceable></arg>
96
        <arg>-s <replaceable>disksize</replaceable></arg>
97
        <sbr>
98

    
99
        <arg>--swap-size <replaceable>disksize</replaceable></arg>
100
        <arg>-m <replaceable>memsize</replaceable></arg>
101
        <arg>-b <replaceable>bridge</replaceable></arg>
102
        <sbr>
103

    
104
        <arg choice="req">-t<group>
105
            <arg>diskless</arg>
106
            <arg>plain</arg>
107
            <arg>local_raid1</arg>
108
            <arg>remote_raid1</arg>
109
            <arg>drbd</arg>
110
          </group></arg>
111
        <sbr>
112

    
113
        <arg choice="req">--src-node=<replaceable>source-node</replaceable></arg>
114
        <arg choice="req">--src-dir=<replaceable>source-dir</replaceable></arg>
115
        <arg choice="req"><replaceable>instance</replaceable></arg>
116
      </cmdsynopsis>
117
      <para>
118
        Imports a new instance from an export residing on
119
        <replaceable>source-node</replaceable> in
120
        <replaceable>source-dir</replaceable>.
121
        <replaceable>instance</replaceable> must be in DNS and
122
        resolve to a IP in the same network as the nodes in the
123
        cluster.
124
      </para>
125

    
126
      <para>
127
        The <option>-s</option> option specifies the disk size for
128
        the instance, in mebibytes (defaults to
129
        <constant>20480MiB</constant> =
130
        <constant>20GiB</constant>). You can also use one of the
131
        suffixes <literal>m</literal>, <literal>g</literal> or
132
        <literal>t</literal> to specificy the exact the units used;
133
        these suffixes map to mebibytes, gibibytes and tebibytes.
134
      </para>
135

    
136
      <para>
137
        The <option>--swap-size</option> option specifies the swap
138
        disk size (in mebibytes) for the instance (the one presented
139
        as <filename class="devicefile">/dev/sdb</filename>). The
140
        default is <constant>4096MiB</constant>. As for the disk
141
        size, you can specify other suffixes.
142
      </para>
143

    
144
      <para>
145
        The <option>-m</option> option specifies the memory size for
146
        the instance, in mebibytes (defaults to 128 MiB). Again, you
147
        can use other suffixes (e.g. <userinput>2g</userinput>).
148
      </para>
149

    
150
      <para>
151
        The <option>-b</option> option specifies the bridge to which the
152
        instance will be connected. (defaults to the cluster-wide default
153
        bridge specified at cluster intialization time).
154
      </para>
155

    
156
      <para>
157
        The <option>-t</option> options specifies the disk layout type for
158
        the instance. The available choices are:
159
        <variablelist>
160
          <varlistentry>
161
            <term>diskless</term>
162
            <listitem>
163
              <para>
164
                This creates an instance with no disks. Its useful for
165
                testing only (or other special cases).
166
              </para>
167
            </listitem>
168
          </varlistentry>
169
          <varlistentry>
170
            <term>plain</term>
171
            <listitem>
172
              <para>Disk devices will be logical volumes.</para>
173
            </listitem>
174
          </varlistentry>
175
          <varlistentry>
176
            <term>local_raid1</term>
177
            <listitem>
178
              <para>
179
                Disk devices will be md raid1 arrays over two local
180
                logical volumes.
181
              </para>
182
            </listitem>
183
          </varlistentry>
184
          <varlistentry>
185
            <term>remote_raid1</term>
186
            <listitem>
187
              <para>
188
                Disk devices will be md raid1 arrays with one
189
                component (so it's not actually raid1): a drbd (0.7.x)
190
                device between the instance's primary node and the
191
                node given by the second value of the
192
                <option>--node</option> option.
193
              </para>
194
            </listitem>
195
          </varlistentry>
196
          <varlistentry>
197
            <term>drbd</term>
198
            <listitem>
199
              <para>
200
                Disk devices will be drbd (version 8.x) on top of lvm
201
                volumes. They are equivalent in functionality to
202
                <replaceable>remote_raid1</replaceable>, but are
203
                recommended for new instances (if you have drbd 8.x
204
                installed).
205
              </para>
206
            </listitem>
207
          </varlistentry>
208
        </variablelist>
209
      </para>
210

    
211
      <para>
212
        The optional second value of the <option>--node</option> is used for
213
        the remote raid template type and specifies the remote node.
214
      </para>
215

    
216
      <para>
217
        If you do not want gnt-backup to wait for the disk mirror
218
        to be synced, use the <option>--no-wait-for-sync</option>
219
        option.
220
      </para>
221

    
222
      <para>
223
        Example:
224
        <screen>
225
# gnt-backup import -t plain -s 30 -m 512 -n node1.example.com \
226
> --src-node=node2.example.com \
227
> --src-dir=/srv/ganeti/exports/instance3.example.com \
228
> instance3.example.com
229
        </screen>
230
      </para>
231

    
232
    </refsect2>
233

    
234
    <refsect2>
235
      <title>LIST</title>
236

    
237
      <cmdsynopsis>
238
        <command>list</command>
239
        <arg>--node=<replaceable>NODE</replaceable></arg>
240
      </cmdsynopsis>
241

    
242
      <para>
243
        Lists the exports currently available in the default directory
244
        in all the nodes of the current cluster, or optionally only a
245
        subset of them specified using the <option>--node</option>
246
        option (which can be used multiple times)
247
      </para>
248

    
249
      <para>
250
      Example:
251
<screen>
252
# gnt-backup list --nodes node1 --nodes node2
253
</screen>
254
    </refsect2>
255

    
256
  </refsect1>
257

    
258
  &footer;
259

    
260
</refentry>
261

    
262
<!-- Keep this comment at the end of the file
263
Local variables:
264
mode: sgml
265
sgml-omittag:t
266
sgml-shorttag:t
267
sgml-minimize-attributes:nil
268
sgml-always-quote-attributes:t
269
sgml-indent-step:2
270
sgml-indent-data:t
271
sgml-parent-document:nil
272
sgml-default-dtd-file:nil
273
sgml-exposed-tags:nil
274
sgml-local-catalogs:nil
275
sgml-local-ecat-files:nil
276
End:
277
-->