Statistics
| Branch: | Tag: | Revision:

root / man / gnt-node.sgml @ ae5b1530

History | View | Annotate | Download (33.8 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 e0897adf Michael Hanselmann
  <!ENTITY dhdate      "<date>June 08, 2010</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-node</refentrytitle>">
10 a8083063 Iustin Pop
  <!ENTITY dhpackage   "gnt-node">
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 e7c6e02b Michael Hanselmann
      <year>2008</year>
24 d3b4cf9f Iustin Pop
      <year>2009</year>
25 a8083063 Iustin Pop
      <holder>Google Inc.</holder>
26 a8083063 Iustin Pop
    </copyright>
27 a8083063 Iustin Pop
    &dhdate;
28 a8083063 Iustin Pop
  </refentryinfo>
29 a8083063 Iustin Pop
  <refmeta>
30 a8083063 Iustin Pop
    &dhucpackage;
31 a8083063 Iustin Pop
32 a8083063 Iustin Pop
    &dhsection;
33 e0897adf Michael Hanselmann
    <refmiscinfo>Ganeti 2.2</refmiscinfo>
34 a8083063 Iustin Pop
  </refmeta>
35 a8083063 Iustin Pop
  <refnamediv>
36 a8083063 Iustin Pop
    <refname>&dhpackage;</refname>
37 a8083063 Iustin Pop
38 e0897adf Michael Hanselmann
    <refpurpose>Node administration</refpurpose>
39 a8083063 Iustin Pop
  </refnamediv>
40 a8083063 Iustin Pop
  <refsynopsisdiv>
41 a8083063 Iustin Pop
    <cmdsynopsis>
42 a8083063 Iustin Pop
      <command>&dhpackage; </command>
43 a8083063 Iustin Pop
44 a8083063 Iustin Pop
      <arg choice="req">command</arg>
45 a8083063 Iustin Pop
      <arg>arguments...</arg>
46 a8083063 Iustin Pop
    </cmdsynopsis>
47 a8083063 Iustin Pop
  </refsynopsisdiv>
48 a8083063 Iustin Pop
  <refsect1>
49 a8083063 Iustin Pop
    <title>DESCRIPTION</title>
50 a8083063 Iustin Pop
51 a8083063 Iustin Pop
    <para>
52 a8083063 Iustin Pop
      The <command>&dhpackage;</command> is used for managing the
53 e0897adf Michael Hanselmann
      (physical) nodes in the Ganeti system.
54 a8083063 Iustin Pop
    </para>
55 a8083063 Iustin Pop
56 a8083063 Iustin Pop
  </refsect1>
57 a8083063 Iustin Pop
  <refsect1>
58 a8083063 Iustin Pop
    <title>COMMANDS</title>
59 a8083063 Iustin Pop
60 a8083063 Iustin Pop
    <refsect2>
61 a8083063 Iustin Pop
      <title>ADD</title>
62 a8083063 Iustin Pop
63 a8083063 Iustin Pop
      <cmdsynopsis>
64 a8083063 Iustin Pop
        <command>add</command>
65 e7c6e02b Michael Hanselmann
        <arg>--readd</arg>
66 a8083063 Iustin Pop
        <arg>-s <replaceable>secondary_ip</replaceable></arg>
67 a8083063 Iustin Pop
        <arg choice="req"><replaceable>nodename</replaceable></arg>
68 a8083063 Iustin Pop
      </cmdsynopsis>
69 a8083063 Iustin Pop
70 a8083063 Iustin Pop
      <para>
71 a8083063 Iustin Pop
        Adds the given node to the cluster.
72 a8083063 Iustin Pop
      </para>
73 a8083063 Iustin Pop
74 a8083063 Iustin Pop
      <para>
75 a8083063 Iustin Pop
        This command is used to join a new node to the cluster. You
76 a8083063 Iustin Pop
        will have to provide the password for root of the node to be
77 a8083063 Iustin Pop
        able to add the node in the cluster. The command needs to be
78 e0897adf Michael Hanselmann
        run on the Ganeti master.
79 a8083063 Iustin Pop
      </para>
80 a8083063 Iustin Pop
81 a8083063 Iustin Pop
      <para>
82 a8083063 Iustin Pop
        Note that the command is potentially destructive, as it will
83 a8083063 Iustin Pop
        forcibly join the specified host the cluster, not paying
84 a8083063 Iustin Pop
        attention to its current status (it could be already in a
85 a8083063 Iustin Pop
        cluster, etc.)
86 a8083063 Iustin Pop
      </para>
87 a8083063 Iustin Pop
88 a8083063 Iustin Pop
      <para>
89 a8083063 Iustin Pop
        The <option>-s</option> is used in dual-home clusters and
90 a8083063 Iustin Pop
        specifies the new node's IP in the secondary network. See the
91 a8083063 Iustin Pop
        discussion in <citerefentry>
92 a8083063 Iustin Pop
        <refentrytitle>gnt-cluster</refentrytitle>
93 a8083063 Iustin Pop
        <manvolnum>8</manvolnum> </citerefentry> for more
94 5bbd3f7f Michael Hanselmann
        information.
95 a8083063 Iustin Pop
      </para>
96 a8083063 Iustin Pop
97 a8083063 Iustin Pop
      <para>
98 d3b4cf9f Iustin Pop
        In case you're readding a node after hardware failure, you can
99 d3b4cf9f Iustin Pop
        use the <option>--readd</option> parameter. In this case, you
100 d3b4cf9f Iustin Pop
        don't need to pass the secondary IP again, it will reused from
101 d3b4cf9f Iustin Pop
        the cluster. Also, the <literal>drained</literal> and
102 d3b4cf9f Iustin Pop
        <literal>offline</literal> flags of the node will be cleared
103 d3b4cf9f Iustin Pop
        before re-adding it.
104 e7c6e02b Michael Hanselmann
      </para>
105 e7c6e02b Michael Hanselmann
106 e7c6e02b Michael Hanselmann
      <para>
107 a8083063 Iustin Pop
        Example:
108 a8083063 Iustin Pop
        <screen>
109 a8083063 Iustin Pop
# gnt-node add node5.example.com
110 a8083063 Iustin Pop
# gnt-node add -s 192.168.44.5 node5.example.com
111 a8083063 Iustin Pop
        </screen>
112 a8083063 Iustin Pop
      </para>
113 a8083063 Iustin Pop
    </refsect2>
114 a8083063 Iustin Pop
115 a8083063 Iustin Pop
    <refsect2>
116 cc425644 Iustin Pop
      <title>ADD-TAGS</title>
117 cc425644 Iustin Pop
118 cc425644 Iustin Pop
      <cmdsynopsis>
119 cc425644 Iustin Pop
        <command>add-tags</command>
120 810c50b7 Iustin Pop
        <arg choice="opt">--from <replaceable>file</replaceable></arg>
121 cc425644 Iustin Pop
        <arg choice="req"><replaceable>nodename</replaceable></arg>
122 cc425644 Iustin Pop
        <arg choice="req"
123 cc425644 Iustin Pop
        rep="repeat"><replaceable>tag</replaceable></arg>
124 cc425644 Iustin Pop
      </cmdsynopsis>
125 cc425644 Iustin Pop
126 cc425644 Iustin Pop
      <para>
127 cc425644 Iustin Pop
        Add tags to the given node. If any of the tags contains
128 cc425644 Iustin Pop
        invalid characters, the entire operation will abort.
129 cc425644 Iustin Pop
      </para>
130 810c50b7 Iustin Pop
131 810c50b7 Iustin Pop
      <para>
132 810c50b7 Iustin Pop
        If the <option>--from</option> option is given, the list of
133 810c50b7 Iustin Pop
        tags will be extended with the contents of that file (each
134 810c50b7 Iustin Pop
        line becomes a tag). In this case, there is not need to pass
135 810c50b7 Iustin Pop
        tags on the command line (if you do, both sources will be
136 810c50b7 Iustin Pop
        used). A file name of - will be interpreted as stdin.
137 810c50b7 Iustin Pop
      </para>
138 cc425644 Iustin Pop
    </refsect2>
139 cc425644 Iustin Pop
140 cc425644 Iustin Pop
    <refsect2>
141 a5bc662a Iustin Pop
      <title>EVACUATE</title>
142 a5bc662a Iustin Pop
143 a5bc662a Iustin Pop
      <cmdsynopsis>
144 a5bc662a Iustin Pop
        <command>evacuate</command>
145 a5bc662a Iustin Pop
        <arg>-f</arg>
146 7ea7bcf6 Iustin Pop
        <arg>--early-release</arg>
147 d3b4cf9f Iustin Pop
        <group>
148 d3b4cf9f Iustin Pop
          <arg>--iallocator <replaceable>NAME</replaceable></arg>
149 d3b4cf9f Iustin Pop
          <arg>--new-secondary <replaceable>destination_node</replaceable></arg>
150 d3b4cf9f Iustin Pop
        </group>
151 f8c9fa5c Iustin Pop
        <arg choice="req" rep="repeat"><replaceable>node</replaceable></arg>
152 a5bc662a Iustin Pop
      </cmdsynopsis>
153 a5bc662a Iustin Pop
154 a5bc662a Iustin Pop
      <para>
155 d3b4cf9f Iustin Pop
        This command will move all secondary instances away from the
156 f8c9fa5c Iustin Pop
        given node(s). It works only for instances having a drbd disk
157 d3b4cf9f Iustin Pop
        template.
158 d3b4cf9f Iustin Pop
      </para>
159 d3b4cf9f Iustin Pop
160 d3b4cf9f Iustin Pop
      <para>
161 d3b4cf9f Iustin Pop
        The new location for the instances can be specified in two ways:
162 d3b4cf9f Iustin Pop
        <itemizedlist>
163 d3b4cf9f Iustin Pop
          <listitem>
164 d3b4cf9f Iustin Pop
            <simpara>as a single node for all instances, via the
165 d3b4cf9f Iustin Pop
            <option>--new-secondary</option> option</simpara>
166 d3b4cf9f Iustin Pop
          </listitem>
167 d3b4cf9f Iustin Pop
          <listitem>
168 d3b4cf9f Iustin Pop
            <simpara>or via the <option>--iallocator</option> option,
169 d3b4cf9f Iustin Pop
            giving a script name as parameter, so each instance will
170 d3b4cf9f Iustin Pop
            be in turn placed on the (per the script) optimal
171 d3b4cf9f Iustin Pop
            node</simpara>
172 d3b4cf9f Iustin Pop
          </listitem>
173 d3b4cf9f Iustin Pop
        </itemizedlist>
174 a5bc662a Iustin Pop
      </para>
175 a5bc662a Iustin Pop
176 a5bc662a Iustin Pop
      <para>
177 7ea7bcf6 Iustin Pop
        The <option>--early-release</option> changes the code so that
178 7ea7bcf6 Iustin Pop
        the old storage on node being evacuated is removed early
179 7ea7bcf6 Iustin Pop
        (before the resync is completed) and the internal Ganeti locks
180 7ea7bcf6 Iustin Pop
        are also released for both the current secondary and the new
181 7ea7bcf6 Iustin Pop
        secondary, thus allowing more parallelism in the cluster
182 7ea7bcf6 Iustin Pop
        operation. This should be used only when recovering from a
183 7ea7bcf6 Iustin Pop
        disk failure on the current secondary (thus the old storage is
184 7ea7bcf6 Iustin Pop
        already broken) or when the storage on the primary node is
185 7ea7bcf6 Iustin Pop
        known to be fine (thus we won't need the old storage for
186 7ea7bcf6 Iustin Pop
        potential recovery).
187 7ea7bcf6 Iustin Pop
      </para>
188 7ea7bcf6 Iustin Pop
189 7ea7bcf6 Iustin Pop
      <para>
190 a5bc662a Iustin Pop
        Example:
191 a5bc662a Iustin Pop
        <screen>
192 d3b4cf9f Iustin Pop
          # gnt-node evacuate -I dumb node3.example.com
193 a5bc662a Iustin Pop
        </screen>
194 a5bc662a Iustin Pop
      </para>
195 a5bc662a Iustin Pop
    </refsect2>
196 a5bc662a Iustin Pop
197 a5bc662a Iustin Pop
    <refsect2>
198 c450e9b0 Iustin Pop
      <title>FAILOVER</title>
199 c450e9b0 Iustin Pop
200 c450e9b0 Iustin Pop
      <cmdsynopsis>
201 c450e9b0 Iustin Pop
        <command>failover</command>
202 c450e9b0 Iustin Pop
        <arg>-f</arg>
203 c450e9b0 Iustin Pop
        <arg>--ignore-consistency</arg>
204 c450e9b0 Iustin Pop
        <arg choice="req"><replaceable>node</replaceable></arg>
205 c450e9b0 Iustin Pop
      </cmdsynopsis>
206 c450e9b0 Iustin Pop
207 c450e9b0 Iustin Pop
      <para>
208 c450e9b0 Iustin Pop
        This command will fail over all instances having the given
209 c450e9b0 Iustin Pop
        node as primary to their secondary nodes. This works only for
210 bd028152 Iustin Pop
        instances having a drbd disk template.
211 c450e9b0 Iustin Pop
      </para>
212 c450e9b0 Iustin Pop
213 c450e9b0 Iustin Pop
      <para>
214 c450e9b0 Iustin Pop
        Normally the failover will check the consistency of the disks
215 c450e9b0 Iustin Pop
        before failing over the instance. If you are trying to migrate
216 c450e9b0 Iustin Pop
        instances off a dead node, this will fail. Use the
217 c450e9b0 Iustin Pop
        <option>--ignore-consistency</option> option for this purpose.
218 c450e9b0 Iustin Pop
      </para>
219 c450e9b0 Iustin Pop
220 c450e9b0 Iustin Pop
      <para>
221 c450e9b0 Iustin Pop
        Example:
222 c450e9b0 Iustin Pop
        <screen>
223 c450e9b0 Iustin Pop
          # gnt-node failover node1.example.com
224 c450e9b0 Iustin Pop
        </screen>
225 c450e9b0 Iustin Pop
      </para>
226 c450e9b0 Iustin Pop
    </refsect2>
227 c450e9b0 Iustin Pop
228 c450e9b0 Iustin Pop
    <refsect2>
229 a8083063 Iustin Pop
      <title>INFO</title>
230 a8083063 Iustin Pop
231 a8083063 Iustin Pop
      <cmdsynopsis>
232 a8083063 Iustin Pop
        <command>info</command>
233 a8083063 Iustin Pop
        <arg rep="repeat"><replaceable>node</replaceable></arg>
234 a8083063 Iustin Pop
      </cmdsynopsis>
235 a8083063 Iustin Pop
236 a8083063 Iustin Pop
      <para>
237 a8083063 Iustin Pop
        Show detailed information about the nodes in the cluster. If you
238 a8083063 Iustin Pop
        don't give any arguments, all nodes will be shows, otherwise the
239 a8083063 Iustin Pop
        output will be restricted to the given names.
240 a8083063 Iustin Pop
      </para>
241 a8083063 Iustin Pop
    </refsect2>
242 a8083063 Iustin Pop
243 a8083063 Iustin Pop
    <refsect2>
244 a8083063 Iustin Pop
      <title>LIST</title>
245 a8083063 Iustin Pop
246 a8083063 Iustin Pop
      <cmdsynopsis>
247 a8083063 Iustin Pop
        <command>list</command>
248 d3b4cf9f Iustin Pop
        <arg>--sync</arg>
249 d3b4cf9f Iustin Pop
        <sbr>
250 a8083063 Iustin Pop
        <arg>--no-headers</arg>
251 a8083063 Iustin Pop
        <arg>--separator=<replaceable>SEPARATOR</replaceable></arg>
252 d3b4cf9f Iustin Pop
        <sbr>
253 d3b4cf9f Iustin Pop
        <arg>--units=<replaceable>UNITS</replaceable></arg>
254 48c4dfa8 Iustin Pop
        <arg>-o <replaceable>[+]FIELD,...</replaceable></arg>
255 d3b4cf9f Iustin Pop
        <sbr>
256 31d97b2a Guido Trotter
        <arg>--roman</arg>
257 31d97b2a Guido Trotter
        <sbr>
258 d3b4cf9f Iustin Pop
        <arg rep="repeat">node</arg>
259 a8083063 Iustin Pop
      </cmdsynopsis>
260 a8083063 Iustin Pop
261 a8083063 Iustin Pop
      <para>
262 d3b4cf9f Iustin Pop
        Lists the nodes in the cluster.
263 a8083063 Iustin Pop
      </para>
264 a8083063 Iustin Pop
265 a8083063 Iustin Pop
      <para>
266 a8083063 Iustin Pop
        The <option>--no-headers</option> option will skip the initial
267 a8083063 Iustin Pop
        header line. The <option>--separator</option> option takes an
268 a8083063 Iustin Pop
        argument which denotes what will be used between the output
269 a8083063 Iustin Pop
        fields. Both these options are to help scripting.
270 a8083063 Iustin Pop
      </para>
271 a8083063 Iustin Pop
272 a8083063 Iustin Pop
      <para>
273 d3b4cf9f Iustin Pop
        The units used to display the numeric values in the output
274 d3b4cf9f Iustin Pop
        varies, depending on the options given. By default, the values
275 d3b4cf9f Iustin Pop
        will be formatted in the most appropriate unit. If the
276 d3b4cf9f Iustin Pop
        <option>--separator</option> option is given, then the values
277 d3b4cf9f Iustin Pop
        are shown in mebibytes to allow parsing by scripts. In both
278 d3b4cf9f Iustin Pop
        cases, the <option>--units</option> option can be used to
279 d3b4cf9f Iustin Pop
        enforce a given output unit.
280 d3b4cf9f Iustin Pop
      </para>
281 d3b4cf9f Iustin Pop
282 d3b4cf9f Iustin Pop
      <para>
283 d3b4cf9f Iustin Pop
        By default, the query of nodes will be done in parallel with
284 d3b4cf9f Iustin Pop
        any running jobs. This might give inconsistent results for the
285 d3b4cf9f Iustin Pop
        free disk/memory. The <option>--sync</option> can be used to
286 d3b4cf9f Iustin Pop
        grab locks for all the nodes and ensure consistent view of the
287 d3b4cf9f Iustin Pop
        cluster (but this might stall the query for a long time).
288 d3b4cf9f Iustin Pop
      </para>
289 d3b4cf9f Iustin Pop
290 d3b4cf9f Iustin Pop
      <para>
291 31d97b2a Guido Trotter
        Passing the <option>--roman</option> option gnt-node list will try to
292 31d97b2a Guido Trotter
        output some of its fields in a latin-friendly way. This is not the
293 31d97b2a Guido Trotter
        default for backwards compatibility.
294 31d97b2a Guido Trotter
      </para>
295 31d97b2a Guido Trotter
296 31d97b2a Guido Trotter
      <para>
297 a8083063 Iustin Pop
        The <option>-o</option> option takes a comma-separated list of
298 a8083063 Iustin Pop
        output fields. The available fields and their meaning are:
299 a8083063 Iustin Pop
        <variablelist>
300 a8083063 Iustin Pop
          <varlistentry>
301 a8083063 Iustin Pop
            <term>name</term>
302 a8083063 Iustin Pop
            <listitem>
303 a8083063 Iustin Pop
              <simpara>the node name</simpara>
304 a8083063 Iustin Pop
            </listitem>
305 a8083063 Iustin Pop
          </varlistentry>
306 a8083063 Iustin Pop
          <varlistentry>
307 d8a4b51d Iustin Pop
            <term>pinst_cnt</term>
308 a8083063 Iustin Pop
            <listitem>
309 a8083063 Iustin Pop
              <simpara>the number of instances having this node as
310 a8083063 Iustin Pop
              primary</simpara>
311 a8083063 Iustin Pop
            </listitem>
312 a8083063 Iustin Pop
          </varlistentry>
313 a8083063 Iustin Pop
          <varlistentry>
314 d8a4b51d Iustin Pop
            <term>pinst_list</term>
315 d8a4b51d Iustin Pop
            <listitem>
316 d8a4b51d Iustin Pop
              <simpara>the list of instances having this node as
317 d8a4b51d Iustin Pop
              primary, comma separated</simpara>
318 d8a4b51d Iustin Pop
            </listitem>
319 d8a4b51d Iustin Pop
          </varlistentry>
320 d8a4b51d Iustin Pop
          <varlistentry>
321 d8a4b51d Iustin Pop
            <term>sinst_cnt</term>
322 a8083063 Iustin Pop
            <listitem>
323 a8083063 Iustin Pop
              <simpara>the number of instances having this node as a
324 a8083063 Iustin Pop
              secondary node</simpara>
325 a8083063 Iustin Pop
            </listitem>
326 a8083063 Iustin Pop
          </varlistentry>
327 a8083063 Iustin Pop
          <varlistentry>
328 d8a4b51d Iustin Pop
            <term>sinst_list</term>
329 d8a4b51d Iustin Pop
            <listitem>
330 d8a4b51d Iustin Pop
              <simpara>the list of instances having this node as a
331 d8a4b51d Iustin Pop
              secondary node, comma separated</simpara>
332 d8a4b51d Iustin Pop
            </listitem>
333 d8a4b51d Iustin Pop
          </varlistentry>
334 d8a4b51d Iustin Pop
          <varlistentry>
335 a8083063 Iustin Pop
            <term>pip</term>
336 a8083063 Iustin Pop
            <listitem>
337 a8083063 Iustin Pop
              <simpara>the primary ip of this node (used for cluster
338 a8083063 Iustin Pop
              communication)</simpara>
339 a8083063 Iustin Pop
            </listitem>
340 a8083063 Iustin Pop
          </varlistentry>
341 a8083063 Iustin Pop
          <varlistentry>
342 a8083063 Iustin Pop
            <term>sip</term>
343 a8083063 Iustin Pop
            <listitem>
344 a8083063 Iustin Pop
              <simpara>
345 a8083063 Iustin Pop
                the secondary ip of this node (used for data
346 a8083063 Iustin Pop
                replication in dual-ip clusters, see <citerefentry>
347 a8083063 Iustin Pop
                <refentrytitle>gnt-cluster</refentrytitle>
348 a8083063 Iustin Pop
                <manvolnum>8</manvolnum>
349 a8083063 Iustin Pop
                </citerefentry>
350 a8083063 Iustin Pop
              </simpara>
351 a8083063 Iustin Pop
            </listitem>
352 a8083063 Iustin Pop
          </varlistentry>
353 a8083063 Iustin Pop
          <varlistentry>
354 a8083063 Iustin Pop
            <term>dtotal</term>
355 a8083063 Iustin Pop
            <listitem>
356 a8083063 Iustin Pop
              <simpara>total disk space in the volume group used for
357 a8083063 Iustin Pop
              instance disk allocations</simpara>
358 a8083063 Iustin Pop
            </listitem>
359 a8083063 Iustin Pop
          </varlistentry>
360 a8083063 Iustin Pop
          <varlistentry>
361 a8083063 Iustin Pop
            <term>dfree</term>
362 a8083063 Iustin Pop
            <listitem>
363 a8083063 Iustin Pop
              <simpara>available disk space in the volume group</simpara>
364 a8083063 Iustin Pop
            </listitem>
365 a8083063 Iustin Pop
          </varlistentry>
366 a8083063 Iustin Pop
          <varlistentry>
367 a8083063 Iustin Pop
            <term>mtotal</term>
368 a8083063 Iustin Pop
            <listitem>
369 a8083063 Iustin Pop
              <simpara>total memory on the physical node</simpara>
370 a8083063 Iustin Pop
            </listitem>
371 a8083063 Iustin Pop
          </varlistentry>
372 a8083063 Iustin Pop
          <varlistentry>
373 a8083063 Iustin Pop
            <term>mnode</term>
374 a8083063 Iustin Pop
            <listitem>
375 a8083063 Iustin Pop
              <simpara>the memory used by the node itself</simpara>
376 a8083063 Iustin Pop
            </listitem>
377 a8083063 Iustin Pop
          </varlistentry>
378 a8083063 Iustin Pop
          <varlistentry>
379 a8083063 Iustin Pop
            <term>mfree</term>
380 a8083063 Iustin Pop
            <listitem>
381 a8083063 Iustin Pop
              <simpara>memory available for instance
382 a8083063 Iustin Pop
              allocations</simpara>
383 a8083063 Iustin Pop
            </listitem>
384 a8083063 Iustin Pop
          </varlistentry>
385 d8a4b51d Iustin Pop
          <varlistentry>
386 d8a4b51d Iustin Pop
            <term>bootid</term>
387 d8a4b51d Iustin Pop
            <listitem>
388 d8a4b51d Iustin Pop
              <simpara>the node bootid value; this is a linux specific
389 d8a4b51d Iustin Pop
              feature that assigns a new UUID to the node at each boot
390 d8a4b51d Iustin Pop
              and can be use to detect node reboots (by tracking
391 d8a4b51d Iustin Pop
              changes in this value)</simpara>
392 d8a4b51d Iustin Pop
            </listitem>
393 d8a4b51d Iustin Pop
          </varlistentry>
394 130a6a6f Iustin Pop
          <varlistentry>
395 130a6a6f Iustin Pop
            <term>tags</term>
396 130a6a6f Iustin Pop
            <listitem>
397 130a6a6f Iustin Pop
              <simpara>comma-separated list of the node's
398 130a6a6f Iustin Pop
              tags</simpara>
399 130a6a6f Iustin Pop
            </listitem>
400 130a6a6f Iustin Pop
          </varlistentry>
401 38d7239a Iustin Pop
          <varlistentry>
402 38d7239a Iustin Pop
            <term>serial_no</term>
403 38d7239a Iustin Pop
            <listitem>
404 90f72445 Iustin Pop
              <simpara>the so called 'serial number' of the node;
405 38d7239a Iustin Pop
              this is a numeric field that is incremented each time
406 90f72445 Iustin Pop
              the node is modified, and it can be used to detect
407 38d7239a Iustin Pop
              modifications</simpara>
408 38d7239a Iustin Pop
            </listitem>
409 38d7239a Iustin Pop
          </varlistentry>
410 d3b4cf9f Iustin Pop
          <varlistentry>
411 90f72445 Iustin Pop
            <term>ctime</term>
412 90f72445 Iustin Pop
            <listitem>
413 90f72445 Iustin Pop
              <para>
414 90f72445 Iustin Pop
                the creation time of the node; note that this field
415 90f72445 Iustin Pop
                contains spaces and as such it's harder to parse
416 90f72445 Iustin Pop
              </para>
417 90f72445 Iustin Pop
              <para>
418 90f72445 Iustin Pop
                if this attribute is not present (e.g. when upgrading
419 90f72445 Iustin Pop
                from older versions), then "N/A" will be shown instead
420 90f72445 Iustin Pop
              </para>
421 90f72445 Iustin Pop
            </listitem>
422 90f72445 Iustin Pop
          </varlistentry>
423 90f72445 Iustin Pop
          <varlistentry>
424 90f72445 Iustin Pop
            <term>mtime</term>
425 90f72445 Iustin Pop
            <listitem>
426 90f72445 Iustin Pop
              <para>
427 90f72445 Iustin Pop
                the last modification time of the node; note that this
428 90f72445 Iustin Pop
                field contains spaces and as such it's harder to parse
429 90f72445 Iustin Pop
              </para>
430 90f72445 Iustin Pop
              <para>
431 90f72445 Iustin Pop
                if this attribute is not present (e.g. when upgrading
432 90f72445 Iustin Pop
                from older versions), then "N/A" will be shown instead
433 90f72445 Iustin Pop
              </para>
434 90f72445 Iustin Pop
            </listitem>
435 90f72445 Iustin Pop
          </varlistentry>
436 90f72445 Iustin Pop
          <varlistentry>
437 edc8fc5f Iustin Pop
            <term>uuid</term>
438 edc8fc5f Iustin Pop
            <listitem>
439 edc8fc5f Iustin Pop
              <simpara>Show the UUID of the node (generated
440 edc8fc5f Iustin Pop
                automatically by Ganeti)</simpara>
441 edc8fc5f Iustin Pop
            </listitem>
442 edc8fc5f Iustin Pop
          </varlistentry>
443 edc8fc5f Iustin Pop
444 edc8fc5f Iustin Pop
          <varlistentry>
445 d3b4cf9f Iustin Pop
            <term>ctotal</term>
446 d3b4cf9f Iustin Pop
            <listitem>
447 d3b4cf9f Iustin Pop
              <simpara>the toal number of logical processors</simpara>
448 d3b4cf9f Iustin Pop
            </listitem>
449 d3b4cf9f Iustin Pop
          </varlistentry>
450 d3b4cf9f Iustin Pop
          <varlistentry>
451 d3b4cf9f Iustin Pop
            <term>cnodes</term>
452 d3b4cf9f Iustin Pop
            <listitem>
453 d3b4cf9f Iustin Pop
              <simpara>the number of NUMA domains on the node, if the
454 d3b4cf9f Iustin Pop
              hypervisor can export this information</simpara>
455 d3b4cf9f Iustin Pop
            </listitem>
456 d3b4cf9f Iustin Pop
          </varlistentry>
457 d3b4cf9f Iustin Pop
          <varlistentry>
458 d3b4cf9f Iustin Pop
            <term>csockets</term>
459 d3b4cf9f Iustin Pop
            <listitem>
460 d3b4cf9f Iustin Pop
              <simpara>the number of physical CPU sockets, if the
461 d3b4cf9f Iustin Pop
              hypervisor can export this information</simpara>
462 d3b4cf9f Iustin Pop
            </listitem>
463 d3b4cf9f Iustin Pop
          </varlistentry>
464 d3b4cf9f Iustin Pop
          <varlistentry>
465 d3b4cf9f Iustin Pop
            <term>master_candidate</term>
466 d3b4cf9f Iustin Pop
            <listitem>
467 d3b4cf9f Iustin Pop
              <simpara>whether the node is a master candidate or not</simpara>
468 d3b4cf9f Iustin Pop
            </listitem>
469 d3b4cf9f Iustin Pop
          </varlistentry>
470 d3b4cf9f Iustin Pop
          <varlistentry>
471 d3b4cf9f Iustin Pop
            <term>drained</term>
472 d3b4cf9f Iustin Pop
            <listitem>
473 253ba78f Raiford Storey
              <simpara>whether the node is drained or not; the cluster
474 253ba78f Raiford Storey
              still communicates with drained nodes but excludes them
475 253ba78f Raiford Storey
              from allocation operations</simpara>
476 d3b4cf9f Iustin Pop
            </listitem>
477 d3b4cf9f Iustin Pop
          </varlistentry>
478 d3b4cf9f Iustin Pop
          <varlistentry>
479 d3b4cf9f Iustin Pop
            <term>offline</term>
480 d3b4cf9f Iustin Pop
            <listitem>
481 253ba78f Raiford Storey
              <simpara>whether the node is offline or not; if offline,
482 253ba78f Raiford Storey
              the cluster does not communicate with offline nodes;
483 253ba78f Raiford Storey
              useful for nodes that are not reachable in order to
484 253ba78f Raiford Storey
              avoid delays</simpara>
485 d3b4cf9f Iustin Pop
            </listitem>
486 d3b4cf9f Iustin Pop
          </varlistentry>
487 c120ff34 Iustin Pop
          <varlistentry>
488 c120ff34 Iustin Pop
            <term>role</term>
489 c120ff34 Iustin Pop
            <listitem>
490 c120ff34 Iustin Pop
              <para>
491 c120ff34 Iustin Pop
                A condensed version of the node flags; this field will
492 c120ff34 Iustin Pop
                output a one-character field, with the following
493 c120ff34 Iustin Pop
                possible values:
494 c120ff34 Iustin Pop
                <itemizedlist>
495 c120ff34 Iustin Pop
                  <listitem>
496 c120ff34 Iustin Pop
                    <simpara><emphasis>M</emphasis> for the master
497 c120ff34 Iustin Pop
                    node</simpara>
498 c120ff34 Iustin Pop
                  </listitem>
499 c120ff34 Iustin Pop
                  <listitem>
500 c120ff34 Iustin Pop
                    <simpara><emphasis>C</emphasis> for a master
501 c120ff34 Iustin Pop
                    candidate</simpara>
502 c120ff34 Iustin Pop
                  </listitem>
503 c120ff34 Iustin Pop
                  <listitem>
504 c120ff34 Iustin Pop
                    <simpara><emphasis>R</emphasis> for a regular
505 c120ff34 Iustin Pop
                    node</simpara>
506 c120ff34 Iustin Pop
                  </listitem>
507 c120ff34 Iustin Pop
                  <listitem>
508 c120ff34 Iustin Pop
                    <simpara><emphasis>D</emphasis> for a drained
509 c120ff34 Iustin Pop
                    node</simpara>
510 c120ff34 Iustin Pop
                  </listitem>
511 c120ff34 Iustin Pop
                  <listitem>
512 c120ff34 Iustin Pop
                    <simpara><emphasis>O</emphasis> for an offline
513 c120ff34 Iustin Pop
                    node</simpara>
514 c120ff34 Iustin Pop
                  </listitem>
515 c120ff34 Iustin Pop
                </itemizedlist>
516 c120ff34 Iustin Pop
              </para>
517 c120ff34 Iustin Pop
            </listitem>
518 c120ff34 Iustin Pop
          </varlistentry>
519 a8083063 Iustin Pop
        </variablelist>
520 a8083063 Iustin Pop
      </para>
521 a8083063 Iustin Pop
522 a8083063 Iustin Pop
      <para>
523 48c4dfa8 Iustin Pop
        If the value of the option starts with the character
524 48c4dfa8 Iustin Pop
        <constant>+</constant>, the new fields will be added to the
525 48c4dfa8 Iustin Pop
        default list. This allows to quickly see the default list plus
526 48c4dfa8 Iustin Pop
        a few other fields, instead of retyping the entire list of
527 48c4dfa8 Iustin Pop
        fields.
528 48c4dfa8 Iustin Pop
      </para>
529 48c4dfa8 Iustin Pop
530 48c4dfa8 Iustin Pop
      <para>
531 a8083063 Iustin Pop
        Note that some of this fields are known from the configuration
532 d3b4cf9f Iustin Pop
        of the cluster (e.g. <simplelist type="inline">
533 a8083063 Iustin Pop
        <member>name</member> <member>pinst</member>
534 a8083063 Iustin Pop
        <member>sinst</member> <member>pip</member>
535 a8083063 Iustin Pop
        <member>sip</member> </simplelist> and thus the master does
536 a8083063 Iustin Pop
        not need to contact the node for this data (making the listing
537 a8083063 Iustin Pop
        fast if only fields from this set are selected), whereas the
538 a8083063 Iustin Pop
        other fields are "live" fields and we need to make a query to
539 a8083063 Iustin Pop
        the cluster nodes.
540 a8083063 Iustin Pop
      </para>
541 a8083063 Iustin Pop
542 a8083063 Iustin Pop
      <para>
543 a8083063 Iustin Pop
        Depending on the virtualization type and implementation
544 a8083063 Iustin Pop
        details, the mtotal, mnode and mfree may have slighly varying
545 a8083063 Iustin Pop
        meanings. For example, some solutions share the node memory
546 a8083063 Iustin Pop
        with the pool of memory used for instances
547 d3b4cf9f Iustin Pop
        (<acronym>KVM</acronym>), whereas others have separate memory
548 a8083063 Iustin Pop
        for the node and for the instances (Xen).
549 a8083063 Iustin Pop
      </para>
550 d3b4cf9f Iustin Pop
551 d3b4cf9f Iustin Pop
      <para>
552 d3b4cf9f Iustin Pop
        If no node names are given, then all nodes are
553 d3b4cf9f Iustin Pop
        queried. Otherwise, only the given nodes will be listed.
554 d3b4cf9f Iustin Pop
      </para>
555 a8083063 Iustin Pop
    </refsect2>
556 a8083063 Iustin Pop
557 a8083063 Iustin Pop
    <refsect2>
558 cc425644 Iustin Pop
      <title>LIST-TAGS</title>
559 cc425644 Iustin Pop
560 cc425644 Iustin Pop
      <cmdsynopsis>
561 cc425644 Iustin Pop
        <command>list-tags</command>
562 cc425644 Iustin Pop
        <arg choice="req"><replaceable>nodename</replaceable></arg>
563 cc425644 Iustin Pop
      </cmdsynopsis>
564 cc425644 Iustin Pop
565 cc425644 Iustin Pop
      <para>List the tags of the given node.</para>
566 cc425644 Iustin Pop
    </refsect2>
567 cc425644 Iustin Pop
568 cc425644 Iustin Pop
    <refsect2>
569 d3b4cf9f Iustin Pop
      <title>MIGRATE</title>
570 d3b4cf9f Iustin Pop
      <cmdsynopsis>
571 d3b4cf9f Iustin Pop
        <command>migrate</command>
572 d3b4cf9f Iustin Pop
        <arg>-f</arg>
573 d3b4cf9f Iustin Pop
        <arg>--non-live</arg>
574 d3b4cf9f Iustin Pop
        <arg choice="req"><replaceable>node</replaceable></arg>
575 d3b4cf9f Iustin Pop
      </cmdsynopsis>
576 d3b4cf9f Iustin Pop
577 d3b4cf9f Iustin Pop
      <para>
578 d3b4cf9f Iustin Pop
        This command will migrate all instances having the given
579 d3b4cf9f Iustin Pop
        node as primary to their secondary nodes. This works only for
580 d3b4cf9f Iustin Pop
        instances having a drbd disk template.
581 d3b4cf9f Iustin Pop
      </para>
582 d3b4cf9f Iustin Pop
583 d3b4cf9f Iustin Pop
      <para>
584 d3b4cf9f Iustin Pop
        As for the <command>gnt-instance migrate</command> command,
585 d3b4cf9f Iustin Pop
        the <option>--no-live</option> option can be given to do a
586 d3b4cf9f Iustin Pop
        non-live migration.
587 d3b4cf9f Iustin Pop
      </para>
588 d3b4cf9f Iustin Pop
589 d3b4cf9f Iustin Pop
      <para>
590 d3b4cf9f Iustin Pop
        Example:
591 d3b4cf9f Iustin Pop
        <screen>
592 d3b4cf9f Iustin Pop
          # gnt-node migrate node1.example.com
593 d3b4cf9f Iustin Pop
        </screen>
594 d3b4cf9f Iustin Pop
      </para>
595 d3b4cf9f Iustin Pop
596 d3b4cf9f Iustin Pop
    </refsect2>
597 d3b4cf9f Iustin Pop
598 d3b4cf9f Iustin Pop
    <refsect2>
599 949bdabe Iustin Pop
      <title>MODIFY</title>
600 949bdabe Iustin Pop
      <cmdsynopsis>
601 949bdabe Iustin Pop
        <command>modify</command>
602 949bdabe Iustin Pop
        <arg>-f</arg>
603 949bdabe Iustin Pop
        <arg>--submit</arg>
604 949bdabe Iustin Pop
        <arg>--master-candidate=<option>yes|no</option></arg>
605 949bdabe Iustin Pop
        <arg>--drained=<option>yes|no</option></arg>
606 949bdabe Iustin Pop
        <arg>--offline=<option>yes|no</option></arg>
607 4c61d894 Iustin Pop
        <arg>--auto-promote</arg>
608 949bdabe Iustin Pop
        <arg choice="req"><replaceable>node</replaceable></arg>
609 949bdabe Iustin Pop
      </cmdsynopsis>
610 949bdabe Iustin Pop
611 949bdabe Iustin Pop
      <para>
612 949bdabe Iustin Pop
        This command changes the role of the node. Each options takes
613 949bdabe Iustin Pop
        either a literal <literal>yes</literal> or
614 949bdabe Iustin Pop
        <literal>no</literal>, and only one option should be given as
615 949bdabe Iustin Pop
        <literal>yes</literal>. The meaning of the roles are described
616 949bdabe Iustin Pop
        in the manpage <citerefentry>
617 949bdabe Iustin Pop
        <refentrytitle>ganeti</refentrytitle> <manvolnum>7</manvolnum>
618 949bdabe Iustin Pop
        </citerefentry>.
619 949bdabe Iustin Pop
      </para>
620 949bdabe Iustin Pop
621 949bdabe Iustin Pop
      <para>
622 4c61d894 Iustin Pop
        In case a node is demoted from the master candidate role, the
623 4c61d894 Iustin Pop
        operation will be refused unless you pass
624 4c61d894 Iustin Pop
        the <option>--auto-promote</option> option. This option will
625 4c61d894 Iustin Pop
        cause the operation to lock all cluster nodes (thus it will
626 4c61d894 Iustin Pop
        not be able to run in parallel with most other jobs), but it
627 4c61d894 Iustin Pop
        allows automated maintenance of the cluster candidate pool. If
628 4c61d894 Iustin Pop
        locking all cluster node is too expensive, another option is
629 4c61d894 Iustin Pop
        to promote manually another node to master candidate before
630 4c61d894 Iustin Pop
        demoting the current one.
631 949bdabe Iustin Pop
      </para>
632 949bdabe Iustin Pop
633 949bdabe Iustin Pop
      <para>
634 949bdabe Iustin Pop
        Example (setting a node offline, which will demote it from
635 949bdabe Iustin Pop
        master candidate role if is in that role):
636 949bdabe Iustin Pop
        <screen>
637 949bdabe Iustin Pop
# gnt-node modify --offline=yes node1.example.com
638 949bdabe Iustin Pop
        </screen>
639 949bdabe Iustin Pop
      </para>
640 949bdabe Iustin Pop
641 949bdabe Iustin Pop
      <para>Example (setting the node back to online and master candidate):
642 949bdabe Iustin Pop
        <screen>
643 949bdabe Iustin Pop
# gnt-node modify --offline=no --master-candidate=yes node1.example.com
644 949bdabe Iustin Pop
        </screen>
645 949bdabe Iustin Pop
      </para>
646 949bdabe Iustin Pop
647 949bdabe Iustin Pop
    </refsect2>
648 949bdabe Iustin Pop
649 949bdabe Iustin Pop
    <refsect2>
650 a8083063 Iustin Pop
      <title>REMOVE</title>
651 a8083063 Iustin Pop
652 a8083063 Iustin Pop
      <cmdsynopsis>
653 a8083063 Iustin Pop
        <command>remove</command>
654 a8083063 Iustin Pop
        <arg choice="req"><replaceable>nodename</replaceable></arg>
655 a8083063 Iustin Pop
      </cmdsynopsis>
656 a8083063 Iustin Pop
657 a8083063 Iustin Pop
      <para>
658 a8083063 Iustin Pop
        Removes a node from the cluster. Instances must be removed or
659 a8083063 Iustin Pop
        migrated to another cluster before.
660 a8083063 Iustin Pop
      </para>
661 a8083063 Iustin Pop
662 a8083063 Iustin Pop
      <para>
663 a8083063 Iustin Pop
        Example:
664 a8083063 Iustin Pop
        <screen>
665 a8083063 Iustin Pop
# gnt-node remove node5.example.com
666 a8083063 Iustin Pop
        </screen>
667 a8083063 Iustin Pop
      </para>
668 a8083063 Iustin Pop
    </refsect2>
669 a8083063 Iustin Pop
670 dcb93971 Michael Hanselmann
    <refsect2>
671 cc425644 Iustin Pop
      <title>REMOVE-TAGS</title>
672 cc425644 Iustin Pop
      <cmdsynopsis>
673 cc425644 Iustin Pop
        <command>remove-tags</command>
674 810c50b7 Iustin Pop
        <arg choice="opt">--from <replaceable>file</replaceable></arg>
675 cc425644 Iustin Pop
        <arg choice="req"><replaceable>nodename</replaceable></arg>
676 cc425644 Iustin Pop
        <arg choice="req"
677 cc425644 Iustin Pop
        rep="repeat"><replaceable>tag</replaceable></arg>
678 cc425644 Iustin Pop
      </cmdsynopsis>
679 cc425644 Iustin Pop
680 cc425644 Iustin Pop
      <para>
681 cc425644 Iustin Pop
        Remove tags from the given node. If any of the tags are not
682 cc425644 Iustin Pop
        existing on the node, the entire operation will abort.
683 cc425644 Iustin Pop
      </para>
684 810c50b7 Iustin Pop
685 810c50b7 Iustin Pop
      <para>
686 810c50b7 Iustin Pop
        If the <option>--from</option> option is given, the list of
687 810c50b7 Iustin Pop
        tags will be extended with the contents of that file (each
688 810c50b7 Iustin Pop
        line becomes a tag). In this case, there is not need to pass
689 810c50b7 Iustin Pop
        tags on the command line (if you do, both sources will be
690 810c50b7 Iustin Pop
        used). A file name of - will be interpreted as stdin.
691 810c50b7 Iustin Pop
      </para>
692 cc425644 Iustin Pop
    </refsect2>
693 cc425644 Iustin Pop
694 cc425644 Iustin Pop
    <refsect2>
695 dcb93971 Michael Hanselmann
      <title>VOLUMES</title>
696 dcb93971 Michael Hanselmann
697 dcb93971 Michael Hanselmann
      <cmdsynopsis>
698 dcb93971 Michael Hanselmann
        <command>volumes</command>
699 f69dab6d Iustin Pop
        <arg>--no-headers</arg>
700 f69dab6d Iustin Pop
        <arg>--human-readable</arg>
701 f69dab6d Iustin Pop
        <arg>--separator=<replaceable>SEPARATOR</replaceable></arg>
702 f69dab6d Iustin Pop
        <arg>--output=<replaceable>FIELDS</replaceable></arg>
703 f69dab6d Iustin Pop
        <sbr>
704 dcb93971 Michael Hanselmann
        <arg rep="repeat"><replaceable>node</replaceable></arg>
705 dcb93971 Michael Hanselmann
      </cmdsynopsis>
706 dcb93971 Michael Hanselmann
707 dcb93971 Michael Hanselmann
      <para>
708 dcb93971 Michael Hanselmann
        Lists all logical volumes and their physical disks from the node(s)
709 dcb93971 Michael Hanselmann
        provided.
710 dcb93971 Michael Hanselmann
      </para>
711 dcb93971 Michael Hanselmann
712 dcb93971 Michael Hanselmann
      <para>
713 f69dab6d Iustin Pop
        The <option>--no-headers</option> option will skip the initial
714 f69dab6d Iustin Pop
        header line. The <option>--separator</option> option takes an
715 f69dab6d Iustin Pop
        argument which denotes what will be used between the output
716 f69dab6d Iustin Pop
        fields. Both these options are to help scripting.
717 f69dab6d Iustin Pop
      </para>
718 f69dab6d Iustin Pop
719 f69dab6d Iustin Pop
      <para>
720 d3b4cf9f Iustin Pop
        The units used to display the numeric values in the output
721 d3b4cf9f Iustin Pop
        varies, depending on the options given. By default, the values
722 d3b4cf9f Iustin Pop
        will be formatted in the most appropriate unit. If the
723 d3b4cf9f Iustin Pop
        <option>--separator</option> option is given, then the values
724 d3b4cf9f Iustin Pop
        are shown in mebibytes to allow parsing by scripts. In both
725 d3b4cf9f Iustin Pop
        cases, the <option>--units</option> option can be used to
726 d3b4cf9f Iustin Pop
        enforce a given output unit.
727 d3b4cf9f Iustin Pop
      </para>
728 d3b4cf9f Iustin Pop
729 d3b4cf9f Iustin Pop
      <para>
730 f69dab6d Iustin Pop
        The <option>-o</option> option takes a comma-separated list of
731 f69dab6d Iustin Pop
        output fields. The available fields and their meaning are:
732 f69dab6d Iustin Pop
        <variablelist>
733 f69dab6d Iustin Pop
          <varlistentry>
734 f69dab6d Iustin Pop
            <term>node</term>
735 f69dab6d Iustin Pop
            <listitem>
736 f69dab6d Iustin Pop
              <simpara>the node name on which the volume exists</simpara>
737 f69dab6d Iustin Pop
            </listitem>
738 f69dab6d Iustin Pop
          </varlistentry>
739 f69dab6d Iustin Pop
          <varlistentry>
740 f69dab6d Iustin Pop
            <term>phys</term>
741 f69dab6d Iustin Pop
            <listitem>
742 f69dab6d Iustin Pop
              <simpara>the physical drive (on which the LVM physical
743 f69dab6d Iustin Pop
              volume lives)</simpara>
744 f69dab6d Iustin Pop
            </listitem>
745 f69dab6d Iustin Pop
          </varlistentry>
746 f69dab6d Iustin Pop
          <varlistentry>
747 f69dab6d Iustin Pop
            <term>vg</term>
748 f69dab6d Iustin Pop
            <listitem>
749 f69dab6d Iustin Pop
              <simpara>the volume group name</simpara>
750 f69dab6d Iustin Pop
            </listitem>
751 f69dab6d Iustin Pop
          </varlistentry>
752 f69dab6d Iustin Pop
          <varlistentry>
753 f69dab6d Iustin Pop
            <term>name</term>
754 f69dab6d Iustin Pop
            <listitem>
755 f69dab6d Iustin Pop
              <simpara>the logical volume name</simpara>
756 f69dab6d Iustin Pop
            </listitem>
757 f69dab6d Iustin Pop
          </varlistentry>
758 f69dab6d Iustin Pop
          <varlistentry>
759 f69dab6d Iustin Pop
            <term>size</term>
760 f69dab6d Iustin Pop
            <listitem>
761 f69dab6d Iustin Pop
              <simpara>the logical volume size</simpara>
762 f69dab6d Iustin Pop
            </listitem>
763 f69dab6d Iustin Pop
          </varlistentry>
764 f69dab6d Iustin Pop
          <varlistentry>
765 f69dab6d Iustin Pop
            <term>instance</term>
766 f69dab6d Iustin Pop
            <listitem>
767 f69dab6d Iustin Pop
              <simpara>The name of the instance to which this volume
768 f69dab6d Iustin Pop
              belongs, or (in case it's an orphan volume) the
769 f69dab6d Iustin Pop
              character <quote>-</quote></simpara>
770 f69dab6d Iustin Pop
            </listitem>
771 f69dab6d Iustin Pop
          </varlistentry>
772 f69dab6d Iustin Pop
        </variablelist>
773 f69dab6d Iustin Pop
      </para>
774 f69dab6d Iustin Pop
775 f69dab6d Iustin Pop
      <para>
776 dcb93971 Michael Hanselmann
        Example:
777 dcb93971 Michael Hanselmann
        <screen>
778 dcb93971 Michael Hanselmann
# gnt-node volumes node5.example.com
779 dcb93971 Michael Hanselmann
Node              PhysDev   VG    Name                                 Size Instance
780 dcb93971 Michael Hanselmann
node1.example.com /dev/hdc1 xenvg instance1.example.com-sda_11000.meta 128  instance1.example.com
781 dcb93971 Michael Hanselmann
node1.example.com /dev/hdc1 xenvg instance1.example.com-sda_11001.data 256  instance1.example.com
782 dcb93971 Michael Hanselmann
        </screen>
783 dcb93971 Michael Hanselmann
      </para>
784 dcb93971 Michael Hanselmann
    </refsect2>
785 dcb93971 Michael Hanselmann
786 f5118ade Iustin Pop
    <refsect2>
787 9b94905f Iustin Pop
      <title>LIST-STORAGE</title>
788 4007f57d Michael Hanselmann
789 4007f57d Michael Hanselmann
      <cmdsynopsis>
790 9b94905f Iustin Pop
        <command>list-storage</command>
791 4007f57d Michael Hanselmann
        <arg>--no-headers</arg>
792 4007f57d Michael Hanselmann
        <arg>--human-readable</arg>
793 4007f57d Michael Hanselmann
        <arg>--separator=<replaceable>SEPARATOR</replaceable></arg>
794 53548798 Michael Hanselmann
        <arg>--storage-type=<replaceable>STORAGE_TYPE</replaceable></arg>
795 4007f57d Michael Hanselmann
        <arg>--output=<replaceable>FIELDS</replaceable></arg>
796 4007f57d Michael Hanselmann
        <sbr>
797 4007f57d Michael Hanselmann
        <arg rep="repeat"><replaceable>node</replaceable></arg>
798 4007f57d Michael Hanselmann
      </cmdsynopsis>
799 4007f57d Michael Hanselmann
800 4007f57d Michael Hanselmann
      <para>
801 9b94905f Iustin Pop
        Lists the available storage units and their details for the
802 9b94905f Iustin Pop
        given node(s).
803 4007f57d Michael Hanselmann
      </para>
804 4007f57d Michael Hanselmann
805 4007f57d Michael Hanselmann
      <para>
806 4007f57d Michael Hanselmann
        The <option>--no-headers</option> option will skip the initial header
807 4007f57d Michael Hanselmann
        line. The <option>--separator</option> option takes an argument which
808 4007f57d Michael Hanselmann
        denotes what will be used between the output fields. Both these options
809 4007f57d Michael Hanselmann
        are to help scripting.
810 4007f57d Michael Hanselmann
      </para>
811 4007f57d Michael Hanselmann
812 4007f57d Michael Hanselmann
      <para>
813 4007f57d Michael Hanselmann
        The units used to display the numeric values in the output varies,
814 4007f57d Michael Hanselmann
        depending on the options given. By default, the values will be
815 4007f57d Michael Hanselmann
        formatted in the most appropriate unit. If the
816 4007f57d Michael Hanselmann
        <option>--separator</option> option is given, then the values are shown
817 4007f57d Michael Hanselmann
        in mebibytes to allow parsing by scripts. In both cases, the
818 4007f57d Michael Hanselmann
        <option>--units</option> option can be used to enforce a given output
819 4007f57d Michael Hanselmann
        unit.
820 4007f57d Michael Hanselmann
      </para>
821 4007f57d Michael Hanselmann
822 4007f57d Michael Hanselmann
      <para>
823 53548798 Michael Hanselmann
        The <option>--storage-type</option> option can be used to choose a
824 53548798 Michael Hanselmann
        storage unit type. Possible choices are <literal>lvm-pv</literal>,
825 620a85fd Iustin Pop
        <literal>lvm-vg</literal> or <literal>file</literal>.
826 53548798 Michael Hanselmann
      </para>
827 53548798 Michael Hanselmann
828 53548798 Michael Hanselmann
      <para>
829 4007f57d Michael Hanselmann
        The <option>-o</option> option takes a comma-separated list of
830 4007f57d Michael Hanselmann
        output fields. The available fields and their meaning are:
831 4007f57d Michael Hanselmann
        <variablelist>
832 4007f57d Michael Hanselmann
          <varlistentry>
833 4007f57d Michael Hanselmann
            <term>node</term>
834 4007f57d Michael Hanselmann
            <listitem>
835 4007f57d Michael Hanselmann
              <simpara>the node name on which the volume exists</simpara>
836 4007f57d Michael Hanselmann
            </listitem>
837 4007f57d Michael Hanselmann
          </varlistentry>
838 4007f57d Michael Hanselmann
          <varlistentry>
839 620a85fd Iustin Pop
            <term>type</term>
840 620a85fd Iustin Pop
            <listitem>
841 620a85fd Iustin Pop
              <simpara>the type of the storage unit (currently just
842 620a85fd Iustin Pop
              what is passed in via
843 620a85fd Iustin Pop
              <option>--storage-type</option>)</simpara>
844 620a85fd Iustin Pop
            </listitem>
845 620a85fd Iustin Pop
          </varlistentry>
846 620a85fd Iustin Pop
          <varlistentry>
847 4007f57d Michael Hanselmann
            <term>name</term>
848 4007f57d Michael Hanselmann
            <listitem>
849 620a85fd Iustin Pop
              <simpara>the path/identifier of the storage unit</simpara>
850 4007f57d Michael Hanselmann
            </listitem>
851 4007f57d Michael Hanselmann
          </varlistentry>
852 4007f57d Michael Hanselmann
          <varlistentry>
853 4007f57d Michael Hanselmann
            <term>size</term>
854 4007f57d Michael Hanselmann
            <listitem>
855 53548798 Michael Hanselmann
              <simpara>
856 620a85fd Iustin Pop
                total size of the unit; for the file type see a note below
857 53548798 Michael Hanselmann
              </simpara>
858 4007f57d Michael Hanselmann
            </listitem>
859 4007f57d Michael Hanselmann
          </varlistentry>
860 4007f57d Michael Hanselmann
          <varlistentry>
861 4007f57d Michael Hanselmann
            <term>used</term>
862 4007f57d Michael Hanselmann
            <listitem>
863 53548798 Michael Hanselmann
              <simpara>
864 620a85fd Iustin Pop
                used space in the unit; for the file type see a note below
865 53548798 Michael Hanselmann
              </simpara>
866 4007f57d Michael Hanselmann
            </listitem>
867 4007f57d Michael Hanselmann
          </varlistentry>
868 4007f57d Michael Hanselmann
          <varlistentry>
869 4007f57d Michael Hanselmann
            <term>free</term>
870 4007f57d Michael Hanselmann
            <listitem>
871 53548798 Michael Hanselmann
              <simpara>
872 53548798 Michael Hanselmann
                available disk space
873 53548798 Michael Hanselmann
              </simpara>
874 4007f57d Michael Hanselmann
            </listitem>
875 4007f57d Michael Hanselmann
          </varlistentry>
876 4007f57d Michael Hanselmann
          <varlistentry>
877 4007f57d Michael Hanselmann
            <term>allocatable</term>
878 4007f57d Michael Hanselmann
            <listitem>
879 53548798 Michael Hanselmann
              <simpara>
880 620a85fd Iustin Pop
                whether we the unit is available for allocation
881 620a85fd Iustin Pop
                (only <literal>lvm-pv</literal> can change this
882 620a85fd Iustin Pop
                setting, the other types always report true)
883 53548798 Michael Hanselmann
              </simpara>
884 4007f57d Michael Hanselmann
            </listitem>
885 4007f57d Michael Hanselmann
          </varlistentry>
886 4007f57d Michael Hanselmann
        </variablelist>
887 4007f57d Michael Hanselmann
      </para>
888 4007f57d Michael Hanselmann
889 4007f57d Michael Hanselmann
      <para>
890 620a85fd Iustin Pop
        Note that for the <quote>file</quote> type, the total disk
891 620a85fd Iustin Pop
        space might not equal to the sum of used and free, due to the
892 620a85fd Iustin Pop
        method Ganeti uses to compute each of them. The total and free
893 620a85fd Iustin Pop
        values are computed as the total and free space values for the
894 620a85fd Iustin Pop
        filesystem to which the directory belongs, but the used space
895 620a85fd Iustin Pop
        is computed from the used space under that directory
896 620a85fd Iustin Pop
        <emphasis>only</emphasis>, which might not be necessarily the
897 620a85fd Iustin Pop
        root of the filesystem, and as such there could be files
898 620a85fd Iustin Pop
        outside the file storage directory using disk space and
899 620a85fd Iustin Pop
        causing a mismatch in the values.
900 620a85fd Iustin Pop
      </para>
901 620a85fd Iustin Pop
902 620a85fd Iustin Pop
      <para>
903 4007f57d Michael Hanselmann
        Example:
904 4007f57d Michael Hanselmann
        <screen>
905 620a85fd Iustin Pop
node1# gnt-node list-storage node2
906 620a85fd Iustin Pop
Node  Type   Name        Size Used   Free Allocatable
907 620a85fd Iustin Pop
node2 lvm-pv /dev/sda7 673.8G 1.5G 672.3G Y
908 620a85fd Iustin Pop
node2 lvm-pv /dev/sdb1 698.6G   0M 698.6G Y
909 4007f57d Michael Hanselmann
        </screen>
910 4007f57d Michael Hanselmann
      </para>
911 4007f57d Michael Hanselmann
    </refsect2>
912 4007f57d Michael Hanselmann
913 4007f57d Michael Hanselmann
    <refsect2>
914 9b94905f Iustin Pop
      <title>MODIFY-STORAGE</title>
915 0e89fc2d Michael Hanselmann
916 0e89fc2d Michael Hanselmann
      <cmdsynopsis>
917 9b94905f Iustin Pop
        <command>modify-storage</command>
918 0e89fc2d Michael Hanselmann
        <arg><option>--allocatable=yes|no</option></arg>
919 0e89fc2d Michael Hanselmann
        <sbr>
920 7e9c6a78 Iustin Pop
        <arg choice="req"><replaceable>node</replaceable></arg>
921 7e9c6a78 Iustin Pop
        <arg choice="req"><replaceable>storage-type</replaceable></arg>
922 7e9c6a78 Iustin Pop
        <arg choice="req"><replaceable>volume-name</replaceable></arg>
923 0e89fc2d Michael Hanselmann
      </cmdsynopsis>
924 0e89fc2d Michael Hanselmann
925 0e89fc2d Michael Hanselmann
      <para>
926 9b94905f Iustin Pop
        Modifies storage volumes on a node. Only LVM physical volumes
927 9b94905f Iustin Pop
        can be modified at the moment. They have a storage type
928 9b94905f Iustin Pop
        of <quote>lvm-pv</quote>.
929 0e89fc2d Michael Hanselmann
      </para>
930 0e89fc2d Michael Hanselmann
931 0e89fc2d Michael Hanselmann
      <para>
932 0e89fc2d Michael Hanselmann
        Example:
933 0e89fc2d Michael Hanselmann
        <screen>
934 9b94905f Iustin Pop
# gnt-node modify-storage --allocatable no node5.example.com lvm-pv /dev/sdb1
935 0e89fc2d Michael Hanselmann
        </screen>
936 0e89fc2d Michael Hanselmann
      </para>
937 0e89fc2d Michael Hanselmann
    </refsect2>
938 0e89fc2d Michael Hanselmann
939 0e89fc2d Michael Hanselmann
    <refsect2>
940 9b94905f Iustin Pop
      <title>REPAIR-STORAGE</title>
941 1e3463f1 Michael Hanselmann
942 1e3463f1 Michael Hanselmann
      <cmdsynopsis>
943 9b94905f Iustin Pop
        <command>repair-storage</command>
944 7e9c6a78 Iustin Pop
        <arg>--ignore-consistency</arg>
945 7e9c6a78 Iustin Pop
        <arg choice="req"><replaceable>node</replaceable></arg>
946 7e9c6a78 Iustin Pop
        <arg choice="req"><replaceable>storage-type</replaceable></arg>
947 7e9c6a78 Iustin Pop
        <arg choice="req"><replaceable>volume-name</replaceable></arg>
948 1e3463f1 Michael Hanselmann
      </cmdsynopsis>
949 1e3463f1 Michael Hanselmann
950 1e3463f1 Michael Hanselmann
      <para>
951 9b94905f Iustin Pop
        Repairs a storage volume on a node. Only LVM volume groups can
952 9b94905f Iustin Pop
        be repaired at this time. They have the storage type
953 1e3463f1 Michael Hanselmann
        <quote>lvm-vg</quote>.
954 1e3463f1 Michael Hanselmann
      </para>
955 1e3463f1 Michael Hanselmann
956 1e3463f1 Michael Hanselmann
      <para>
957 c71a1a3d Iustin Pop
        On LVM volume groups, <command>repair-storage</command> runs
958 1e3463f1 Michael Hanselmann
        <quote>vgreduce --removemissing</quote>.
959 1e3463f1 Michael Hanselmann
      </para>
960 1e3463f1 Michael Hanselmann
961 1e3463f1 Michael Hanselmann
      <caution>
962 1e3463f1 Michael Hanselmann
        <para>
963 1e3463f1 Michael Hanselmann
          Running this command can lead to data loss. Use it with care.
964 1e3463f1 Michael Hanselmann
        </para>
965 1e3463f1 Michael Hanselmann
      </caution>
966 1e3463f1 Michael Hanselmann
967 1e3463f1 Michael Hanselmann
      <para>
968 7e9c6a78 Iustin Pop
        The <option>--ignore-consistency</option> option will ignore
969 7e9c6a78 Iustin Pop
        any inconsistent disks (on the nodes paired with this
970 7e9c6a78 Iustin Pop
        one). Use of this option is most likely to lead to data-loss.
971 7e9c6a78 Iustin Pop
      </para>
972 7e9c6a78 Iustin Pop
973 7e9c6a78 Iustin Pop
      <para>
974 1e3463f1 Michael Hanselmann
        Example:
975 1e3463f1 Michael Hanselmann
        <screen>
976 9b94905f Iustin Pop
# gnt-node repair-storage node5.example.com lvm-vg xenvg
977 1e3463f1 Michael Hanselmann
        </screen>
978 1e3463f1 Michael Hanselmann
      </para>
979 1e3463f1 Michael Hanselmann
    </refsect2>
980 1e3463f1 Michael Hanselmann
981 1e3463f1 Michael Hanselmann
    <refsect2>
982 f5118ade Iustin Pop
      <title>POWERCYCLE</title>
983 f5118ade Iustin Pop
984 f5118ade Iustin Pop
      <cmdsynopsis>
985 f5118ade Iustin Pop
        <command>powercycle</command>
986 f65a637a Luca Bigliardi
        <arg><option>--yes</option></arg>
987 f5118ade Iustin Pop
        <arg><option>--force</option></arg>
988 f5118ade Iustin Pop
        <arg choice="req"><replaceable>node</replaceable></arg>
989 f5118ade Iustin Pop
      </cmdsynopsis>
990 f5118ade Iustin Pop
991 f5118ade Iustin Pop
      <para>
992 f5118ade Iustin Pop
        This commands (tries to) forcefully reboot a node. It is a
993 f5118ade Iustin Pop
        command that can be used if the node environemnt is broken,
994 f5118ade Iustin Pop
        such that the admin can no longer login over ssh, but the
995 e0897adf Michael Hanselmann
        Ganeti node daemon is still working.
996 f5118ade Iustin Pop
      </para>
997 f5118ade Iustin Pop
998 f5118ade Iustin Pop
      <para>
999 f5118ade Iustin Pop
        Note that this command is not guaranteed to work; it depends
1000 f5118ade Iustin Pop
        on the hypervisor how effective is the reboot attempt. For
1001 f5118ade Iustin Pop
        Linux, this command require that the kernel option
1002 f5118ade Iustin Pop
        <literal>CONFIG_MAGIC_SYSRQ</literal> is enabled.
1003 f5118ade Iustin Pop
      </para>
1004 f5118ade Iustin Pop
1005 f5118ade Iustin Pop
      <para>
1006 f5118ade Iustin Pop
        The <option>--yes</option> option can be used to skip
1007 f5118ade Iustin Pop
        confirmation, while the <option>--force</option> option is
1008 f5118ade Iustin Pop
        needed if the target node is the master node.
1009 f5118ade Iustin Pop
      </para>
1010 f5118ade Iustin Pop
1011 a8083063 Iustin Pop
  </refsect1>
1012 a8083063 Iustin Pop
1013 a8083063 Iustin Pop
  &footer;
1014 a8083063 Iustin Pop
1015 a8083063 Iustin Pop
</refentry>
1016 a8083063 Iustin Pop
1017 a8083063 Iustin Pop
<!-- Keep this comment at the end of the file
1018 a8083063 Iustin Pop
Local variables:
1019 a8083063 Iustin Pop
mode: sgml
1020 a8083063 Iustin Pop
sgml-omittag:t
1021 a8083063 Iustin Pop
sgml-shorttag:t
1022 a8083063 Iustin Pop
sgml-minimize-attributes:nil
1023 a8083063 Iustin Pop
sgml-always-quote-attributes:t
1024 a8083063 Iustin Pop
sgml-indent-step:2
1025 a8083063 Iustin Pop
sgml-indent-data:t
1026 a8083063 Iustin Pop
sgml-parent-document:nil
1027 a8083063 Iustin Pop
sgml-default-dtd-file:nil
1028 a8083063 Iustin Pop
sgml-exposed-tags:nil
1029 a8083063 Iustin Pop
sgml-local-catalogs:nil
1030 a8083063 Iustin Pop
sgml-local-ecat-files:nil
1031 a8083063 Iustin Pop
End:
1032 a8083063 Iustin Pop
-->