mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-06-20 11:22:19 +08:00
feat(host-deployer): try again if the partition cannot be found
This commit is contained in:
@@ -175,6 +175,15 @@ func (d *NBDDriver) setupLVMS() (bool, error) {
|
||||
for i := 0; i < len(subparts); i++ {
|
||||
lvmPartitions = append(lvmPartitions, subparts[i])
|
||||
}
|
||||
} else {
|
||||
log.Infof("wait a second and try again")
|
||||
time.Sleep(time.Second)
|
||||
subparts := lvm.FindPartitions()
|
||||
if len(subparts) > 0 {
|
||||
for i := 0; i < len(subparts); i++ {
|
||||
lvmPartitions = append(lvmPartitions, subparts[i])
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user