summaryrefslogtreecommitdiffstats
path: root/boot
diff options
context:
space:
mode:
authorEthan Lynn <ethanlynnl@vmware.com>2017-05-03 16:07:04 +0800
committerEthan Lynn <ethanlynnl@vmware.com>2017-05-03 16:11:17 +0800
commit2eb4fdb92bf0be8863dc1ef5d7ca142342f30b37 (patch)
tree3b0d34631ecb9b28b922e5be1401a37e03ab6ab1 /boot
parentc55d79043a44fbfea2d2aa8781acfec4ee0d3a17 (diff)
Don't hard code second disk in asdc_install.sh
Some openstack env will reconignized the second disk as 'sdb', so it's better avoid to hard code 'vdb' in asdc_install.sh. Change-Id: I8e7f77931b70c71f3f27061623cc928a96c40f6c Signed-off-by: Ethan Lynn <ethanlynnl@vmware.com>
Diffstat (limited to 'boot')
-rw-r--r--boot/asdc_install.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/boot/asdc_install.sh b/boot/asdc_install.sh
index 5ef620c9..2f07b232 100644
--- a/boot/asdc_install.sh
+++ b/boot/asdc_install.sh
@@ -70,8 +70,8 @@ if [[ $CLOUD_ENV == "rackspace" ]]
then
DISK="xvdb"
else
- DISK="vdb"
- sed -i "s/xvdb/vdb/g" /opt/asdc_ext_volume_partitions.txt
+ DISK=$(ls /dev |grep -e '^.*db$')
+ sed -i "s/xvdb/$DISK/g" /opt/asdc_ext_volume_partitions.txt
fi
sfdisk /dev/$DISK < /opt/asdc_ext_volume_partitions.txt