diff options
| author | Yoshiaki Tamura <yoshi@midokura.jp> | 2011-04-12 22:12:28 +0000 |
|---|---|---|
| committer | Tarmac <> | 2011-04-12 22:12:28 +0000 |
| commit | 6b84c7c935ac1fa7abb82e2a83545ebd4ac4b311 (patch) | |
| tree | 171f0eef2278bd453499898aa502302d9a918e13 | |
| parent | abaf265ca4e83291afac9ba8666423b41b449f28 (diff) | |
| parent | 87d758b18836085d73c8b4230cd4812e0aa876aa (diff) | |
| download | nova-6b84c7c935ac1fa7abb82e2a83545ebd4ac4b311.tar.gz nova-6b84c7c935ac1fa7abb82e2a83545ebd4ac4b311.tar.xz nova-6b84c7c935ac1fa7abb82e2a83545ebd4ac4b311.zip | |
Fix RBDDriver in volume manager. discover_volume was raising exception.
Modified local_path as well.
| -rw-r--r-- | Authors | 1 | ||||
| -rw-r--r-- | nova/volume/driver.py | 6 |
2 files changed, 3 insertions, 4 deletions
@@ -74,5 +74,6 @@ Trey Morris <trey.morris@rackspace.com> Tushar Patil <tushar.vitthal.patil@gmail.com> Vasiliy Shlykov <vash@vasiliyshlykov.org> Vishvananda Ishaya <vishvananda@gmail.com> +Yoshiaki Tamura <yoshi@midokura.jp> Youcef Laribi <Youcef.Laribi@eu.citrix.com> Zhixue Wu <Zhixue.Wu@citrix.com> diff --git a/nova/volume/driver.py b/nova/volume/driver.py index 850893914..85ff17708 100644 --- a/nova/volume/driver.py +++ b/nova/volume/driver.py @@ -557,7 +557,7 @@ class RBDDriver(VolumeDriver): """Returns the path of the rbd volume.""" # This is the same as the remote path # since qemu accesses it directly. - return self.discover_volume(volume) + return "rbd:%s/%s" % (FLAGS.rbd_pool, volume['name']) def ensure_export(self, context, volume): """Synchronously recreates an export for a logical volume.""" @@ -571,10 +571,8 @@ class RBDDriver(VolumeDriver): """Removes an export for a logical volume""" pass - def discover_volume(self, volume): + def discover_volume(self, context, volume): """Discover volume on a remote host""" - # NOTE(justinsb): This is messed up... discover_volume takes 3 args - # but then that would break local_path return "rbd:%s/%s" % (FLAGS.rbd_pool, volume['name']) def undiscover_volume(self, volume): |
