fix defect 4535: xcat can not get the right disk name for powerkvm VM
This commit is contained in:
parent
6ba12f6085
commit
decd51de2d
@ -52,7 +52,7 @@ d-i partman/early_command string \
|
||||
head -n1 /tmp/devs-with-boot | egrep -o '\S+[^0-9]' > /tmp/boot_disk; \
|
||||
rm /tmp/devs-with-boot 2>/dev/null || true; \
|
||||
else \
|
||||
DEV=`ls /dev/disk/by-path/* -l | egrep -o '/dev.*sd[^0-9]$' | sort -t : -k 1 -k 2 -k 3 -k 4 -k 5 -k 6 -k 7 -k 8 -g | head -n1 | egrep -o 'sd.*$'`; \
|
||||
DEV=`ls /dev/disk/by-path/* -l | egrep -o '/dev.*[s|h|v]d[^0-9]$' | sort -t : -k 1 -k 2 -k 3 -k 4 -k 5 -k 6 -k 7 -k 8 -g | head -n1 | egrep -o '[s|h|v]d.*$'`; \
|
||||
if [[ "$DEV" == "" ]]; then DEV="sda"; fi; \
|
||||
echo "/dev/$DEV" > /tmp/boot_disk; \
|
||||
fi; \
|
||||
|
Loading…
Reference in New Issue
Block a user