mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
storage backend: Add RBD (RADOS Block Device) support
This patch adds support for a new storage backend with RBD support. RBD is the RADOS Block Device and is part of the Ceph distributed storage system. It comes in two flavours: Qemu-RBD and Kernel RBD, this storage backend only supports Qemu-RBD, thus limiting the use of this storage driver to Qemu only. To function this backend relies on librbd and librados being present on the local system. The backend also supports Cephx authentication for safe authentication with the Ceph cluster. For storing credentials it uses the built-in secret mechanism of libvirt. Signed-off-by: Wido den Hollander <wido@widodh.nl>
This commit is contained in:
committed by
Eric Blake
parent
b8e6021e7b
commit
74951eadef
@@ -19,6 +19,7 @@
|
||||
<ref name='pooliscsi'/>
|
||||
<ref name='poolscsi'/>
|
||||
<ref name='poolmpath'/>
|
||||
<ref name='poolrbd'/>
|
||||
</choice>
|
||||
</element>
|
||||
</define>
|
||||
@@ -105,6 +106,15 @@
|
||||
<ref name='target'/>
|
||||
</define>
|
||||
|
||||
<define name='poolrbd'>
|
||||
<attribute name='type'>
|
||||
<value>rbd</value>
|
||||
</attribute>
|
||||
<ref name='commonmetadata'/>
|
||||
<ref name='sizing'/>
|
||||
<ref name='sourcerbd'/>
|
||||
</define>
|
||||
|
||||
<define name='sourceinfovendor'>
|
||||
<optional>
|
||||
<element name='vendor'>
|
||||
@@ -184,17 +194,19 @@
|
||||
</define>
|
||||
|
||||
<define name='sourceinfohost'>
|
||||
<element name='host'>
|
||||
<attribute name='name'>
|
||||
<text/>
|
||||
</attribute>
|
||||
<optional>
|
||||
<attribute name='port'>
|
||||
<ref name="PortNumber"/>
|
||||
<oneOrMore>
|
||||
<element name='host'>
|
||||
<attribute name='name'>
|
||||
<text/>
|
||||
</attribute>
|
||||
</optional>
|
||||
<empty/>
|
||||
</element>
|
||||
<optional>
|
||||
<attribute name='port'>
|
||||
<ref name="PortNumber"/>
|
||||
</attribute>
|
||||
</optional>
|
||||
<empty/>
|
||||
</element>
|
||||
</oneOrMore>
|
||||
</define>
|
||||
|
||||
<define name='sourceinfodev'>
|
||||
@@ -265,14 +277,38 @@
|
||||
<attribute name='type'>
|
||||
<choice>
|
||||
<value>chap</value>
|
||||
<value>ceph</value>
|
||||
</choice>
|
||||
</attribute>
|
||||
<attribute name='login'>
|
||||
<text/>
|
||||
</attribute>
|
||||
<attribute name='passwd'>
|
||||
<text/>
|
||||
</attribute>
|
||||
<choice>
|
||||
<attribute name='login'>
|
||||
<text/>
|
||||
</attribute>
|
||||
<attribute name='username'>
|
||||
<text/>
|
||||
</attribute>
|
||||
</choice>
|
||||
<optional>
|
||||
<attribute name='passwd'>
|
||||
<text/>
|
||||
</attribute>
|
||||
</optional>
|
||||
<optional>
|
||||
<ref name='sourceinfoauthsecret'/>
|
||||
</optional>
|
||||
</element>
|
||||
</define>
|
||||
|
||||
<define name='sourceinfoauthsecret'>
|
||||
<element name='secret'>
|
||||
<choice>
|
||||
<attribute name='uuid'>
|
||||
<text/>
|
||||
</attribute>
|
||||
<attribute name='usage'>
|
||||
<text/>
|
||||
</attribute>
|
||||
</choice>
|
||||
</element>
|
||||
</define>
|
||||
|
||||
@@ -450,6 +486,16 @@
|
||||
</element>
|
||||
</define>
|
||||
|
||||
<define name='sourcerbd'>
|
||||
<element name='source'>
|
||||
<ref name='sourceinfoname'/>
|
||||
<ref name='sourceinfohost'/>
|
||||
<optional>
|
||||
<ref name='sourceinfoauth'/>
|
||||
</optional>
|
||||
</element>
|
||||
</define>
|
||||
|
||||
<define name='name'>
|
||||
<data type='string'>
|
||||
<param name="pattern">[a-zA-Z0-9_\+\-]+</param>
|
||||
|
||||
Reference in New Issue
Block a user