зеркало из https://github.com/Azure/azlustre.git
Updated to use device links from /dev/disk/azure
This commit is contained in:
Родитель
8ec30e88a7
Коммит
07428399cc
4
build.sh
4
build.sh
|
@ -14,6 +14,4 @@
|
||||||
ossDiskSetup \
|
ossDiskSetup \
|
||||||
deployPolicyEngine \
|
deployPolicyEngine \
|
||||||
mdtStorageSku \
|
mdtStorageSku \
|
||||||
mdtNumDisks \
|
ostStorageSku
|
||||||
ostStorageSku \
|
|
||||||
ostNumDisks
|
|
||||||
|
|
|
@ -14,17 +14,13 @@ storage_container="$5"
|
||||||
oss_disk_setup="$6"
|
oss_disk_setup="$6"
|
||||||
deploy_policy_engine="$7"
|
deploy_policy_engine="$7"
|
||||||
mdt_storage_sku="$8"
|
mdt_storage_sku="$8"
|
||||||
num_mdts="$9"
|
ost_storage_sku="$9"
|
||||||
ost_storage_sku="${10}"
|
|
||||||
num_osts="${11}"
|
|
||||||
|
|
||||||
|
|
||||||
if [ "$HOSTNAME" = "$mds" ]; then
|
if [ "$HOSTNAME" = "$mds" ]; then
|
||||||
storage_sku="$mdt_storage_sku"
|
storage_sku="$mdt_storage_sku"
|
||||||
num_disks="$num_mdts"
|
|
||||||
else
|
else
|
||||||
storage_sku="$ost_storage_sku"
|
storage_sku="$ost_storage_sku"
|
||||||
num_disks="$num_osts"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo mds="$1"
|
echo mds="$1"
|
||||||
|
@ -35,11 +31,8 @@ echo storage_container="$5"
|
||||||
echo oss_disk_setup="$6"
|
echo oss_disk_setup="$6"
|
||||||
echo deploy_policy_engine="$7"
|
echo deploy_policy_engine="$7"
|
||||||
echo mdt_storage_sku="$8"
|
echo mdt_storage_sku="$8"
|
||||||
echo num_msts="$9"
|
echo ost_storage_sku="$9"
|
||||||
echo ost_storage_sku="${10}"
|
|
||||||
echo num_osts="${11}"
|
|
||||||
echo storage_sku="$storage_sku"
|
echo storage_sku="$storage_sku"
|
||||||
echo num_disks="$num_disks"
|
|
||||||
|
|
||||||
|
|
||||||
rbh="${mds}rbh"
|
rbh="${mds}rbh"
|
||||||
|
@ -74,28 +67,18 @@ else
|
||||||
devices='/dev/nvme*n1'
|
devices='/dev/nvme*n1'
|
||||||
n_devices=$(echo $devices | wc -w)
|
n_devices=$(echo $devices | wc -w)
|
||||||
echo "Using $n_devices NVME devices"
|
echo "Using $n_devices NVME devices"
|
||||||
elif [ -e /dev/sdb ]; then
|
elif [ -e /dev/disk/azure/resource ]; then
|
||||||
devices='/dev/sdb'
|
devices='/dev/disk/azure/resource'
|
||||||
n_devices=1
|
n_devices=1
|
||||||
echo "Using ephemeral disk on /dev/sdb"
|
echo "Using ephemeral disk on /dev/disk/azure/resource"
|
||||||
else
|
else
|
||||||
echo "ERROR: cannot find devices for storage"
|
echo "ERROR: cannot find devices for storage"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
if [ -e /dev/nvme0n1 ]; then
|
if [ -d /dev/disk/azure/scsi1 ]; then
|
||||||
devices='/dev/nvme*n1'
|
devices='/dev/disk/azure/scsi1/*'
|
||||||
n_devices=$(echo $devices | wc -w)
|
n_devices=$(echo $devices | wc -w)
|
||||||
echo "Using $n_devices NVME devices"
|
|
||||||
elif [ -e /dev/sdb ]; then
|
|
||||||
devices='/dev/sd[b-m]'
|
|
||||||
n_devices=$(echo $devices | wc -w)
|
|
||||||
|
|
||||||
if [ "$n_devices" -gt "$num_disks" ]; then
|
|
||||||
echo "VM has ephemeral disk, ignoring /dev/sdb"
|
|
||||||
devices='/dev/sd[c-m]'
|
|
||||||
n_devices=$(echo $devices | wc -w)
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "Using $n_devices managed disks"
|
echo "Using $n_devices managed disks"
|
||||||
else
|
else
|
||||||
|
|
Загрузка…
Ссылка в новой задаче