root / man / gnt-instance.sgml @ ed2d1409
History | View | Annotate | Download (31.7 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 | a8083063 | Iustin Pop | <!ENTITY dhdate "<date>May 16, 2007</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 | a8083063 | Iustin Pop | <holder>Google Inc.</holder> |
24 | a8083063 | Iustin Pop | </copyright> |
25 | a8083063 | Iustin Pop | &dhdate; |
26 | a8083063 | Iustin Pop | </refentryinfo> |
27 | a8083063 | Iustin Pop | <refmeta> |
28 | a8083063 | Iustin Pop | &dhucpackage; |
29 | a8083063 | Iustin Pop | |
30 | a8083063 | Iustin Pop | &dhsection; |
31 | a8083063 | Iustin Pop | <refmiscinfo>ganeti 1.2</refmiscinfo> |
32 | a8083063 | Iustin Pop | </refmeta> |
33 | a8083063 | Iustin Pop | <refnamediv> |
34 | a8083063 | Iustin Pop | <refname>&dhpackage;</refname> |
35 | a8083063 | Iustin Pop | |
36 | a8083063 | Iustin Pop | <refpurpose>ganeti instance administration</refpurpose> |
37 | a8083063 | Iustin Pop | </refnamediv> |
38 | a8083063 | Iustin Pop | <refsynopsisdiv> |
39 | a8083063 | Iustin Pop | <cmdsynopsis> |
40 | a8083063 | Iustin Pop | <command>&dhpackage; </command> |
41 | a8083063 | Iustin Pop | |
42 | a8083063 | Iustin Pop | <arg choice="req">command</arg> |
43 | a8083063 | Iustin Pop | <arg>arguments...</arg> |
44 | a8083063 | Iustin Pop | </cmdsynopsis> |
45 | a8083063 | Iustin Pop | </refsynopsisdiv> |
46 | a8083063 | Iustin Pop | <refsect1> |
47 | a8083063 | Iustin Pop | <title>DESCRIPTION</title> |
48 | a8083063 | Iustin Pop | |
49 | a8083063 | Iustin Pop | <para> |
50 | a8083063 | Iustin Pop | The <command>&dhpackage;</command> is used for instance |
51 | a8083063 | Iustin Pop | administration in the ganeti system. |
52 | a8083063 | Iustin Pop | </para> |
53 | a8083063 | Iustin Pop | |
54 | a8083063 | Iustin Pop | </refsect1> |
55 | a8083063 | Iustin Pop | <refsect1> |
56 | a8083063 | Iustin Pop | <title>COMMANDS</title> |
57 | a8083063 | Iustin Pop | |
58 | a8083063 | Iustin Pop | <refsect2> |
59 | a8083063 | Iustin Pop | <title>Creation/removal/querying</title> |
60 | a8083063 | Iustin Pop | |
61 | a8083063 | Iustin Pop | <refsect3> |
62 | a8083063 | Iustin Pop | <title>ADD</title> |
63 | a8083063 | Iustin Pop | <cmdsynopsis> |
64 | a8083063 | Iustin Pop | <command>add</command> |
65 | a8083063 | Iustin Pop | <arg>-s <replaceable>disksize</replaceable></arg> |
66 | b9ac33e9 | Iustin Pop | <arg>--swap-size <replaceable>disksize</replaceable></arg> |
67 | a8083063 | Iustin Pop | <arg>-m <replaceable>memsize</replaceable></arg> |
68 | b9ac33e9 | Iustin Pop | <sbr> |
69 | b9ac33e9 | Iustin Pop | <arg>-o <replaceable>os-type</replaceable></arg> |
70 | a8083063 | Iustin Pop | <arg>-b <replaceable>bridge</replaceable></arg> |
71 | a8083063 | Iustin Pop | <sbr> |
72 | a8083063 | Iustin Pop | <arg choice="req">-t<group> |
73 | a8083063 | Iustin Pop | <arg>diskless</arg> |
74 | a8083063 | Iustin Pop | <arg>plain</arg> |
75 | a8083063 | Iustin Pop | <arg>local_raid1</arg> |
76 | a8083063 | Iustin Pop | <arg>remote_raid1</arg> |
77 | f69dab6d | Iustin Pop | <arg>drbd</arg> |
78 | a8083063 | Iustin Pop | </group> |
79 | a8083063 | Iustin Pop | </arg> |
80 | b9ac33e9 | Iustin Pop | <sbr> |
81 | 4677a909 | Michael Hanselmann | <arg choice="req">-n <replaceable>node<optional>:secondary-node</optional></replaceable></arg> |
82 | a8083063 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
83 | a8083063 | Iustin Pop | </cmdsynopsis> |
84 | a8083063 | Iustin Pop | <para> |
85 | a8083063 | Iustin Pop | Creates a new instance on the specified |
86 | a8083063 | Iustin Pop | host. <replaceable>instance</replaceable> must be in DNS and |
87 | a8083063 | Iustin Pop | resolve to a IP in the same network as the nodes in the |
88 | a8083063 | Iustin Pop | cluster. |
89 | a8083063 | Iustin Pop | </para> |
90 | a8083063 | Iustin Pop | |
91 | a8083063 | Iustin Pop | <para> |
92 | a8083063 | Iustin Pop | The <option>-s</option> option specifies the disk size for |
93 | b9ac33e9 | Iustin Pop | the instance, in mebibytes (defaults to |
94 | b9ac33e9 | Iustin Pop | <constant>20480MiB</constant> = |
95 | b9ac33e9 | Iustin Pop | <constant>20GiB</constant>). You can also use one of the |
96 | b9ac33e9 | Iustin Pop | suffixes <literal>m</literal>, <literal>g</literal> or |
97 | b9ac33e9 | Iustin Pop | <literal>t</literal> to specificy the exact the units used; |
98 | b9ac33e9 | Iustin Pop | these suffixes map to mebibytes, gibibytes and tebibytes. |
99 | a8083063 | Iustin Pop | </para> |
100 | a8083063 | Iustin Pop | |
101 | a8083063 | Iustin Pop | <para> |
102 | b9ac33e9 | Iustin Pop | The <option>--swap-size</option> option specifies the swap |
103 | b9ac33e9 | Iustin Pop | disk size (in mebibytes) for the instance (the one presented |
104 | b9ac33e9 | Iustin Pop | as <filename class="devicefile">/dev/sdb</filename>). The |
105 | b9ac33e9 | Iustin Pop | default is <constant>4096MiB</constant>. As for the disk |
106 | b9ac33e9 | Iustin Pop | size, you can specify other suffixes. |
107 | a8083063 | Iustin Pop | </para> |
108 | a8083063 | Iustin Pop | |
109 | a8083063 | Iustin Pop | <para> |
110 | a8083063 | Iustin Pop | The <option>-m</option> option specifies the memory size for |
111 | b9ac33e9 | Iustin Pop | the instance, in mebibytes (defaults to 128 MiB). Again, you |
112 | b9ac33e9 | Iustin Pop | can use other suffixes (e.g. <userinput>2g</userinput>). |
113 | b9ac33e9 | Iustin Pop | </para> |
114 | b9ac33e9 | Iustin Pop | |
115 | b9ac33e9 | Iustin Pop | <para> |
116 | b9ac33e9 | Iustin Pop | The <option>-o</option> options specifies the operating |
117 | b9ac33e9 | Iustin Pop | system to be installed. The available operating systems can |
118 | b9ac33e9 | Iustin Pop | be listed with <command>gnt-os list</command>. |
119 | a8083063 | Iustin Pop | </para> |
120 | a8083063 | Iustin Pop | |
121 | a8083063 | Iustin Pop | <para> |
122 | a8083063 | Iustin Pop | The <option>-b</option> option specifies the bridge to which the |
123 | a8083063 | Iustin Pop | instance will be connected. (defaults to the cluster-wide default |
124 | 7e84d392 | Michael Hanselmann | bridge specified at cluster initialization time). |
125 | a8083063 | Iustin Pop | </para> |
126 | a8083063 | Iustin Pop | |
127 | a8083063 | Iustin Pop | <para> |
128 | a8083063 | Iustin Pop | The <option>-t</option> options specifies the disk layout type for |
129 | a8083063 | Iustin Pop | the instance. The available choices are: |
130 | a8083063 | Iustin Pop | <variablelist> |
131 | a8083063 | Iustin Pop | <varlistentry> |
132 | a8083063 | Iustin Pop | <term>diskless</term> |
133 | a8083063 | Iustin Pop | <listitem> |
134 | a8083063 | Iustin Pop | <para> |
135 | a8083063 | Iustin Pop | This creates an instance with no disks. Its useful for |
136 | a8083063 | Iustin Pop | testing only (or other special cases). |
137 | a8083063 | Iustin Pop | </para> |
138 | a8083063 | Iustin Pop | </listitem> |
139 | a8083063 | Iustin Pop | </varlistentry> |
140 | a8083063 | Iustin Pop | <varlistentry> |
141 | a8083063 | Iustin Pop | <term>plain</term> |
142 | a8083063 | Iustin Pop | <listitem> |
143 | a8083063 | Iustin Pop | <para>Disk devices will be logical volumes.</para> |
144 | a8083063 | Iustin Pop | </listitem> |
145 | a8083063 | Iustin Pop | </varlistentry> |
146 | a8083063 | Iustin Pop | <varlistentry> |
147 | a8083063 | Iustin Pop | <term>local_raid1</term> |
148 | a8083063 | Iustin Pop | <listitem> |
149 | a8083063 | Iustin Pop | <para> |
150 | a8083063 | Iustin Pop | Disk devices will be md raid1 arrays over two local |
151 | a8083063 | Iustin Pop | logical volumes. |
152 | a8083063 | Iustin Pop | </para> |
153 | a8083063 | Iustin Pop | </listitem> |
154 | a8083063 | Iustin Pop | </varlistentry> |
155 | a8083063 | Iustin Pop | <varlistentry> |
156 | a8083063 | Iustin Pop | <term>remote_raid1</term> |
157 | a8083063 | Iustin Pop | <listitem> |
158 | a8083063 | Iustin Pop | <para> |
159 | f69dab6d | Iustin Pop | Disk devices will be md raid1 arrays with one |
160 | f69dab6d | Iustin Pop | component (so it's not actually raid1): a drbd |
161 | f69dab6d | Iustin Pop | (0.7.x) device between the instance's primary node |
162 | f69dab6d | Iustin Pop | and the node given by the second value of the |
163 | f69dab6d | Iustin Pop | <option>--node</option> option. |
164 | f69dab6d | Iustin Pop | </para> |
165 | f69dab6d | Iustin Pop | </listitem> |
166 | f69dab6d | Iustin Pop | </varlistentry> |
167 | f69dab6d | Iustin Pop | <varlistentry> |
168 | f69dab6d | Iustin Pop | <term>drbd</term> |
169 | f69dab6d | Iustin Pop | <listitem> |
170 | f69dab6d | Iustin Pop | <para> |
171 | f69dab6d | Iustin Pop | Disk devices will be drbd (version 8.x) on top of |
172 | f69dab6d | Iustin Pop | lvm volumes. They are equivalent in functionality to |
173 | f69dab6d | Iustin Pop | <replaceable>remote_raid1</replaceable>, but are |
174 | f69dab6d | Iustin Pop | recommended for new instances (if you have drbd 8.x |
175 | f69dab6d | Iustin Pop | installed). |
176 | a8083063 | Iustin Pop | </para> |
177 | a8083063 | Iustin Pop | </listitem> |
178 | a8083063 | Iustin Pop | </varlistentry> |
179 | a8083063 | Iustin Pop | </variablelist> |
180 | a8083063 | Iustin Pop | </para> |
181 | a8083063 | Iustin Pop | |
182 | a8083063 | Iustin Pop | <para> |
183 | 4677a909 | Michael Hanselmann | The optional second value of the <option>--node</option> is used for |
184 | 4677a909 | Michael Hanselmann | the remote raid template type and specifies the remote node. |
185 | a8083063 | Iustin Pop | </para> |
186 | a8083063 | Iustin Pop | |
187 | a8083063 | Iustin Pop | <para> |
188 | a8083063 | Iustin Pop | If you do not want gnt-instance to wait for the disk mirror |
189 | a8083063 | Iustin Pop | to be synced, use the <option>--no-wait-for-sync</option> |
190 | a8083063 | Iustin Pop | option. |
191 | a8083063 | Iustin Pop | </para> |
192 | a8083063 | Iustin Pop | |
193 | a8083063 | Iustin Pop | <para> |
194 | a8083063 | Iustin Pop | Example: |
195 | a8083063 | Iustin Pop | <screen> |
196 | b9ac33e9 | Iustin Pop | # gnt-instance add -t plain -s 30g -m 512 -o debian-etch \ |
197 | b9ac33e9 | Iustin Pop | -n node1.example.com instance1.example.com |
198 | 4677a909 | Michael Hanselmann | # gnt-instance add -t remote_raid1 -s 30g -m 512 -o debian-etch \ |
199 | 4677a909 | Michael Hanselmann | -n node1.example.com:node2.example.com instance2.example.com |
200 | a8083063 | Iustin Pop | </screen> |
201 | a8083063 | Iustin Pop | </para> |
202 | a8083063 | Iustin Pop | </refsect3> |
203 | a8083063 | Iustin Pop | |
204 | a8083063 | Iustin Pop | <refsect3> |
205 | a8083063 | Iustin Pop | <title>REMOVE</title> |
206 | a8083063 | Iustin Pop | |
207 | a8083063 | Iustin Pop | <cmdsynopsis> |
208 | a8083063 | Iustin Pop | <command>remove</command> |
209 | 1d67656e | Iustin Pop | <arg>--ignore-failures</arg> |
210 | a8083063 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
211 | a8083063 | Iustin Pop | </cmdsynopsis> |
212 | a8083063 | Iustin Pop | |
213 | a8083063 | Iustin Pop | <para> |
214 | a8083063 | Iustin Pop | Remove an instance. This will remove all data from the |
215 | a8083063 | Iustin Pop | instance and there is <emphasis>no way back</emphasis>. If |
216 | a8083063 | Iustin Pop | you are not sure if you use an instance again, use |
217 | a8083063 | Iustin Pop | <command>shutdown</command> first and leave it in the |
218 | a8083063 | Iustin Pop | shutdown state for a while. |
219 | 1d67656e | Iustin Pop | |
220 | 1d67656e | Iustin Pop | </para> |
221 | 1d67656e | Iustin Pop | |
222 | 1d67656e | Iustin Pop | <para> |
223 | 1d67656e | Iustin Pop | The <option>--ignore-failures</option> option will cause the |
224 | 1d67656e | Iustin Pop | removal to proceed even in the presence of errors during the |
225 | 1d67656e | Iustin Pop | removal of the instance (e.g. during the shutdown or the |
226 | 1d67656e | Iustin Pop | disk removal). If this option is not given, the command will |
227 | 1d67656e | Iustin Pop | stop at the first error. |
228 | a8083063 | Iustin Pop | </para> |
229 | a8083063 | Iustin Pop | |
230 | a8083063 | Iustin Pop | <para> |
231 | a8083063 | Iustin Pop | Example: |
232 | a8083063 | Iustin Pop | <screen> |
233 | a8083063 | Iustin Pop | # gnt-instance remove instance1.example.com |
234 | a8083063 | Iustin Pop | </screen> |
235 | a8083063 | Iustin Pop | </para> |
236 | a8083063 | Iustin Pop | </refsect3> |
237 | a8083063 | Iustin Pop | |
238 | a8083063 | Iustin Pop | <refsect3> |
239 | a8083063 | Iustin Pop | <title>LIST</title> |
240 | a8083063 | Iustin Pop | |
241 | a8083063 | Iustin Pop | <cmdsynopsis> |
242 | a8083063 | Iustin Pop | <command>list</command> |
243 | a8083063 | Iustin Pop | <arg>--no-headers</arg> |
244 | a8083063 | Iustin Pop | <arg>--separator=<replaceable>SEPARATOR</replaceable></arg> |
245 | a8083063 | Iustin Pop | <arg>-o <replaceable>FIELD,...</replaceable></arg> |
246 | a8083063 | Iustin Pop | </cmdsynopsis> |
247 | a8083063 | Iustin Pop | |
248 | a8083063 | Iustin Pop | <para> |
249 | a8083063 | Iustin Pop | Shows the currently configured instances with memory usage, |
250 | a8083063 | Iustin Pop | disk usage, the node they are running on, and the CPU time, |
251 | a8083063 | Iustin Pop | counted in seconds, used by each instance since its latest |
252 | a8083063 | Iustin Pop | restart. |
253 | a8083063 | Iustin Pop | </para> |
254 | a8083063 | Iustin Pop | |
255 | a8083063 | Iustin Pop | <para> |
256 | a8083063 | Iustin Pop | The <option>--no-headers</option> option will skip the |
257 | a8083063 | Iustin Pop | initial header line. The <option>--separator</option> option |
258 | a8083063 | Iustin Pop | takes an argument which denotes what will be used between |
259 | a8083063 | Iustin Pop | the output fields. Both these options are to help scripting. |
260 | a8083063 | Iustin Pop | </para> |
261 | a8083063 | Iustin Pop | |
262 | a8083063 | Iustin Pop | <para> |
263 | a8083063 | Iustin Pop | The <option>-o</option> option takes a comma-separated list |
264 | a8083063 | Iustin Pop | of output fields. The available fields and their meaning |
265 | a8083063 | Iustin Pop | are: |
266 | a8083063 | Iustin Pop | <variablelist> |
267 | a8083063 | Iustin Pop | <varlistentry> |
268 | a8083063 | Iustin Pop | <term>name</term> |
269 | a8083063 | Iustin Pop | <listitem> |
270 | a8083063 | Iustin Pop | <simpara>the instance name</simpara> |
271 | a8083063 | Iustin Pop | </listitem> |
272 | a8083063 | Iustin Pop | </varlistentry> |
273 | a8083063 | Iustin Pop | <varlistentry> |
274 | a8083063 | Iustin Pop | <term>os</term> |
275 | a8083063 | Iustin Pop | <listitem> |
276 | a8083063 | Iustin Pop | <simpara>the OS of the instance</simpara> |
277 | a8083063 | Iustin Pop | </listitem> |
278 | a8083063 | Iustin Pop | </varlistentry> |
279 | a8083063 | Iustin Pop | <varlistentry> |
280 | a8083063 | Iustin Pop | <term>pnode</term> |
281 | a8083063 | Iustin Pop | <listitem> |
282 | a8083063 | Iustin Pop | <simpara>the primary node of the instance</simpara> |
283 | a8083063 | Iustin Pop | </listitem> |
284 | a8083063 | Iustin Pop | </varlistentry> |
285 | a8083063 | Iustin Pop | <varlistentry> |
286 | a8083063 | Iustin Pop | <term>snodes</term> |
287 | a8083063 | Iustin Pop | <listitem> |
288 | 4677a909 | Michael Hanselmann | <simpara>comma-separated list of secondary nodes for the |
289 | a8083063 | Iustin Pop | instance; usually this will be just one node</simpara> |
290 | a8083063 | Iustin Pop | </listitem> |
291 | a8083063 | Iustin Pop | </varlistentry> |
292 | a8083063 | Iustin Pop | <varlistentry> |
293 | a8083063 | Iustin Pop | <term>admin_state</term> |
294 | a8083063 | Iustin Pop | <listitem> |
295 | a8083063 | Iustin Pop | <simpara>the desired state of the instance (either "yes" |
296 | a8083063 | Iustin Pop | or "no" denoting the instance should run or |
297 | a8083063 | Iustin Pop | not)</simpara> |
298 | a8083063 | Iustin Pop | </listitem> |
299 | a8083063 | Iustin Pop | </varlistentry> |
300 | a8083063 | Iustin Pop | <varlistentry> |
301 | a8083063 | Iustin Pop | <term>admin_ram</term> |
302 | a8083063 | Iustin Pop | <listitem> |
303 | a8083063 | Iustin Pop | <simpara>the desired memory for the instance</simpara> |
304 | a8083063 | Iustin Pop | </listitem> |
305 | a8083063 | Iustin Pop | </varlistentry> |
306 | a8083063 | Iustin Pop | <varlistentry> |
307 | a8083063 | Iustin Pop | <term>disk_template</term> |
308 | a8083063 | Iustin Pop | <listitem> |
309 | a8083063 | Iustin Pop | <simpara>the disk template of the instance</simpara> |
310 | a8083063 | Iustin Pop | </listitem> |
311 | a8083063 | Iustin Pop | </varlistentry> |
312 | a8083063 | Iustin Pop | <varlistentry> |
313 | a8083063 | Iustin Pop | <term>oper_state</term> |
314 | a8083063 | Iustin Pop | <listitem> |
315 | a8083063 | Iustin Pop | <simpara>the actual state of the instance; can take of |
316 | a8083063 | Iustin Pop | the values "running", "stopped", "(node down)"</simpara> |
317 | a8083063 | Iustin Pop | </listitem> |
318 | a8083063 | Iustin Pop | </varlistentry> |
319 | a8083063 | Iustin Pop | <varlistentry> |
320 | a8083063 | Iustin Pop | <term>oper_ram</term> |
321 | a8083063 | Iustin Pop | <listitem> |
322 | a8083063 | Iustin Pop | <simpara>the actual memory usage of the instance as seen |
323 | a8083063 | Iustin Pop | by the hypervisor</simpara> |
324 | a8083063 | Iustin Pop | </listitem> |
325 | a8083063 | Iustin Pop | </varlistentry> |
326 | a8083063 | Iustin Pop | <varlistentry> |
327 | a8083063 | Iustin Pop | <term>ip</term> |
328 | a8083063 | Iustin Pop | <listitem> |
329 | a8083063 | Iustin Pop | <simpara>the ip address ganeti recognizes as associated with |
330 | a8083063 | Iustin Pop | the instance interface</simpara> |
331 | a8083063 | Iustin Pop | </listitem> |
332 | a8083063 | Iustin Pop | </varlistentry> |
333 | a8083063 | Iustin Pop | <varlistentry> |
334 | a8083063 | Iustin Pop | <term>mac</term> |
335 | a8083063 | Iustin Pop | <listitem> |
336 | a8083063 | Iustin Pop | <simpara>the instance interface MAC address</simpara> |
337 | a8083063 | Iustin Pop | </listitem> |
338 | a8083063 | Iustin Pop | </varlistentry> |
339 | a8083063 | Iustin Pop | <varlistentry> |
340 | a8083063 | Iustin Pop | <term>bridge</term> |
341 | a8083063 | Iustin Pop | <listitem> |
342 | a8083063 | Iustin Pop | <simpara>bridge the instance is connected to |
343 | a8083063 | Iustin Pop | </simpara> |
344 | a8083063 | Iustin Pop | </listitem> |
345 | a8083063 | Iustin Pop | </varlistentry> |
346 | a8083063 | Iustin Pop | </variablelist> |
347 | a8083063 | Iustin Pop | </para> |
348 | a8083063 | Iustin Pop | |
349 | a8083063 | Iustin Pop | <para> |
350 | a8083063 | Iustin Pop | There is a subtle grouping about the available output |
351 | a8083063 | Iustin Pop | fields: all fields except for <option>oper_state</option> |
352 | a8083063 | Iustin Pop | and <option>oper_ram</option> are configuration value and |
353 | a8083063 | Iustin Pop | not run-time values. So if you don't select any of the |
354 | a8083063 | Iustin Pop | <option>oper_*</option> fields, the query will be satisfied |
355 | a8083063 | Iustin Pop | instantly from the cluster configuration, without having to |
356 | a8083063 | Iustin Pop | ask the remote nodes for the data. This can be helpful for |
357 | a8083063 | Iustin Pop | big clusters when you only want some data and it makes sense |
358 | a8083063 | Iustin Pop | to specify a reduced set of output fields. |
359 | a8083063 | Iustin Pop | </para> |
360 | a8083063 | Iustin Pop | |
361 | a8083063 | Iustin Pop | <para>The default output field list is: |
362 | a8083063 | Iustin Pop | <simplelist type="inline"> |
363 | a8083063 | Iustin Pop | <member>name</member> |
364 | a8083063 | Iustin Pop | <member>os</member> |
365 | a8083063 | Iustin Pop | <member>pnode</member> |
366 | a8083063 | Iustin Pop | <member>admin_state</member> |
367 | a8083063 | Iustin Pop | <member>oper_state</member> |
368 | a8083063 | Iustin Pop | <member>oper_ram</member> |
369 | a8083063 | Iustin Pop | </simplelist>. |
370 | a8083063 | Iustin Pop | </para> |
371 | a8083063 | Iustin Pop | </refsect3> |
372 | a8083063 | Iustin Pop | |
373 | a8083063 | Iustin Pop | <refsect3> |
374 | a8083063 | Iustin Pop | <title>INFO</title> |
375 | a8083063 | Iustin Pop | |
376 | a8083063 | Iustin Pop | <cmdsynopsis> |
377 | a8083063 | Iustin Pop | <command>info</command> |
378 | a8083063 | Iustin Pop | <arg rep="repeat"><replaceable>instance</replaceable></arg> |
379 | a8083063 | Iustin Pop | </cmdsynopsis> |
380 | a8083063 | Iustin Pop | |
381 | a8083063 | Iustin Pop | <para> |
382 | a8083063 | Iustin Pop | Show detailed information about the (given) instances. This |
383 | a8083063 | Iustin Pop | is different from <command>list</command> as it shows |
384 | a8083063 | Iustin Pop | detailed data about the instance's disks (especially useful |
385 | a8083063 | Iustin Pop | for remote raid templates). |
386 | a8083063 | Iustin Pop | </para> |
387 | a8083063 | Iustin Pop | </refsect3> |
388 | a8083063 | Iustin Pop | |
389 | a8083063 | Iustin Pop | <refsect3> |
390 | a8083063 | Iustin Pop | <title>MODIFY</title> |
391 | a8083063 | Iustin Pop | |
392 | a8083063 | Iustin Pop | <cmdsynopsis> |
393 | a8083063 | Iustin Pop | <command>modify</command> |
394 | a8083063 | Iustin Pop | <arg choice="opt">-m <replaceable>memsize</replaceable></arg> |
395 | a8083063 | Iustin Pop | <arg choice="opt">-p <replaceable>vcpus</replaceable></arg> |
396 | a8083063 | Iustin Pop | <arg choice="opt">-i <replaceable>ip</replaceable></arg> |
397 | a8083063 | Iustin Pop | <arg choice="opt">-b <replaceable>bridge</replaceable></arg> |
398 | a8083063 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
399 | a8083063 | Iustin Pop | </cmdsynopsis> |
400 | a8083063 | Iustin Pop | |
401 | a8083063 | Iustin Pop | <para> |
402 | a8083063 | Iustin Pop | Modify the memory size, number of vcpus, ip address and/or bridge |
403 | a8083063 | Iustin Pop | for an instance. |
404 | a8083063 | Iustin Pop | </para> |
405 | a8083063 | Iustin Pop | |
406 | a8083063 | Iustin Pop | <para> |
407 | a8083063 | Iustin Pop | The memory size is given in MiB. Note that you need to give |
408 | a8083063 | Iustin Pop | at least one of the arguments, otherwise the command |
409 | a8083063 | Iustin Pop | complains. |
410 | a8083063 | Iustin Pop | </para> |
411 | a8083063 | Iustin Pop | |
412 | a8083063 | Iustin Pop | <para> |
413 | a8083063 | Iustin Pop | All the changes take effect at the next restart. If the |
414 | a8083063 | Iustin Pop | instance is running, there is no effect on the instance. |
415 | a8083063 | Iustin Pop | </para> |
416 | a8083063 | Iustin Pop | </refsect3> |
417 | a8083063 | Iustin Pop | |
418 | d0834de3 | Michael Hanselmann | <refsect3> |
419 | d0834de3 | Michael Hanselmann | <title>REINSTALL</title> |
420 | d0834de3 | Michael Hanselmann | |
421 | d0834de3 | Michael Hanselmann | <cmdsynopsis> |
422 | d0834de3 | Michael Hanselmann | <command>reinstall</command> |
423 | d0834de3 | Michael Hanselmann | <arg choice="opt">-o <replaceable>os-type</replaceable></arg> |
424 | d0834de3 | Michael Hanselmann | <arg choice="opt">-f <replaceable>force</replaceable></arg> |
425 | d0834de3 | Michael Hanselmann | <arg choice="req"><replaceable>instance</replaceable></arg> |
426 | d0834de3 | Michael Hanselmann | </cmdsynopsis> |
427 | d0834de3 | Michael Hanselmann | |
428 | d0834de3 | Michael Hanselmann | <para> |
429 | d0834de3 | Michael Hanselmann | Reinstalls the operating system on the given instance. The instance |
430 | d0834de3 | Michael Hanselmann | must be stopped when running this command. If the |
431 | d0834de3 | Michael Hanselmann | <option>--os-type</option> is specified, the operating system is |
432 | d0834de3 | Michael Hanselmann | changed. |
433 | d0834de3 | Michael Hanselmann | </para> |
434 | d0834de3 | Michael Hanselmann | </refsect3> |
435 | d0834de3 | Michael Hanselmann | |
436 | decd5f45 | Iustin Pop | <refsect3> |
437 | decd5f45 | Iustin Pop | <title>RENAME</title> |
438 | decd5f45 | Iustin Pop | |
439 | decd5f45 | Iustin Pop | <cmdsynopsis> |
440 | decd5f45 | Iustin Pop | <command>rename</command> |
441 | decd5f45 | Iustin Pop | <arg>--no-ip-check</arg> |
442 | decd5f45 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
443 | decd5f45 | Iustin Pop | <arg choice="req"><replaceable>new_name</replaceable></arg> |
444 | decd5f45 | Iustin Pop | </cmdsynopsis> |
445 | decd5f45 | Iustin Pop | |
446 | decd5f45 | Iustin Pop | <para> |
447 | decd5f45 | Iustin Pop | Renames the given instance. The instance must be stopped |
448 | decd5f45 | Iustin Pop | when running this command. The requirements for the new name |
449 | decd5f45 | Iustin Pop | are the same as for adding an instance: the new name must be |
450 | decd5f45 | Iustin Pop | resolvable and the IP it resolves to must not be reachable |
451 | decd5f45 | Iustin Pop | (in order to prevent duplicate IPs the next time the |
452 | decd5f45 | Iustin Pop | instance is started). The IP test can be skipped if the |
453 | decd5f45 | Iustin Pop | <option>--no-ip-check</option> option is passed. |
454 | decd5f45 | Iustin Pop | </para> |
455 | decd5f45 | Iustin Pop | </refsect3> |
456 | decd5f45 | Iustin Pop | |
457 | a8083063 | Iustin Pop | </refsect2> |
458 | a8083063 | Iustin Pop | |
459 | a8083063 | Iustin Pop | <refsect2> |
460 | a8083063 | Iustin Pop | <title>Starting/stopping/connecting to console</title> |
461 | a8083063 | Iustin Pop | |
462 | a8083063 | Iustin Pop | <refsect3> |
463 | a8083063 | Iustin Pop | <title>STARTUP</title> |
464 | a8083063 | Iustin Pop | |
465 | a8083063 | Iustin Pop | <cmdsynopsis> |
466 | a8083063 | Iustin Pop | <command>startup</command> |
467 | a8083063 | Iustin Pop | <arg>--extra=<replaceable>PARAMS</replaceable></arg> |
468 | 3bd5f059 | Michael Hanselmann | <arg>--force</arg> |
469 | 312ac745 | Iustin Pop | <sbr> |
470 | 312ac745 | Iustin Pop | <group choice="opt"> |
471 | 312ac745 | Iustin Pop | <arg>--instance</arg> |
472 | 312ac745 | Iustin Pop | <arg>--node</arg> |
473 | 312ac745 | Iustin Pop | <arg>--primary</arg> |
474 | 312ac745 | Iustin Pop | <arg>--secondary</arg> |
475 | 312ac745 | Iustin Pop | <arg>--all</arg> |
476 | 312ac745 | Iustin Pop | </group> |
477 | 312ac745 | Iustin Pop | <sbr> |
478 | 312ac745 | Iustin Pop | <arg choice="opt" |
479 | 312ac745 | Iustin Pop | rep="repeat"><replaceable>name</replaceable></arg> |
480 | a8083063 | Iustin Pop | </cmdsynopsis> |
481 | a8083063 | Iustin Pop | |
482 | a8083063 | Iustin Pop | <para> |
483 | bcee9cb4 | Iustin Pop | Starts one or more instances, depending on the following |
484 | bcee9cb4 | Iustin Pop | options. The four available modes are: |
485 | 312ac745 | Iustin Pop | <variablelist> |
486 | 312ac745 | Iustin Pop | <varlistentry> |
487 | 312ac745 | Iustin Pop | <term><option>--instance</option></term> |
488 | 312ac745 | Iustin Pop | <listitem> |
489 | 312ac745 | Iustin Pop | <simpara>will start the instances given as arguments |
490 | 312ac745 | Iustin Pop | (at least one argument required); this is the default |
491 | 312ac745 | Iustin Pop | selection</simpara> |
492 | 312ac745 | Iustin Pop | </listitem> |
493 | 312ac745 | Iustin Pop | </varlistentry> |
494 | 312ac745 | Iustin Pop | <varlistentry> |
495 | 312ac745 | Iustin Pop | <term>--node</term> |
496 | 312ac745 | Iustin Pop | <listitem> |
497 | 312ac745 | Iustin Pop | <simpara>will start the instances who have the given |
498 | 312ac745 | Iustin Pop | node as either primary or secondary</simpara> |
499 | 312ac745 | Iustin Pop | </listitem> |
500 | 312ac745 | Iustin Pop | </varlistentry> |
501 | 312ac745 | Iustin Pop | <varlistentry> |
502 | 312ac745 | Iustin Pop | <term><option>--primary</option></term> |
503 | 312ac745 | Iustin Pop | <listitem> |
504 | 312ac745 | Iustin Pop | <simpara>will start all instances whose primary node |
505 | 312ac745 | Iustin Pop | is in the list of nodes passed as arguments (at least |
506 | 312ac745 | Iustin Pop | one node required)</simpara> |
507 | 312ac745 | Iustin Pop | </listitem> |
508 | 312ac745 | Iustin Pop | </varlistentry> |
509 | 312ac745 | Iustin Pop | <varlistentry> |
510 | 312ac745 | Iustin Pop | <term><option>--secondary</option></term> |
511 | 312ac745 | Iustin Pop | <listitem> |
512 | 312ac745 | Iustin Pop | <simpara>will start all instances whose secondary node |
513 | 312ac745 | Iustin Pop | is in the list of nodes passed as arguments (at least |
514 | 312ac745 | Iustin Pop | one node required)</simpara> |
515 | 312ac745 | Iustin Pop | </listitem> |
516 | 312ac745 | Iustin Pop | </varlistentry> |
517 | 312ac745 | Iustin Pop | <varlistentry> |
518 | 312ac745 | Iustin Pop | <term>--all</term> |
519 | 312ac745 | Iustin Pop | <listitem> |
520 | 312ac745 | Iustin Pop | <simpara>will start all instances in the cluster (no |
521 | 312ac745 | Iustin Pop | arguments accepted)</simpara> |
522 | 312ac745 | Iustin Pop | </listitem> |
523 | 312ac745 | Iustin Pop | </varlistentry> |
524 | 312ac745 | Iustin Pop | </variablelist> |
525 | 312ac745 | Iustin Pop | </para> |
526 | 312ac745 | Iustin Pop | |
527 | 312ac745 | Iustin Pop | <para> |
528 | bcee9cb4 | Iustin Pop | Note that although you can pass more than one selection |
529 | bcee9cb4 | Iustin Pop | option, the last one wins, so in order to guarantee the |
530 | bcee9cb4 | Iustin Pop | desired result, don't pass more than one such option. |
531 | a8083063 | Iustin Pop | </para> |
532 | a8083063 | Iustin Pop | |
533 | a8083063 | Iustin Pop | <para> |
534 | a8083063 | Iustin Pop | The <option>--extra</option> option is used to pass |
535 | a8083063 | Iustin Pop | additional argument to the instance's kernel for this start |
536 | a8083063 | Iustin Pop | only. Currently there is no way to specify a persistent set |
537 | a8083063 | Iustin Pop | of arguments (beside the one hardcoded). Note that this may |
538 | a8083063 | Iustin Pop | not apply to all virtualization types. |
539 | a8083063 | Iustin Pop | </para> |
540 | a8083063 | Iustin Pop | |
541 | 3bd5f059 | Michael Hanselmann | <para> |
542 | 3bd5f059 | Michael Hanselmann | Use <option>--force</option> to start even if secondary disks are |
543 | 3bd5f059 | Michael Hanselmann | failing. |
544 | 3bd5f059 | Michael Hanselmann | </para> |
545 | a8083063 | Iustin Pop | |
546 | a8083063 | Iustin Pop | <para> |
547 | a8083063 | Iustin Pop | Example: |
548 | a8083063 | Iustin Pop | <screen> |
549 | a8083063 | Iustin Pop | # gnt-instance start instance1.example.com |
550 | a8083063 | Iustin Pop | # gnt-instance start --extra single test1.example.com |
551 | bcee9cb4 | Iustin Pop | # gnt-instance start --node node1.example.com node2.example.com |
552 | bcee9cb4 | Iustin Pop | # gnt-instance start --all |
553 | a8083063 | Iustin Pop | </screen> |
554 | a8083063 | Iustin Pop | </para> |
555 | a8083063 | Iustin Pop | </refsect3> |
556 | a8083063 | Iustin Pop | |
557 | a8083063 | Iustin Pop | <refsect3> |
558 | a8083063 | Iustin Pop | <title>SHUTDOWN</title> |
559 | a8083063 | Iustin Pop | |
560 | a8083063 | Iustin Pop | <cmdsynopsis> |
561 | a8083063 | Iustin Pop | <command>shutdown</command> |
562 | 312ac745 | Iustin Pop | <sbr> |
563 | 312ac745 | Iustin Pop | <group choice="opt"> |
564 | 312ac745 | Iustin Pop | <arg>--instance</arg> |
565 | 312ac745 | Iustin Pop | <arg>--node</arg> |
566 | 312ac745 | Iustin Pop | <arg>--primary</arg> |
567 | 312ac745 | Iustin Pop | <arg>--secondary</arg> |
568 | 312ac745 | Iustin Pop | <arg>--all</arg> |
569 | 312ac745 | Iustin Pop | </group> |
570 | 312ac745 | Iustin Pop | <sbr> |
571 | 312ac745 | Iustin Pop | |
572 | 312ac745 | Iustin Pop | <arg choice="opt" |
573 | 312ac745 | Iustin Pop | rep="repeat"><replaceable>name</replaceable></arg> |
574 | a8083063 | Iustin Pop | </cmdsynopsis> |
575 | a8083063 | Iustin Pop | |
576 | a8083063 | Iustin Pop | <para> |
577 | 312ac745 | Iustin Pop | Stops one or more instances. If the instance cannot be |
578 | 312ac745 | Iustin Pop | cleanly stopped during a hardcoded interval (currently 2 |
579 | 312ac745 | Iustin Pop | minutes), it will forcibly stop the instance (equivalent to |
580 | 312ac745 | Iustin Pop | switching off the power on a physical machine). |
581 | 312ac745 | Iustin Pop | </para> |
582 | 312ac745 | Iustin Pop | |
583 | 312ac745 | Iustin Pop | <para> |
584 | 312ac745 | Iustin Pop | The <option>--instance</option>, <option>--node</option>, |
585 | 312ac745 | Iustin Pop | <option>--primary</option>, <option>--secondary</option> and |
586 | 312ac745 | Iustin Pop | <option>--all</option> options are similar as for the |
587 | 312ac745 | Iustin Pop | <command>startup</command> command and they influence the |
588 | 86b8c6ae | Alexander Schreiber | actual instances being shutdown. |
589 | a8083063 | Iustin Pop | </para> |
590 | a8083063 | Iustin Pop | |
591 | a8083063 | Iustin Pop | <para> |
592 | a8083063 | Iustin Pop | Example: |
593 | a8083063 | Iustin Pop | <screen> |
594 | a8083063 | Iustin Pop | # gnt-instance shutdown instance1.example.com |
595 | bcee9cb4 | Iustin Pop | # gnt-instance shutdown --all |
596 | a8083063 | Iustin Pop | </screen> |
597 | a8083063 | Iustin Pop | </para> |
598 | a8083063 | Iustin Pop | </refsect3> |
599 | a8083063 | Iustin Pop | |
600 | a8083063 | Iustin Pop | <refsect3> |
601 | 579d4337 | Alexander Schreiber | <title>REBOOT</title> |
602 | 579d4337 | Alexander Schreiber | |
603 | 579d4337 | Alexander Schreiber | <cmdsynopsis> |
604 | 579d4337 | Alexander Schreiber | <command>reboot</command> |
605 | 579d4337 | Alexander Schreiber | <sbr> |
606 | 579d4337 | Alexander Schreiber | <arg>--extra=<replaceable>PARAMS</replaceable></arg> |
607 | 579d4337 | Alexander Schreiber | <sbr> |
608 | 579d4337 | Alexander Schreiber | <arg>--type=<replaceable>REBOOT-TYPE</replaceable></arg> |
609 | 579d4337 | Alexander Schreiber | <sbr> |
610 | 579d4337 | Alexander Schreiber | <arg>--ignore-secondaries</arg> |
611 | 579d4337 | Alexander Schreiber | <sbr> |
612 | 579d4337 | Alexander Schreiber | <arg>--force-multiple</arg> |
613 | 579d4337 | Alexander Schreiber | <sbr> |
614 | 579d4337 | Alexander Schreiber | <group choice="opt"> |
615 | 579d4337 | Alexander Schreiber | <arg>--instance</arg> |
616 | 579d4337 | Alexander Schreiber | <arg>--node</arg> |
617 | 579d4337 | Alexander Schreiber | <arg>--primary</arg> |
618 | 579d4337 | Alexander Schreiber | <arg>--secondary</arg> |
619 | 579d4337 | Alexander Schreiber | <arg>--all</arg> |
620 | 579d4337 | Alexander Schreiber | </group> |
621 | 579d4337 | Alexander Schreiber | <sbr> |
622 | 579d4337 | Alexander Schreiber | |
623 | 579d4337 | Alexander Schreiber | <arg choice="opt" |
624 | 579d4337 | Alexander Schreiber | rep="repeat"><replaceable>name</replaceable></arg> |
625 | 579d4337 | Alexander Schreiber | </cmdsynopsis> |
626 | 579d4337 | Alexander Schreiber | |
627 | 579d4337 | Alexander Schreiber | <para> |
628 | 579d4337 | Alexander Schreiber | Reboots one or more instances. The type of reboot depends on |
629 | 579d4337 | Alexander Schreiber | the value of <option>--type</option>. A soft reboot does a |
630 | 579d4337 | Alexander Schreiber | hypervisor reboot, a hard reboot does a instance stop, |
631 | 579d4337 | Alexander Schreiber | recreates the hypervisor config for the instance and |
632 | 579d4337 | Alexander Schreiber | starts the instance. A full reboot does the equivalent |
633 | 579d4337 | Alexander Schreiber | of <command>gnt-instance shutdown && gnt-instance |
634 | 579d4337 | Alexander Schreiber | startup</command>. The default is soft reboot. |
635 | 579d4337 | Alexander Schreiber | </para> |
636 | 579d4337 | Alexander Schreiber | |
637 | 579d4337 | Alexander Schreiber | <para> |
638 | 579d4337 | Alexander Schreiber | For the hard reboot the option |
639 | 579d4337 | Alexander Schreiber | <option>--ignore-secondaries</option> ignores errors for the |
640 | 579d4337 | Alexander Schreiber | secondary node while re-assembling the instance disks. |
641 | 579d4337 | Alexander Schreiber | </para> |
642 | 579d4337 | Alexander Schreiber | |
643 | 579d4337 | Alexander Schreiber | <para> |
644 | 579d4337 | Alexander Schreiber | The <option>--instance</option>, <option>--node</option>, |
645 | 579d4337 | Alexander Schreiber | <option>--primary</option>, <option>--secondary</option> and |
646 | 579d4337 | Alexander Schreiber | <option>--all</option> options are similar as for the |
647 | 579d4337 | Alexander Schreiber | <command>startup</command> command and they influence the |
648 | 579d4337 | Alexander Schreiber | actual instances being rebooted. |
649 | 579d4337 | Alexander Schreiber | </para> |
650 | 36c87212 | Iustin Pop | |
651 | 579d4337 | Alexander Schreiber | <para> |
652 | 3bd5f059 | Michael Hanselmann | Use the <option>--force-multiple</option> option to keep |
653 | 579d4337 | Alexander Schreiber | gnt-instance from asking for confirmation when more than one |
654 | 579d4337 | Alexander Schreiber | instance is affected. |
655 | 579d4337 | Alexander Schreiber | </para> |
656 | 579d4337 | Alexander Schreiber | |
657 | 579d4337 | Alexander Schreiber | <para> |
658 | 579d4337 | Alexander Schreiber | Example: |
659 | 579d4337 | Alexander Schreiber | <screen> |
660 | 579d4337 | Alexander Schreiber | # gnt-instance reboot instance1.example.com |
661 | 579d4337 | Alexander Schreiber | # gnt-instance reboot --type=full instance1.example.com |
662 | 579d4337 | Alexander Schreiber | </screen> |
663 | 579d4337 | Alexander Schreiber | </para> |
664 | 579d4337 | Alexander Schreiber | </refsect3> |
665 | 579d4337 | Alexander Schreiber | |
666 | 579d4337 | Alexander Schreiber | <refsect3> |
667 | a8083063 | Iustin Pop | <title>CONSOLE</title> |
668 | a8083063 | Iustin Pop | <cmdsynopsis> |
669 | a8083063 | Iustin Pop | <command>console</command> |
670 | a8083063 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
671 | a8083063 | Iustin Pop | </cmdsynopsis> |
672 | a8083063 | Iustin Pop | |
673 | a8083063 | Iustin Pop | <para> |
674 | a8083063 | Iustin Pop | Connects to the console of the given instance. If the instance |
675 | a8083063 | Iustin Pop | is not up, an error is returned. |
676 | a8083063 | Iustin Pop | </para> |
677 | a8083063 | Iustin Pop | |
678 | a8083063 | Iustin Pop | <para> |
679 | a8083063 | Iustin Pop | Example: |
680 | a8083063 | Iustin Pop | <screen> |
681 | a8083063 | Iustin Pop | # gnt-instance console instance1.example.com |
682 | a8083063 | Iustin Pop | </screen> |
683 | a8083063 | Iustin Pop | </para> |
684 | a8083063 | Iustin Pop | </refsect3> |
685 | a8083063 | Iustin Pop | |
686 | a8083063 | Iustin Pop | </refsect2> |
687 | a8083063 | Iustin Pop | |
688 | a8083063 | Iustin Pop | <refsect2> |
689 | a8083063 | Iustin Pop | <title>Disk management</title> |
690 | a8083063 | Iustin Pop | |
691 | a8083063 | Iustin Pop | <refsect3> |
692 | a8083063 | Iustin Pop | <title>REPLACE-DISKS</title> |
693 | a8083063 | Iustin Pop | |
694 | a8083063 | Iustin Pop | <cmdsynopsis> |
695 | a8083063 | Iustin Pop | <command>replace-disks</command> |
696 | 0b0dea6a | Iustin Pop | <arg choice="opt">--new-secondary <replaceable>NODE</replaceable></arg> |
697 | 0b0dea6a | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
698 | 0b0dea6a | Iustin Pop | </cmdsynopsis> |
699 | 0b0dea6a | Iustin Pop | |
700 | 0b0dea6a | Iustin Pop | <cmdsynopsis> |
701 | 0b0dea6a | Iustin Pop | <command>replace-disks</command> |
702 | 0b0dea6a | Iustin Pop | <arg choice="req">-s</arg> |
703 | a8083063 | Iustin Pop | <arg choice="req">--new-secondary <replaceable>NODE</replaceable></arg> |
704 | a8083063 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
705 | a8083063 | Iustin Pop | </cmdsynopsis> |
706 | a8083063 | Iustin Pop | |
707 | 0b0dea6a | Iustin Pop | <cmdsynopsis> |
708 | 0b0dea6a | Iustin Pop | <command>replace-disks</command> |
709 | 0b0dea6a | Iustin Pop | <group> |
710 | 0b0dea6a | Iustin Pop | <arg choice="req">-s</arg> |
711 | 0b0dea6a | Iustin Pop | <arg choice="req">-p</arg> |
712 | 0b0dea6a | Iustin Pop | </group> |
713 | 0b0dea6a | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
714 | 0b0dea6a | Iustin Pop | </cmdsynopsis> |
715 | 0b0dea6a | Iustin Pop | |
716 | a8083063 | Iustin Pop | <para> |
717 | 0b0dea6a | Iustin Pop | This command is a generalized form for adding and replacing |
718 | 0b0dea6a | Iustin Pop | disks. |
719 | a8083063 | Iustin Pop | </para> |
720 | a8083063 | Iustin Pop | |
721 | a8083063 | Iustin Pop | <para> |
722 | 0b0dea6a | Iustin Pop | The first form is usable with the |
723 | 0b0dea6a | Iustin Pop | <literal>remote_raid1</literal> disk template. This will |
724 | 0b0dea6a | Iustin Pop | replace the disks on both the primary and secondary node, |
725 | 0b0dea6a | Iustin Pop | and optionally will change the secondary node to a new one |
726 | 0b0dea6a | Iustin Pop | if you pass the <option>--new-secondary</option> option. |
727 | a8083063 | Iustin Pop | </para> |
728 | 0b0dea6a | Iustin Pop | |
729 | 0b0dea6a | Iustin Pop | <para> |
730 | 0b0dea6a | Iustin Pop | The second and third forms are usable with the |
731 | 0b0dea6a | Iustin Pop | <literal>drbd</literal> disk template. The second form will |
732 | 0b0dea6a | Iustin Pop | do a secondary replacement, but as opposed to the |
733 | 0b0dea6a | Iustin Pop | <literal>remote_raid1</literal> will not replace the disks |
734 | 0b0dea6a | Iustin Pop | on the primary, therefore it will execute faster. The third |
735 | 0b0dea6a | Iustin Pop | form will replace the disks on either the primary |
736 | 0b0dea6a | Iustin Pop | (<option>-p</option>) or the secondary (<option>-s</option>) |
737 | 0b0dea6a | Iustin Pop | node of the instance only, without changing the node. |
738 | 0b0dea6a | Iustin Pop | </para> |
739 | 0b0dea6a | Iustin Pop | |
740 | a8083063 | Iustin Pop | </refsect3> |
741 | a8083063 | Iustin Pop | |
742 | a8083063 | Iustin Pop | <refsect3> |
743 | a8083063 | Iustin Pop | <title>ADD-MIRROR</title> |
744 | a8083063 | Iustin Pop | <cmdsynopsis> |
745 | a8083063 | Iustin Pop | <command>add-mirror</command> |
746 | a8083063 | Iustin Pop | <arg choice="req">-b <replaceable>sdX</replaceable></arg> |
747 | a8083063 | Iustin Pop | <arg choice="req">-n <replaceable>node</replaceable></arg> |
748 | a8083063 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
749 | a8083063 | Iustin Pop | </cmdsynopsis> |
750 | a8083063 | Iustin Pop | <para> |
751 | a8083063 | Iustin Pop | Adds a new mirror to the disk layout of the instance, if the |
752 | a8083063 | Iustin Pop | instance has a remote raid disk layout. |
753 | a8083063 | Iustin Pop | |
754 | a8083063 | Iustin Pop | The new mirror member will be between the instance's primary |
755 | a8083063 | Iustin Pop | node and the node given with the <option>-n</option> option. |
756 | a8083063 | Iustin Pop | </para> |
757 | a8083063 | Iustin Pop | </refsect3> |
758 | a8083063 | Iustin Pop | |
759 | a8083063 | Iustin Pop | <refsect3> |
760 | a8083063 | Iustin Pop | <title>REMOVE-MIRROR</title> |
761 | a8083063 | Iustin Pop | |
762 | a8083063 | Iustin Pop | <cmdsynopsis> |
763 | a8083063 | Iustin Pop | <command>removemirror</command> |
764 | a8083063 | Iustin Pop | <arg choice="req">-b <replaceable>sdX</replaceable></arg> |
765 | a8083063 | Iustin Pop | <arg choice="req">-p <replaceable>id</replaceable></arg> |
766 | a8083063 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
767 | a8083063 | Iustin Pop | </cmdsynopsis> |
768 | a8083063 | Iustin Pop | <para> |
769 | a8083063 | Iustin Pop | Removes a mirror componenent from the disk layout of the |
770 | a8083063 | Iustin Pop | instance, if the instance has a remote raid disk layout. |
771 | a8083063 | Iustin Pop | </para> |
772 | a8083063 | Iustin Pop | |
773 | a8083063 | Iustin Pop | <para> |
774 | a8083063 | Iustin Pop | You need to specifiy on which disk to act on using the |
775 | a8083063 | Iustin Pop | <option>-b</option> option (either <filename>sda</filename> |
776 | a8083063 | Iustin Pop | or <filename>sdb</filename>) and the mirror component, which |
777 | a8083063 | Iustin Pop | is identified by the <option>-p</option> option. You can |
778 | a8083063 | Iustin Pop | find the list of valid identifiers with the |
779 | a8083063 | Iustin Pop | <command>info</command> command. |
780 | a8083063 | Iustin Pop | </para> |
781 | a8083063 | Iustin Pop | |
782 | a8083063 | Iustin Pop | <refsect3> |
783 | a8083063 | Iustin Pop | <title>ACTIVATE-DISKS</title> |
784 | a8083063 | Iustin Pop | |
785 | a8083063 | Iustin Pop | <cmdsynopsis> |
786 | a8083063 | Iustin Pop | <command>activate-disks</command> |
787 | a8083063 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
788 | a8083063 | Iustin Pop | </cmdsynopsis> |
789 | a8083063 | Iustin Pop | <para> |
790 | a8083063 | Iustin Pop | Activates the block devices of the given instance. If |
791 | a8083063 | Iustin Pop | successful, the command will show the location and name of |
792 | a8083063 | Iustin Pop | the block devices: |
793 | a8083063 | Iustin Pop | <screen> |
794 | a8083063 | Iustin Pop | node1.example.com:sda:/dev/md0 |
795 | a8083063 | Iustin Pop | node1.example.com:sdb:/dev/md1 |
796 | a8083063 | Iustin Pop | </screen> |
797 | a8083063 | Iustin Pop | |
798 | a8083063 | Iustin Pop | In this example, <emphasis>node1.example.com</emphasis> is |
799 | a8083063 | Iustin Pop | the name of the node on which the devices have been |
800 | a8083063 | Iustin Pop | activated. The <emphasis>sda</emphasis> and |
801 | a8083063 | Iustin Pop | <emphasis>sdb</emphasis> are the names of the block devices |
802 | a8083063 | Iustin Pop | inside the instance. <emphasis>/dev/md0</emphasis> and |
803 | a8083063 | Iustin Pop | <emphasis>/dev/md1</emphasis> are the names of the block |
804 | a8083063 | Iustin Pop | devices as visible on the node. |
805 | a8083063 | Iustin Pop | </para> |
806 | a8083063 | Iustin Pop | |
807 | a8083063 | Iustin Pop | <para> |
808 | a8083063 | Iustin Pop | Note that it is safe to run this command while the instance |
809 | a8083063 | Iustin Pop | is already running. |
810 | a8083063 | Iustin Pop | </para> |
811 | a8083063 | Iustin Pop | </refsect3> |
812 | a8083063 | Iustin Pop | |
813 | a8083063 | Iustin Pop | <refsect3> |
814 | a8083063 | Iustin Pop | <title>DEACTIVATE-DISKS</title> |
815 | a8083063 | Iustin Pop | |
816 | a8083063 | Iustin Pop | <cmdsynopsis> |
817 | a8083063 | Iustin Pop | <command>deactivate-disks</command> |
818 | a8083063 | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
819 | a8083063 | Iustin Pop | </cmdsynopsis> |
820 | a8083063 | Iustin Pop | <para> |
821 | a8083063 | Iustin Pop | De-activates the block devices of the given instance. Note |
822 | a8083063 | Iustin Pop | that if you run this command for a remote raid instance |
823 | a8083063 | Iustin Pop | type, while it is running, it will not be able to shutdown |
824 | a8083063 | Iustin Pop | the block devices on the primary node, but it will shutdown |
825 | a8083063 | Iustin Pop | the block devices on the secondary nodes, thus breaking the |
826 | a8083063 | Iustin Pop | replication. |
827 | a8083063 | Iustin Pop | </para> |
828 | a8083063 | Iustin Pop | |
829 | a8083063 | Iustin Pop | </refsect3> |
830 | a8083063 | Iustin Pop | |
831 | a8083063 | Iustin Pop | </refsect2> |
832 | a8083063 | Iustin Pop | |
833 | a8083063 | Iustin Pop | <refsect2> |
834 | a8083063 | Iustin Pop | <title>Recovery</title> |
835 | a8083063 | Iustin Pop | |
836 | a8083063 | Iustin Pop | <refsect3> |
837 | a8083063 | Iustin Pop | <title>FAILOVER</title> |
838 | a8083063 | Iustin Pop | |
839 | a8083063 | Iustin Pop | <cmdsynopsis> |
840 | a8083063 | Iustin Pop | <command>failover</command> |
841 | a8083063 | Iustin Pop | <arg>-f</arg> |
842 | a8083063 | Iustin Pop | <arg>--ignore-consistency</arg> |
843 | 80de0e3f | Iustin Pop | <arg choice="req"><replaceable>instance</replaceable></arg> |
844 | a8083063 | Iustin Pop | </cmdsynopsis> |
845 | a8083063 | Iustin Pop | |
846 | a8083063 | Iustin Pop | <para> |
847 | 80de0e3f | Iustin Pop | Failover will fail the instance over its secondary |
848 | a8083063 | Iustin Pop | node. This works only for instances having a remote raid |
849 | a8083063 | Iustin Pop | disk layout. |
850 | a8083063 | Iustin Pop | </para> |
851 | a8083063 | Iustin Pop | |
852 | a8083063 | Iustin Pop | <para> |
853 | a8083063 | Iustin Pop | Normally the failover will check the consistency of the |
854 | 80de0e3f | Iustin Pop | disks before failing over the instance. If you are trying to |
855 | a8083063 | Iustin Pop | migrate instances off a dead node, this will fail. Use the |
856 | a8083063 | Iustin Pop | <option>--ignore-consistency</option> option for this |
857 | 24a40d57 | Iustin Pop | purpose. Note that this option can be dangerous as errors in |
858 | 24a40d57 | Iustin Pop | shutting down the instance will be ignored, resulting in |
859 | 24a40d57 | Iustin Pop | possibly having the instance running on two machines in |
860 | 24a40d57 | Iustin Pop | parallel (on disconnected DRBD drives). |
861 | a8083063 | Iustin Pop | </para> |
862 | a8083063 | Iustin Pop | |
863 | a8083063 | Iustin Pop | <para> |
864 | a8083063 | Iustin Pop | Example: |
865 | a8083063 | Iustin Pop | <screen> |
866 | a8083063 | Iustin Pop | # gnt-instance failover instance1.example.com |
867 | a8083063 | Iustin Pop | </screen> |
868 | a8083063 | Iustin Pop | </para> |
869 | a8083063 | Iustin Pop | </refsect3> |
870 | a8083063 | Iustin Pop | |
871 | a8083063 | Iustin Pop | </refsect2> |
872 | a8083063 | Iustin Pop | |
873 | cc425644 | Iustin Pop | <refsect2> |
874 | cc425644 | Iustin Pop | <title>TAGS</title> |
875 | cc425644 | Iustin Pop | |
876 | cc425644 | Iustin Pop | <refsect3> |
877 | cc425644 | Iustin Pop | <title>ADD-TAGS</title> |
878 | cc425644 | Iustin Pop | |
879 | cc425644 | Iustin Pop | <cmdsynopsis> |
880 | cc425644 | Iustin Pop | <command>add-tags</command> |
881 | 810c50b7 | Iustin Pop | <arg choice="opt">--from <replaceable>file</replaceable></arg> |
882 | cc425644 | Iustin Pop | <arg choice="req"><replaceable>instancename</replaceable></arg> |
883 | cc425644 | Iustin Pop | <arg choice="req" |
884 | cc425644 | Iustin Pop | rep="repeat"><replaceable>tag</replaceable></arg> |
885 | cc425644 | Iustin Pop | </cmdsynopsis> |
886 | cc425644 | Iustin Pop | |
887 | cc425644 | Iustin Pop | <para> |
888 | cc425644 | Iustin Pop | Add tags to the given instance. If any of the tags contains |
889 | cc425644 | Iustin Pop | invalid characters, the entire operation will abort. |
890 | cc425644 | Iustin Pop | </para> |
891 | 810c50b7 | Iustin Pop | <para> |
892 | 810c50b7 | Iustin Pop | If the <option>--from</option> option is given, the list of |
893 | 810c50b7 | Iustin Pop | tags will be extended with the contents of that file (each |
894 | 810c50b7 | Iustin Pop | line becomes a tag). In this case, there is not need to pass |
895 | 810c50b7 | Iustin Pop | tags on the command line (if you do, both sources will be |
896 | 810c50b7 | Iustin Pop | used). A file name of - will be interpreted as stdin. |
897 | 810c50b7 | Iustin Pop | </para> |
898 | cc425644 | Iustin Pop | </refsect3> |
899 | cc425644 | Iustin Pop | |
900 | cc425644 | Iustin Pop | <refsect3> |
901 | cc425644 | Iustin Pop | <title>LIST-TAGS</title> |
902 | cc425644 | Iustin Pop | |
903 | cc425644 | Iustin Pop | <cmdsynopsis> |
904 | cc425644 | Iustin Pop | <command>list-tags</command> |
905 | cc425644 | Iustin Pop | <arg choice="req"><replaceable>instancename</replaceable></arg> |
906 | cc425644 | Iustin Pop | </cmdsynopsis> |
907 | cc425644 | Iustin Pop | |
908 | cc425644 | Iustin Pop | <para>List the tags of the given instance.</para> |
909 | cc425644 | Iustin Pop | </refsect3> |
910 | cc425644 | Iustin Pop | |
911 | cc425644 | Iustin Pop | <refsect3> |
912 | cc425644 | Iustin Pop | <title>REMOVE-TAGS</title> |
913 | cc425644 | Iustin Pop | <cmdsynopsis> |
914 | cc425644 | Iustin Pop | <command>remove-tags</command> |
915 | 810c50b7 | Iustin Pop | <arg choice="opt">--from <replaceable>file</replaceable></arg> |
916 | cc425644 | Iustin Pop | <arg choice="req"><replaceable>instancename</replaceable></arg> |
917 | cc425644 | Iustin Pop | <arg choice="req" |
918 | cc425644 | Iustin Pop | rep="repeat"><replaceable>tag</replaceable></arg> |
919 | cc425644 | Iustin Pop | </cmdsynopsis> |
920 | cc425644 | Iustin Pop | |
921 | cc425644 | Iustin Pop | <para> |
922 | cc425644 | Iustin Pop | Remove tags from the given instance. If any of the tags are |
923 | cc425644 | Iustin Pop | not existing on the node, the entire operation will abort. |
924 | cc425644 | Iustin Pop | </para> |
925 | 810c50b7 | Iustin Pop | |
926 | 810c50b7 | Iustin Pop | <para> |
927 | 810c50b7 | Iustin Pop | If the <option>--from</option> option is given, the list of |
928 | 810c50b7 | Iustin Pop | tags will be extended with the contents of that file (each |
929 | 810c50b7 | Iustin Pop | line becomes a tag). In this case, there is not need to pass |
930 | 810c50b7 | Iustin Pop | tags on the command line (if you do, both sources will be |
931 | 810c50b7 | Iustin Pop | used). A file name of - will be interpreted as stdin. |
932 | 810c50b7 | Iustin Pop | </para> |
933 | cc425644 | Iustin Pop | </refsect3> |
934 | cc425644 | Iustin Pop | |
935 | cc425644 | Iustin Pop | </refsect2> |
936 | cc425644 | Iustin Pop | |
937 | a8083063 | Iustin Pop | </refsect1> |
938 | a8083063 | Iustin Pop | |
939 | a8083063 | Iustin Pop | &footer; |
940 | a8083063 | Iustin Pop | |
941 | a8083063 | Iustin Pop | </refentry> |
942 | a8083063 | Iustin Pop | |
943 | a8083063 | Iustin Pop | <!-- Keep this comment at the end of the file |
944 | a8083063 | Iustin Pop | Local variables: |
945 | a8083063 | Iustin Pop | mode: sgml |
946 | a8083063 | Iustin Pop | sgml-omittag:t |
947 | a8083063 | Iustin Pop | sgml-shorttag:t |
948 | a8083063 | Iustin Pop | sgml-minimize-attributes:nil |
949 | a8083063 | Iustin Pop | sgml-always-quote-attributes:t |
950 | a8083063 | Iustin Pop | sgml-indent-step:2 |
951 | a8083063 | Iustin Pop | sgml-indent-data:t |
952 | a8083063 | Iustin Pop | sgml-parent-document:nil |
953 | a8083063 | Iustin Pop | sgml-default-dtd-file:nil |
954 | a8083063 | Iustin Pop | sgml-exposed-tags:nil |
955 | a8083063 | Iustin Pop | sgml-local-catalogs:nil |
956 | a8083063 | Iustin Pop | sgml-local-ecat-files:nil |
957 | a8083063 | Iustin Pop | End: |
958 | a8083063 | Iustin Pop | --> |