No subject


Tue Apr 9 23:27:50 UTC 2013


13.4. Using DRBD VBDs

In order to use a DRBD resource as the virtual block device, you must add a
line like the following to your Xen domU configuration:

disk =3D [ 'drbd:<resource>,xvda,w' ]

This example configuration makes the DRBD resource named
*resource*available to the domU as
/dev/xvda in read/write mode ( w).

Of course, you may use multiple DRBD resources with a single domU. In that
case, simply add more entries like the one provided in the example to the
disk option, separated by commas.


13.5. Starting, stopping, and migrating DRBD-backed domU=92s

*Starting the domU. *Once you have configured your DRBD-backed domU, you
may start it as you would any other domU:

xm create <domU>
Using config file "+/etc/xen/<domU>+".
Started domain <domU>

In the process, the DRBD resource you configured as the VBD will be
promoted to the primary role, and made accessible to Xen as expected.

*Stopping the domU. *This is equally straightforward:

xm shutdown -w <domU>
Domain <domU> terminated.

Again, as you would expect, the DRBD resource is returned to the secondary
role after the domU is successfully shut down.

*Migrating the domU. *This, too, is done using the usual Xen tools:

xm migrate --live <domU> <destination-host>

In this case, several administrative steps are automatically taken in rapid
succession: . The resource is promoted to the primary role on *
destination-host*. . Live migration of *domU* is initiated on the local
host. . When migration to the destination host has completed, the resource
is demoted to the secondary role locally.

The fact that both resources must briefly run in the primary role on both
hosts is the reason for having to configure the resource in dual-primary
mode in the first place


http://www.drbd.org/users-guide/s-xen-internal.html


2013/10/26 georg at riseup.net <georg at riseup.net>

> Hi all,
>
> The drbd documentation [1] regarding integration of Xen and pacemaker
> and drbd reads: "You may configure a Xen domU as a Pacemaker resource,
> and automate resource failover. To do so, use the Xen OCF resource
> agent. If you are using the drbd Xen device type described in this
> chapter, you will not need to configure any separate drbd resource for
> use by the Xen cluster resource. Instead, the block-drbd helper script
> will do all the necessary resource transitions for you."
>
> - Is this the 'correct' way to go?
> - If so, should the drbd initscript be used to handle the initial state
>   of the drbd device?
>
> Thanks,
> Georg
>
>
> [1] http://www.drbd.org/users-guide/s-xen-pacemaker.html
>
> _______________________________________________
> Pacemaker mailing list: Pacemaker at oss.clusterlabs.org
> http://oss.clusterlabs.org/mailman/listinfo/pacemaker
>
> Project Home: http://www.clusterlabs.org
> Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
> Bugs: http://bugs.clusterlabs.org
>



--=20
esta es mi vida e me la vivo hasta que dios quiera

--047d7b33cd74b6d70604e9b4ff1e
Content-Type: text/html; charset=windows-1252
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">From drbd site DOCS<br><br><h2 class=3D"" style=3D"clear:b=
oth">13.4.=A0Using DRBD VBDs</h2><p>In order to use a DRBD resource as the =
virtual block device, you must
add a line like the following to your Xen domU configuration:
</p><pre class=3D"">disk =3D [ &#39;drbd:&lt;resource&gt;,xvda,w&#39; ]</pr=
e><p>This example configuration makes the DRBD resource named <span class=
=3D""><em>resource</em></span>
available to the domU as <code class=3D"">/dev/xvda</code> in read/write mo=
de ( <code class=3D"">w</code>).</p><p>Of course, you may use multiple DRBD=
 resources with a single domU. In
that case, simply add more entries like the one provided in the
example to the <code class=3D"">disk</code> option, separated by commas.</p=
><div class=3D"" style=3D"margin-left:0.5in;margin-right:0.5in"><table summ=
ary=3D"Note" border=3D"0"><tbody><tr><td rowspan=3D"2" align=3D"center" val=
ign=3D"top" width=3D"25">
<br></td></tr></tbody></table></div><br><h2 class=3D"" style=3D"clear:both"=
>13.5.=A0Starting, stopping, and migrating DRBD-backed domU=92s</h2><p><str=
ong>Starting the domU.=A0</strong>Once you have configured your DRBD-backed=
 domU, you may start it as
you would any other domU:</p><pre class=3D"">xm create &lt;domU&gt;
Using config file &quot;+/etc/xen/&lt;domU&gt;+&quot;.
Started domain &lt;domU&gt;</pre><p>In the process, the DRBD resource you c=
onfigured as the VBD will be
promoted to the primary role, and made accessible to Xen as expected.</p><p=
><strong>Stopping the domU.=A0</strong>This is equally straightforward:</p>=
<pre class=3D"">xm shutdown -w &lt;domU&gt;
Domain &lt;domU&gt; terminated.</pre><p>Again, as you would expect, the DRB=
D resource is returned to the
secondary role after the domU is successfully shut down.</p><p><strong>Migr=
ating the domU.=A0</strong>This, too, is done using the usual Xen tools:</p=
><pre class=3D"">xm migrate --live &lt;domU&gt; &lt;destination-host&gt;</p=
re>
<p>In this case, several administrative steps are automatically taken in
rapid succession:
. The resource is promoted to the primary role on <span class=3D""><em>dest=
ination-host</em></span>.
. Live migration of <span class=3D""><em>domU</em></span> is initiated on t=
he local host.
. When migration to the destination host has completed, the resource
  is demoted to the secondary role locally.</p><p>The fact that both resour=
ces must briefly run in the primary role on
both hosts is the reason for having to configure the resource in
dual-primary mode in the first place</p><p><br></p><p><a href=3D"http://www=
.drbd.org/users-guide/s-xen-internal.html">http://www.drbd.org/users-guide/=
s-xen-internal.html</a><br></p></div><div class=3D"gmail_extra"><br><br><di=
v class=3D"gmail_quote">
2013/10/26 <a href=3D"mailto:georg at riseup.net">georg at riseup.net</a> <span d=
ir=3D"ltr">&lt;<a href=3D"mailto:georg at riseup.net" target=3D"_blank">georg@=
riseup.net</a>&gt;</span><br><blockquote class=3D"gmail_quote" style=3D"mar=
gin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi all,<br>
<br>
The drbd documentation [1] regarding integration of Xen and pacemaker<br>
and drbd reads: &quot;You may configure a Xen domU as a Pacemaker resource,=
<br>
and automate resource failover. To do so, use the Xen OCF resource<br>
agent. If you are using the drbd Xen device type described in this<br>
chapter, you will not need to configure any separate drbd resource for<br>
use by the Xen cluster resource. Instead, the block-drbd helper script<br>
will do all the necessary resource transitions for you.&quot;<br>
<br>
- Is this the &#39;correct&#39; way to go?<br>
- If so, should the drbd initscript be used to handle the initial state<br>
=A0 of the drbd device?<br>
<br>
Thanks,<br>
Georg<br>
<br>
<br>
[1] <a href=3D"http://www.drbd.org/users-guide/s-xen-pacemaker.html" target=
=3D"_blank">http://www.drbd.org/users-guide/s-xen-pacemaker.html</a><br>
<br>
_______________________________________________<br>
Pacemaker mailing list: <a href=3D"mailto:Pacemaker at oss.clusterlabs.org">Pa=
cemaker at oss.clusterlabs.org</a><br>
<a href=3D"http://oss.clusterlabs.org/mailman/listinfo/pacemaker" target=3D=
"_blank">http://oss.clusterlabs.org/mailman/listinfo/pacemaker</a><br>
<br>
Project Home: <a href=3D"http://www.clusterlabs.org" target=3D"_blank">http=
://www.clusterlabs.org</a><br>
Getting started: <a href=3D"http://www.clusterlabs.org/doc/Cluster_from_Scr=
atch.pdf" target=3D"_blank">http://www.clusterlabs.org/doc/Cluster_from_Scr=
atch.pdf</a><br>
Bugs: <a href=3D"http://bugs.clusterlabs.org" target=3D"_blank">http://bugs=
.clusterlabs.org</a><br>
</blockquote></div><br><br clear=3D"all"><br>-- <br>esta es mi vida e me la=
 vivo hasta que dios quiera
</div>

--047d7b33cd74b6d70604e9b4ff1e--



More information about the Pacemaker mailing list