From 877c8e7d8c0d397021e1a06b2d2a36962d6a9d42 Mon Sep 17 00:00:00 2001 From: Zhiteng Huang Date: Tue, 21 Apr 2015 00:25:11 +0800 Subject: [PATCH] RBD: Add missing Ceph customized cluster name support It turns out '--cluster' is also needed when RBD driver talks to ceph cluster using 'ceph' command (not via librados). This change appends RBDDriver._ceph_args with '--cluster' when 'rbd_cluster_name' config option is not None. Change-Id: Ie957a3658a630947a140f4172f775e42b7611c6e Closes-bug: #1444855 --- cinder/volume/drivers/rbd.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cinder/volume/drivers/rbd.py b/cinder/volume/drivers/rbd.py index a78921d3a..ae1802862 100644 --- a/cinder/volume/drivers/rbd.py +++ b/cinder/volume/drivers/rbd.py @@ -297,6 +297,8 @@ class RBDDriver(driver.VolumeDriver): args.extend(['--id', self.configuration.rbd_user]) if self.configuration.rbd_ceph_conf: args.extend(['--conf', self.configuration.rbd_ceph_conf]) + if self.configuration.rbd_cluster_name: + args.extend(['--cluster', self.configuration.rbd_cluster_name]) return args def _connect_to_rados(self, pool=None): -- 2.45.2