]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/cephfs: lsof if umount fails 16413/head
authorYan, Zheng <zyan@redhat.com>
Wed, 19 Jul 2017 07:32:37 +0000 (15:32 +0800)
committerYan, Zheng <zyan@redhat.com>
Wed, 19 Jul 2017 07:32:37 +0000 (15:32 +0800)
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
qa/tasks/cephfs/fuse_mount.py
qa/tasks/cephfs/kernel_mount.py

index 872412f912dec178c6007f28b602aae6cb048f1c..8d8410c69edce471954f347a10b0759964feaf99 100644 (file)
@@ -222,6 +222,15 @@ class FuseMount(CephFSMount):
         except run.CommandFailedError:
             log.info('Failed to unmount ceph-fuse on {name}, aborting...'.format(name=self.client_remote.name))
 
+            self.client_remote.run(args=[
+                'sudo',
+                run.Raw('PATH=/usr/sbin:$PATH'),
+                'lsof',
+                run.Raw(';'),
+                'ps',
+                'auxf',
+            ])
+
             # abort the fuse mount, killing all hung processes
             if self._fuse_conn:
                 self.run_python(dedent("""
index 105dd4025faeb1a03042d5bb66b55d2ff5c738d4..bfa1ac679166bd90367b9982be2806e4d922bc73 100644 (file)
@@ -98,7 +98,17 @@ class KernelMount(CephFSMount):
         if force:
             cmd.append('-f')
 
-        self.client_remote.run(args=cmd)
+        try:
+            self.client_remote.run(args=cmd)
+        except Exception as e:
+            self.client_remote.run(args=[
+                'sudo',
+                run.Raw('PATH=/usr/sbin:$PATH'),
+                'lsof',
+                run.Raw(';'),
+                'ps', 'auxf',
+            ])
+            raise e
 
         rproc = self.client_remote.run(
             args=[