From 877f66826cd1b50163c67e73c8ebb4590c0f7ec8 Mon Sep 17 00:00:00 2001 From: Jim Rollenhagen Date: Fri, 6 Feb 2015 07:08:09 -0800 Subject: [PATCH] Use partx to update partition table partprobe does not appear to work in virtual machines. Let's find out if `partx -u` does the same thing and also works on virt. Change-Id: I4467299a82e728930ac8f99a0ba16d3ea7c6755c Closes-Bug: #1418833 --- ironic_python_agent/shell/copy_configdrive_to_disk.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ironic_python_agent/shell/copy_configdrive_to_disk.sh b/ironic_python_agent/shell/copy_configdrive_to_disk.sh index de0b1b38d..ce0fcc17c 100755 --- a/ironic_python_agent/shell/copy_configdrive_to_disk.sh +++ b/ironic_python_agent/shell/copy_configdrive_to_disk.sh @@ -41,9 +41,9 @@ DEVICE="$2" [[ -f $CONFIGDRIVE ]] || usage "$CONFIGDRIVE (CONFIGDRIVE) is not a regular file" [[ -b $DEVICE ]] || usage "$DEVICE (DEVICE) is not a block device" -# We need to run partprobe to ensure all partitions are visible so the +# We need to run partx -u to ensure all partitions are visible so the # following blkid command returns partitions just imaged to the device -/sbin/partprobe $DEVICE || fail "running partprobe against $DEVICE" +partx -u $DEVICE || fail "running partx -u $DEVICE" # Check for preexisting partition for configdrive EXISTING_PARTITION=`/sbin/blkid -l -o device $DEVICE -t LABEL=config-2`