Statistics
| Branch: | Tag: | Revision:

root / man / ganeti.sgml @ e0897adf

History | View | Annotate | Download (8.2 kB)

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

    
3
  <!-- Fill in your name for FIRSTNAME and SURNAME. -->
4
  <!-- Please adjust the date whenever revising the manpage. -->
5
  <!ENTITY dhdate      "<date>June 08, 2010</date>">
6
  <!-- SECTION should be 1-8, maybe w/ subsection other parameters are
7
       allowed: see man(7), man(1). -->
8
  <!ENTITY dhsection   "<manvolnum>7</manvolnum>">
9
  <!ENTITY dhucpackage "<refentrytitle>ganeti</refentrytitle>">
10
  <!ENTITY dhpackage   "ganeti">
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
      <year>2008</year>
24
      <year>2009</year>
25
      <year>2010</year>
26
      <holder>Google Inc.</holder>
27
    </copyright>
28
    &dhdate;
29
  </refentryinfo>
30
  <refmeta>
31
    &dhucpackage;
32

    
33
    &dhsection;
34
    <refmiscinfo>Ganeti 2.2</refmiscinfo>
35
  </refmeta>
36
  <refnamediv>
37
    <refname>&dhpackage;</refname>
38

    
39
    <refpurpose>cluster-based virtualization management</refpurpose>
40

    
41
  </refnamediv>
42
  <refsynopsisdiv>
43
    <screen>
44
# gnt-cluster init cluster1.example.com
45
# gnt-node add node2.example.com
46
# gnt-instance add -n node2.example.com \
47
&gt; -o debootstrap --disk 0:size=30g \
48
&gt; -t plain instance1.example.com
49
    </screen>
50
  </refsynopsisdiv>
51
  <refsect1>
52
    <title>DESCRIPTION</title>
53

    
54
    <para>
55
      The Ganeti software manages physical nodes and virtual instances
56
      of a cluster based on a virtualization software. The current
57
      version (2.2) supports Xen 3.x and KVM (72 or above) as hypervisors.
58
    </para>
59

    
60
  </refsect1>
61
  <refsect1>
62
    <title>Quick start</title>
63

    
64
    <para>
65
      First you must install the software on all the cluster nodes,
66
      either from sources or (if available) from a package. The next
67
      step is to create the initial cluster configuration, using
68
      <userinput>gnt-cluster init</userinput>.
69
    </para>
70

    
71
    <para>
72
      Then you can add other nodes, or start creating instances.
73
    </para>
74

    
75
  </refsect1>
76

    
77
  <refsect1>
78
    <title>Cluster architecture</title>
79

    
80
    <para>
81
      In Ganeti 2.0, the architecture of the cluster is a little more
82
      complicated than in 1.2. The cluster is coordinated by a master
83
      daemon (<citerefentry>
84
      <refentrytitle>ganeti-masterd</refentrytitle>
85
      <manvolnum>8</manvolnum> </citerefentry>), running on the master
86
      node. Each node runs (as before) a node daemon, and the master
87
      has the <acronym>RAPI</acronym> daemon running too.
88
    </para>
89

    
90
    <refsect2>
91
      <title>Node roles</title>
92

    
93
      <para>Each node can be in one of the following states:
94
        <variablelist>
95
          <varlistentry>
96
            <term>master</term>
97
            <listitem>
98
              <para>
99
                Only one node per cluster can be in this role, and
100
                this node is the one holding the authoritative copy of
101
                the cluster configuration and the one that can
102
                actually execute commands on the cluster and modify
103
                the cluster state. See more details under
104
                <emphasis>Cluster configuration</emphasis>.
105
              </para>
106
            </listitem>
107
          </varlistentry>
108
          <varlistentry>
109
            <term>master_candidate</term>
110
            <listitem>
111
              <para>The node receives the full cluster configuration
112
              (configuration file and jobs) and can become a master
113
              via the <command>gnt-cluster masterfailover</command>
114
              command. Nodes that are not in this state cannot
115
              transition into the master role due to missing
116
              state.</para>
117
            </listitem>
118
          </varlistentry>
119
          <varlistentry>
120
            <term>regular</term>
121
            <listitem>
122
              <para>This the normal state of a node.</para>
123
            </listitem>
124
          </varlistentry>
125
          <varlistentry>
126
            <term>drained</term>
127
            <listitem>
128
              <para>Nodes in this state are functioning normally but
129
              cannot receive new instance, because the intention is to
130
              set them to <emphasis>offline</emphasis> or remove them
131
              from the cluster.</para>
132
            </listitem>
133
          </varlistentry>
134
          <varlistentry>
135
            <term>offline</term>
136
            <listitem>
137
              <para>These nodes are still recorded in the Ganeti
138
              configuration, but except for the master daemon startup
139
              voting procedure, they are not actually contacted by the
140
              master. This state was added in order to allow broken
141
              machines (that are being repaired) to remain in the
142
              cluster but without creating problems.</para>
143
            </listitem>
144
          </varlistentry>
145
        </variablelist>
146
      </para>
147
    </refsect2>
148

    
149
    <refsect2>
150
      <title>Cluster configuration</title>
151

    
152
      <para>The master node keeps and is responsible for the cluster
153
      configuration. On the filesystem, this is stored under the
154
      <filename
155
      class="directory">@LOCALSTATEDIR@/ganeti/lib</filename>
156
      directory, and if the master daemon is stopped it can be backed
157
      up normally.</para>
158

    
159
      <para>The master daemon will replicate the configuration
160
      database called <filename>config.data</filename> and the job
161
      files to all the nodes in the master candidate role. It will
162
      also distribute a copy of some configuration values via the
163
      <emphasis>ssconf</emphasis> files, which are stored in the same
164
      directory and start with <filename>ssconf_</filename> prefix, to
165
      all nodes.</para>
166

    
167
    </refsect2>
168

    
169
    <refsect2>
170
      <title>Jobs</title>
171

    
172
      <para>
173
        All cluster modification are done via jobs. A job consists of
174
        one or more opcodes, and the list of opcodes is processed
175
        serially. If an opcode fails, the entire job is failed and
176
        later opcodes are no longer processed. A job can be in one of
177
        the following states:
178
        <variablelist>
179
          <varlistentry>
180
            <term>queued</term>
181
            <listitem>
182
              <simpara>The job has been submitted but not yet
183
              processed by the master daemon.</simpara>
184
            </listitem>
185
          </varlistentry>
186
          <varlistentry>
187
            <term>waiting</term>
188
            <listitem>
189
              <simpara>The job is waiting for for locks before the
190
              first of its opcodes.</simpara>
191
            </listitem>
192
          </varlistentry>
193
          <varlistentry>
194
            <term>canceling</term>
195
            <listitem>
196
              <para>The jos is waiting for locks, but is has been
197
              marked for cancellation. It will not transition to
198
              <emphasis>running</emphasis>, but to
199
              <emphasis>canceled</emphasis>.
200
              </para>
201
            </listitem>
202
          </varlistentry>
203
          <varlistentry>
204
            <term>running</term>
205
            <listitem>
206
              <simpara>The job is currently being executed.</simpara>
207
            </listitem>
208
          </varlistentry>
209
          <varlistentry>
210
            <term>canceled</term>
211
            <listitem>
212
              <para>The job has been canceled before starting
213
              execution.</para>
214
            </listitem>
215
          </varlistentry>
216
          <varlistentry>
217
            <term>success</term>
218
            <listitem>
219
              <para>The job has finished successfully.</para>
220
            </listitem>
221
          </varlistentry>
222
          <varlistentry>
223
            <term>error</term>
224
            <listitem>
225
              <para>The job has failed during runtime, or the master
226
              daemon has been stopped during the job execution.</para>
227
            </listitem>
228
          </varlistentry>
229
        </variablelist>
230
      </para>
231
    </refsect2>
232
  </refsect1>
233

    
234
  &footer;
235

    
236
</refentry>
237

    
238
<!-- Keep this comment at the end of the file
239
Local variables:
240
mode: sgml
241
sgml-omittag:t
242
sgml-shorttag:t
243
sgml-minimize-attributes:nil
244
sgml-always-quote-attributes:t
245
sgml-indent-step:2
246
sgml-indent-data:t
247
sgml-parent-document:nil
248
sgml-default-dtd-file:nil
249
sgml-exposed-tags:nil
250
sgml-local-catalogs:nil
251
sgml-local-ecat-files:nil
252
End:
253
-->