mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-23 11:50:44 +00:00
Merge pull request #92258 from SidneyShen/node-boot-nvme-disk-fix
Add logic to check if local NVMe SSDs in node boot-up script
This commit is contained in:
commit
2d1c417934
@ -364,6 +364,13 @@ function ensure-local-ssds() {
|
||||
# The following mounts or symlinks NVMe devices
|
||||
get-local-disk-num "nvme" "block"
|
||||
local nvmeblocknum="${localdisknum}"
|
||||
get-local-disk-num "nvme" "fs"
|
||||
local nvmefsnum="${localdisknum}"
|
||||
# Check if NVMe SSD specified.
|
||||
if [ "${nvmeblocknum}" -eq "0" ] && [ "${nvmefsnum}" -eq "0" ]; then
|
||||
echo "No local NVMe SSD specified."
|
||||
return
|
||||
fi
|
||||
local i=0
|
||||
for ssd in /dev/nvme*; do
|
||||
if [ -e "${ssd}" ]; then
|
||||
|
Loading…
Reference in New Issue
Block a user