Implement cluster rename operation
[ganeti-local] / man / gnt-cluster.sgml
1 <!doctype refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN" [
2
3   <!-- Fill in your name for FIRSTNAME and SURNAME. -->
4   <!-- Please adjust the date whenever revising the manpage. -->
5   <!ENTITY dhdate      "<date>June 20, 2007</date>">
6   <!-- SECTION should be 1-8, maybe w/ subsection other parameters are
7        allowed: see man(7), man(1). -->
8   <!ENTITY dhsection   "<manvolnum>8</manvolnum>">
9   <!ENTITY dhucpackage "<refentrytitle>gnt-cluster</refentrytitle>">
10   <!ENTITY dhpackage   "gnt-cluster">
11
12   <!ENTITY debian      "<productname>Debian</productname>">
13   <!ENTITY gnu         "<acronym>GNU</acronym>">
14   <!ENTITY gpl         "&gnu; <acronym>GPL</acronym>">
15   <!ENTITY footer SYSTEM "footer.sgml">
16 ]>
17
18 <refentry>
19   <refentryinfo>
20     <copyright>
21       <year>2006</year>
22       <year>2007</year>
23       <holder>Google Inc.</holder>
24     </copyright>
25     &dhdate;
26   </refentryinfo>
27   <refmeta>
28     &dhucpackage;
29
30     &dhsection;
31     <refmiscinfo>ganeti 1.2</refmiscinfo>
32   </refmeta>
33   <refnamediv>
34     <refname>&dhpackage;</refname>
35
36     <refpurpose>ganeti administration, cluster-wide</refpurpose>
37   </refnamediv>
38   <refsynopsisdiv>
39     <cmdsynopsis>
40       <command>&dhpackage; </command>
41
42       <arg choice="req">command</arg>
43       <arg>arguments...</arg>
44     </cmdsynopsis>
45   </refsynopsisdiv>
46   <refsect1>
47     <title>DESCRIPTION</title>
48
49     <para>
50       The <command>&dhpackage;</command> is used for cluster-wide
51       administration in the ganeti system.
52     </para>
53
54   </refsect1>
55   <refsect1>
56     <title>COMMANDS</title>
57
58     <cmdsynopsis>
59       <command>command</command>
60       <arg>-n <replaceable>node</replaceable></arg>
61       <arg choice="req"><replaceable>command</replaceable></arg>
62     </cmdsynopsis>
63
64     <para>
65       Executes a command on all nodes. If the option
66       <option>-n</option> is not given, the command will be executed
67       on all nodes, otherwise it will be executed only on the node(s)
68       specified. Use the option multiple times for running it on
69       multiple nodes, like:
70
71       <screen>
72         # gnt-cluster command -n node1.example.com -n node2.example.com date
73       </screen>
74
75     </para>
76
77     <para>The command is constructed by concatenating all other
78     command line arguments. For example, to list the contents of the
79     <filename class="directory">/etc</filename> directory on all
80     nodes, run:
81
82       <screen>
83         # gnt-cluster command ls -l /etc
84       </screen>
85
86       and the command which will be executed will be
87       <computeroutput>"ls -l /etc"</computeroutput>
88     </para>
89
90
91     <cmdsynopsis>
92       <command>copyfile</command>
93       <arg>-n <replaceable>node</replaceable></arg>
94       <arg choice="req"><replaceable>file</replaceable></arg>
95     </cmdsynopsis>
96
97     <para>
98       Copies a file to all or to some nodes. The argument specifies
99       the source file (on the current system), the <option>-n</option>
100       argument specifies the target node, or nodes if the option is
101       given multiple times. If <option>-n</option> is not given at
102       all, the file will be copied to all nodes.
103
104       Example:
105       <screen>
106         # gnt-cluster -n node1.example.com -n node2.example.com copyfile /tmp/test
107       </screen>
108
109       This will copy the file <filename>/tmp/test</filename> from the
110       current node to the two named nodes.
111     </para>
112
113     <cmdsynopsis>
114       <command>destroy</command>
115     </cmdsynopsis>
116
117     <para>
118       Remove all configuration files related to the cluster, so that a
119       <command>gnt-cluster init</command> can be done again afterwards.
120     </para>
121
122     <cmdsynopsis>
123       <command>getmaster</command>
124     </cmdsynopsis>
125
126     <para>
127       Displays the current master node.
128     </para>
129
130     <cmdsynopsis>
131       <command>info</command>
132     </cmdsynopsis>
133
134     <para>
135       Shows runtime cluster information: cluster name, architecture
136       (32 or 64 bit), master node, node list and instance list.
137     </para>
138
139     <cmdsynopsis>
140       <command>init</command>
141       <arg>-s <replaceable>secondary_ip</replaceable></arg>
142       <arg>-b <replaceable>bridge</replaceable></arg>
143       <arg choice="req"><replaceable>clustername</replaceable></arg>
144     </cmdsynopsis>
145     <para>
146       This commands is only run once initially on the first node of
147       the cluster. It will initialize the cluster configuration and
148       setup ssh-keys and more.
149     </para>
150
151     <para>
152       Note that the <replaceable>clustername</replaceable> is not any
153       random name. It has to be resolvable to an IP address using DNS,
154       and it is best if you give the fully-qualified domain name.
155     </para>
156
157     <para>
158       The cluster can run in two modes: single-home or dual-homed. In
159       the first case, all traffic (both public traffic, inter-node
160       traffic and data replication traffic) goes over the same
161       interface. In the dual-homed case, the data replication traffic
162       goes over the second network. The <option>-s</option> option
163       here marks the cluster as dual-homed and its parameter
164       represents this node's address on the second network. If you
165       initialise the cluster with <option>-s</option>, all nodes added
166       must have a secondary IP as well.
167     </para>
168
169     <para>
170       Note that for Ganeti it doesn't matter if the secondary network
171       is actually a separate physical network, or is done using
172       tunneling, etc. For performance reasons, it's recommended to use
173       a separate network, of course.
174     </para>
175
176     <para>
177       The <option>-b</option> option specifies the default bridge for
178       instances.
179     </para>
180
181     <cmdsynopsis>
182       <command>masterfailover</command>
183     </cmdsynopsis>
184
185     <para>
186       Failover the master role to the current node.
187     </para>
188
189     <cmdsynopsis>
190       <command>rename</command>
191       <arg>-f</arg>
192       <arg choice="req"><replaceable>name</replaceable></arg>
193     </cmdsynopsis>
194
195     <para>
196       Renames the cluster and in the process updates the master IP
197       address to the one the new name resolves to. At least one of
198       either the name or the IP address must be different, otherwise
199       the operation will be aborted.
200     </para>
201
202     <para>
203       Note that since this command can be dangerous (especially when
204       run over SSH), the command will require confirmation unless run
205       with the <option>-f</option> option.
206     </para>
207
208     <cmdsynopsis>
209       <command>verify</command>
210     </cmdsynopsis>
211
212     <para>
213       Verify correctness of cluster configuration. This is safe with
214       respect to running instances, and incurs no downtime of the
215       instances.
216     </para>
217
218     <cmdsynopsis>
219       <command>version</command>
220     </cmdsynopsis>
221
222     <para>
223       Show the cluster version.
224     </para>
225
226   </refsect1>
227
228   &footer;
229
230 </refentry>
231
232 <!-- Keep this comment at the end of the file
233 Local variables:
234 mode: sgml
235 sgml-omittag:t
236 sgml-shorttag:t
237 sgml-minimize-attributes:nil
238 sgml-always-quote-attributes:t
239 sgml-indent-step:2
240 sgml-indent-data:t
241 sgml-parent-document:nil
242 sgml-default-dtd-file:nil
243 sgml-exposed-tags:nil
244 sgml-local-catalogs:nil
245 sgml-local-ecat-files:nil
246 End:
247 -->