From: Sage Weil Date: Tue, 31 Mar 2020 13:16:25 +0000 (-0500) Subject: cephadm: ceph-volume: disallow concurrent execution X-Git-Tag: v15.2.2~81^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=72b90835e31997681423ff7a8020722e15ab2da5;p=ceph.git cephadm: ceph-volume: disallow concurrent execution Fixes: https://tracker.ceph.com/issues/44820 Signed-off-by: Sage Weil (cherry picked from commit eae20a70738f20738b3754e464b8a4922912e58a) --- diff --git a/src/cephadm/cephadm b/src/cephadm/cephadm index baccd7c0505..4d71bc6ed51 100755 --- a/src/cephadm/cephadm +++ b/src/cephadm/cephadm @@ -2635,6 +2635,9 @@ def command_ceph_volume(): if args.fsid: make_log_dir(args.fsid) + l = FileLock(args.fsid) + l.acquire() + (uid, gid) = (0, 0) # ceph-volume runs as root mounts = get_container_mounts(args.fsid, 'osd', None)