From 1c52dbedd0d3209627743112dcc142390e67b2b8 Mon Sep 17 00:00:00 2001 From: lsimngar Date: Mon, 11 Aug 2014 14:44:18 +0200 Subject: [PATCH 1/5] Documentation changes about Ceph datastore CEPH_USER attr --- source/administration/storage/ceph_ds.rst | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/source/administration/storage/ceph_ds.rst b/source/administration/storage/ceph_ds.rst index 27d0e7e103..0a0ef77f92 100644 --- a/source/administration/storage/ceph_ds.rst +++ b/source/administration/storage/ceph_ds.rst @@ -26,6 +26,8 @@ Also the ``mon`` daemon must be defined in the ``ceph.conf`` for all the nodes, Additionally each OpenNebula datastore is backed by a ceph pool, these pools must be created and configured in the Ceph cluster. The name of the pool by default is ``one`` but can be changed on a per-datastore basis (see below). +``ceph`` cluster admin must include a valid user to be used by ``one`` ``ceph`` datastore (see below). + This driver can work with either RBD Format 1 or RBD Format 2. To set the default you can specify this option in ``ceph.conf``: .. code:: @@ -81,6 +83,8 @@ The first step to create a Ceph datastore is to set up a template file for it. I +------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | ``POOL_NAME`` | The OpenNebula Ceph pool name. Defaults to ``one``. **This pool must exist before using the drivers**. | +------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| ``CEPH_USER`` | **Mandatory** The OpenNebula Ceph user name. **This ceph user must exist before using the drivers**. | ++------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | ``STAGING_DIR`` | Default path for image operations in the OpenNebula Ceph frontend. | +------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | ``RESTRICTED_DIRS`` | Paths that can not be used to register images. A space separated list of paths. | @@ -120,10 +124,11 @@ An example of datastore: DS_MAD = ceph TM_MAD = ceph - # the following line *must* be preset + # the following lines *must* be preset DISK_TYPE = RBD - POOL_NAME = one + CEPH_USER = libvirt + BRIDGE_LIST = cephfrontend > onedatastore create ds.conf From af31d5ef537fa959f23cdd9250bd9f6598941a39 Mon Sep 17 00:00:00 2001 From: lsimngar Date: Thu, 14 Aug 2014 11:35:51 +0200 Subject: [PATCH 2/5] * Change: CEPH_USER is not mandatory into CEPH datastore conf to become backwards comp. --- source/administration/storage/ceph_ds.rst | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source/administration/storage/ceph_ds.rst b/source/administration/storage/ceph_ds.rst index 0a0ef77f92..d8623258c4 100644 --- a/source/administration/storage/ceph_ds.rst +++ b/source/administration/storage/ceph_ds.rst @@ -83,7 +83,7 @@ The first step to create a Ceph datastore is to set up a template file for it. I +------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | ``POOL_NAME`` | The OpenNebula Ceph pool name. Defaults to ``one``. **This pool must exist before using the drivers**. | +------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| ``CEPH_USER`` | **Mandatory** The OpenNebula Ceph user name. **This ceph user must exist before using the drivers**. | +| ``CEPH_USER`` | The OpenNebula Ceph user name. If set it is used by RBD commands. **This ceph user must exist before using the drivers**. | +------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | ``STAGING_DIR`` | Default path for image operations in the OpenNebula Ceph frontend. | +------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -127,6 +127,8 @@ An example of datastore: # the following lines *must* be preset DISK_TYPE = RBD POOL_NAME = one + + # CEPH_USER is optional CEPH_USER = libvirt BRIDGE_LIST = cephfrontend From c5daf6f732334667df903c9e2ab374ff8ab3b0d4 Mon Sep 17 00:00:00 2001 From: lsimngar Date: Thu, 11 Sep 2014 11:48:09 +0200 Subject: [PATCH 3/5] Doc Fix: one.datastore.allocate IN string cluster ID is mandatory --- source/integration/system_interfaces/api.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/integration/system_interfaces/api.rst b/source/integration/system_interfaces/api.rst index c80df62fca..b71be30ba0 100644 --- a/source/integration/system_interfaces/api.rst +++ b/source/integration/system_interfaces/api.rst @@ -2357,6 +2357,8 @@ one.datastore.allocate +------+------------+--------------------------------------------------------------------------------------------------------+ | IN | String | A string containing the template of the datastore. Syntax can be the usual ``attribute=value`` or XML. | +------+------------+--------------------------------------------------------------------------------------------------------+ +| IN | Int | The cluster ID. If it is -1, this host won't be added to any cluster. | ++------+------------+--------------------------------------------------------------------------------------------------------+ | OUT | Boolean | true or false whenever is successful or not | +------+------------+--------------------------------------------------------------------------------------------------------+ | OUT | Int/String | The allocated resource ID / The error string. | From c6a5c782ae96aa31e504ba54208f3cc188e2d859 Mon Sep 17 00:00:00 2001 From: lsimngar Date: Thu, 11 Sep 2014 11:55:27 +0200 Subject: [PATCH 4/5] Fix: one.datastore.allocate add IN cluster ID is mandatory --- source/integration/system_interfaces/api.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/integration/system_interfaces/api.rst b/source/integration/system_interfaces/api.rst index b71be30ba0..c39f837280 100644 --- a/source/integration/system_interfaces/api.rst +++ b/source/integration/system_interfaces/api.rst @@ -2357,7 +2357,7 @@ one.datastore.allocate +------+------------+--------------------------------------------------------------------------------------------------------+ | IN | String | A string containing the template of the datastore. Syntax can be the usual ``attribute=value`` or XML. | +------+------------+--------------------------------------------------------------------------------------------------------+ -| IN | Int | The cluster ID. If it is -1, this host won't be added to any cluster. | +| IN | Int | The cluster ID. If it is -1, this datastore won't be added to any cluster. | +------+------------+--------------------------------------------------------------------------------------------------------+ | OUT | Boolean | true or false whenever is successful or not | +------+------------+--------------------------------------------------------------------------------------------------------+ From b11f8f2afc3cd729ce801ff6e5dfa842f1057071 Mon Sep 17 00:00:00 2001 From: lsimngar Date: Thu, 11 Sep 2014 11:57:24 +0200 Subject: [PATCH 5/5] Fix: one.datastore.allocate add IN cluster ID is mandatory --- source/integration/system_interfaces/api.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/integration/system_interfaces/api.rst b/source/integration/system_interfaces/api.rst index c39f837280..c25532c831 100644 --- a/source/integration/system_interfaces/api.rst +++ b/source/integration/system_interfaces/api.rst @@ -2357,7 +2357,7 @@ one.datastore.allocate +------+------------+--------------------------------------------------------------------------------------------------------+ | IN | String | A string containing the template of the datastore. Syntax can be the usual ``attribute=value`` or XML. | +------+------------+--------------------------------------------------------------------------------------------------------+ -| IN | Int | The cluster ID. If it is -1, this datastore won't be added to any cluster. | +| IN | Int | The cluster ID. If it is -1, this datastore won't be added to any cluster. | +------+------------+--------------------------------------------------------------------------------------------------------+ | OUT | Boolean | true or false whenever is successful or not | +------+------------+--------------------------------------------------------------------------------------------------------+