diff options
author | Sage Weil <sage@inktank.com> | 2013-08-20 22:39:09 -0700 |
---|---|---|
committer | Sage Weil <sage@inktank.com> | 2013-08-26 21:33:21 -0700 |
commit | 39adc0195e6016ce36828885515be1bffbc10ae1 (patch) | |
tree | 4c8757a57213c9d2c30ef1f12069e82d95c8d22c | |
parent | 6a4fe7b9b068ae990d6404921a46631fe9ebcd31 (diff) | |
download | ceph-39adc0195e6016ce36828885515be1bffbc10ae1.tar.gz |
ceph-disk: partprobe after creating journal partition
At least one user reports that a partprobe is needed after creating the
journal partition. It is not clear why sgdisk is not doing it, but this
fixes ceph-disk for them, and should be harmless for other users.
Fixes: #5599
Tested-by: lurbs in #ceph
Signed-off-by: Sage Weil <sage@inktank.com>
(cherry picked from commit 2af59d5e81c5e3e3d7cfc50d9330d7364659c5eb)
(cherry picked from commit 3e42df221315679605d68b2875aab6c7eb6b3cc4)
-rwxr-xr-x | src/ceph-disk | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/ceph-disk b/src/ceph-disk index dce6224080e..3d09bdf7418 100755 --- a/src/ceph-disk +++ b/src/ceph-disk @@ -851,9 +851,21 @@ def prepare_journal_dev( journal, ], ) + + # try to make sure the kernel refreshes the table. note + # that if this gets ebusy, we are probably racing with + # udev because it already updated it.. ignore failure here. + LOG.debug('Calling partprobe on prepared device %s', journal) + subprocess.call( + args=[ + 'partprobe', + journal, + ], + ) + + # wait for udev event queue to clear subprocess.call( args=[ - # wait for udev event queue to clear 'udevadm', 'settle', ], |