]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph-volume: lvm activate should check if the device is mounted to prevent errors... 16919/head
authorAlfredo Deza <adeza@redhat.com>
Wed, 9 Aug 2017 19:24:15 +0000 (15:24 -0400)
committerAlfredo Deza <adeza@redhat.com>
Wed, 9 Aug 2017 19:24:15 +0000 (15:24 -0400)
Signed-off-by: Alfredo Deza <adeza@redhat.com>
src/ceph-volume/ceph_volume/devices/lvm/activate.py

index 1f0de1717c53c41110d6b451c0e03fb9ee8d1de4..7787aabd18bfd741d0d8282a0d18df7d1486f0e9 100644 (file)
@@ -28,7 +28,8 @@ def activate_filestore(lvs):
     # mount the osd
     source = osd_lv.lv_path
     destination = '/var/lib/ceph/osd/%s-%s' % (conf.cluster, osd_id)
-    process.run(['sudo', 'mount', '-v', source, destination])
+    if not system.is_mounted(source, destination=destination):
+        process.run(['sudo', 'mount', '-v', source, destination])
 
     # ensure that the symlink for the journal is there
     if not os.path.exists(osd_journal):