<simpara><emphasis role="strong">Note:</emphasis> This is
only valid for multi-node clusters.</simpara>
<simpara>
- A mirror is set between the local node and a remote
- one, which must be specified with the --secondary-node
- option. Use this option to obtain a highly available
- instance that can be failed over to a remote node
- should the primary one fail.
+ A mirror is set between the local node and a remote one, which
+ must be specified with the second value of the --node option. Use
+ this option to obtain a highly available instance that can be
+ failed over to a remote node should the primary one fail.
</simpara>
</listitem>
</varlistentry>
<para>
For example if you want to create an highly available instance
use the remote_raid1 disk template:
- <synopsis>gnt-instance add -n <replaceable>TARGET_NODE</replaceable> -o <replaceable>OS_TYPE</replaceable> -t remote_raid1 \
- --secondary-node=<replaceable>SECONDARY_NODE</replaceable> <replaceable>INSTANCE_NAME</replaceable></synopsis>
+ <synopsis>gnt-instance add -n <replaceable>TARGET_NODE</replaceable><optional>:<replaceable>SECONDARY_NODE</replaceable></optional> -o <replaceable>OS_TYPE</replaceable> -t remote_raid1 \
+ <replaceable>INSTANCE_NAME</replaceable></synopsis>
<para>
To know which operating systems your cluster supports you can use:
To create a network mirrored instance, change the argument to
the <option>-t</option> option from <literal>plain</literal>
to <literal>remote_raid1</literal> and specify the node on
- which the mirror should reside with the
- <option>--secondary-node</option> option, like this:
+ which the mirror should reside with the second value of the
+ <option>--node</option> option, like this:
</para>
<screen>
-# gnt-instance add -t remote_raid1 --secondary-node node1 \
- -n node2 -o debian-etch instance2
+# gnt-instance add -t remote_raid1 -n node1:node2 -o debian-etch instance2
* creating instance disks...
adding instance instance2 to cluster config
Waiting for instance instance1 to sync disks.
- device sdb: 76.30% done, 72 estimated seconds remaining
- device sdb: 94.80% done, 18 estimated seconds remaining
Instance instance2's disks are in sync.
-creating os for instance instance2 on node node2.example.com
+creating os for instance instance2 on node node1.example.com
* running the instance OS create scripts...
* starting instance...
</screen>
<title>IMPORT</title>
<cmdsynopsis>
<command>import</command>
- <arg choice="req">-n <replaceable>node</replaceable></arg>
+ <arg choice="req">-n <replaceable>node<optional>:secondary-node</optional></replaceable></arg>
<arg>-s <replaceable>disksize</replaceable></arg>
<arg>-o <replaceable>os-type</replaceable></arg>
<arg>-m <replaceable>memsize</replaceable></arg>
<term>remote_raid1</term>
<listitem>
<para>
- Disk devices will be md raid1 arrays with one
- component (so it's not actually raid1): a drbd device
- between the instance's primary node and the node given
- by the option <option>--secondary-node</option>.
+ Disk devices will be md raid1 arrays with one component (so
+ it's not actually raid1): a drbd device between the instance's
+ primary node and the node given by the second value of the
+ <option>--node</option> option.
</para>
</listitem>
</varlistentry>
</para>
<para>
- The <option>--secondary-node</option> option is used with
- the remote raid disk template type and specifies the remote
- node.
- </para>
-
- <para>
If you do not want gnt-backup to wait for the disk mirror
to be synced, use the <option>--no-wait-for-sync</option>
option.
</para>
-
<para>
Example:
<screen>
</group>
</arg>
<sbr>
- <arg choice="req">-n <replaceable>node</replaceable></arg>
+ <arg choice="req">-n <replaceable>node<optional>:secondary-node</optional></replaceable></arg>
<arg choice="req"><replaceable>instance</replaceable></arg>
</cmdsynopsis>
<para>
<term>remote_raid1</term>
<listitem>
<para>
- Disk devices will be md raid1 arrays with one
- component (so it's not actually raid1): a drbd device
- between the instance's primary node and the node given
- by the option <option>--secondary-node</option>.
+ Disk devices will be md raid1 arrays with one component (so
+ it's not actually raid1): a drbd device between the
+ instance's primary node and the node given by the second
+ value of the <option>--node</option> option.
</para>
</listitem>
</varlistentry>
</para>
<para>
- The <option>--secondary-node</option> option is used with
- the remote raid disk template type and specifies the remote
- node.
+ The optional second value of the <option>--node</option> is used for
+ the remote raid template type and specifies the remote node.
</para>
<para>
option.
</para>
-
<para>
Example:
<screen>
# gnt-instance add -t plain -s 30g -m 512 -o debian-etch \
-n node1.example.com instance1.example.com
-# gnt-instance add -t remote_raid1 --secondary-node node3.example.com \
- -s 30g -m 512 -o debian-etch \
- -n node1.example.com instance2.example.com
+# gnt-instance add -t remote_raid1 -s 30g -m 512 -o debian-etch \
+ -n node1.example.com:node2.example.com instance2.example.com
</screen>
</para>
-
</refsect3>
<refsect3>
<varlistentry>
<term>snodes</term>
<listitem>
- <simpara>comma-separated list of secondary-nodes for the
+ <simpara>comma-separated list of secondary nodes for the
instance; usually this will be just one node</simpara>
</listitem>
</varlistentry>