Skip to content

Commit 2d1c417

Browse files
authored
Merge pull request kubernetes#92258 from SidneyShen/node-boot-nvme-disk-fix
Add logic to check if local NVMe SSDs in node boot-up script
2 parents e201c6b + 27658f8 commit 2d1c417

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

cluster/gce/gci/configure-helper.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -364,6 +364,13 @@ function ensure-local-ssds() {
364364
# The following mounts or symlinks NVMe devices
365365
get-local-disk-num "nvme" "block"
366366
local nvmeblocknum="${localdisknum}"
367+
get-local-disk-num "nvme" "fs"
368+
local nvmefsnum="${localdisknum}"
369+
# Check if NVMe SSD specified.
370+
if [ "${nvmeblocknum}" -eq "0" ] && [ "${nvmefsnum}" -eq "0" ]; then
371+
echo "No local NVMe SSD specified."
372+
return
373+
fi
367374
local i=0
368375
for ssd in /dev/nvme*; do
369376
if [ -e "${ssd}" ]; then

0 commit comments

Comments
 (0)