mirror of
https://github.com/bin456789/reinstall.git
synced 2025-01-19 04:49:13 +08:00
windows: 修复了错误判断 sda 只读,导致无法安装 iso
This commit is contained in:
parent
e2e829b0b5
commit
275a3fc36f
2
trans.sh
2
trans.sh
@ -1754,7 +1754,7 @@ install_windows() {
|
||||
# sda 只读,放的是 cloud-init 配置,通常 win 有驱动,能识别
|
||||
# 而 vda/nvme/xen 加载驱动后才能识别,所以这时 disk_id 应该为 1
|
||||
if [ -e "/sys/class/block/sda/ro" ] &&
|
||||
[ "$(cat /sys/class/block/sda/ro)" = 0 ]; then
|
||||
[ "$(cat /sys/class/block/sda/ro)" = 1 ]; then
|
||||
disk_id=1
|
||||
else
|
||||
disk_id=0
|
||||
|
Loading…
x
Reference in New Issue
Block a user