Aug 24 12:28:42 node5 os-agent[1157]: time="2022-08-24T12:28:42Z" level=error msg="update error fail to run command:grub2-editenv [/boot/efi/EFI/openEuler/grubenv set saved_entry=A] out:grub2-editenv: error: cannot open `/boot/efi/EFI/openEuler/grubenv.new': No such file or directory.\n err:exit status 1"
Aug 24 12:28:42 node5 os-agent[1157]: time="2022-08-24T12:28:42Z" level=info msg="start to update to KubeOS EulerOS_X86_2209LTS_test_dc_2"
Aug 24 12:28:42 node5 os-agent[1157]: time="2022-08-24T12:28:42Z" level=info msg="start pull rnd-dockerhub.huawei.com/official/kubeos_euleros_x86_2209lts_test_dc_2:1.0"
Aug 24 12:28:46 node5 os-agent[1157]: time="2022-08-24T12:28:46Z" level=info msg="downloading to file /persist/update.img"
Aug 24 12:28:52 node5 os-agent[1157]: time="2022-08-24T12:28:52Z" level=info msg="/dev/sda2 mounted on "
Aug 24 12:28:52 node5 os-agent[1157]: time="2022-08-24T12:28:52Z" level=info msg="side is /dev/sda2"
Aug 24 12:29:00 node5 os-agent[1157]: time="2022-08-24T12:29:00Z" level=error msg="update error fail to run command:grub2-editenv [/boot/efi/EFI/openEuler/grubenv set saved_entry=A] out:grub2-editenv: error: cannot open `/boot/efi/EFI/openEuler/grubenv.new': No such file or directory.\n err:exit status 1"
Aug 24 12:29:00 node5 os-agent[1157]: time="2022-08-24T12:29:00Z" level=info msg="start to update to KubeOS EulerOS_X86_2209LTS_test_dc_2"
Aug 24 12:29:00 node5 os-agent[1157]: time="2022-08-24T12:29:00Z" level=info msg="start pull rnd-dockerhub.huawei.com/official/kubeos_euleros_x86_2209lts_test_dc_2:1.0"
Aug 24 12:29:04 node5 os-agent[1157]: time="2022-08-24T12:29:04Z" level=info msg="downloading to file /persist/update.img"
Aug 24 12:29:10 node5 os-agent[1157]: time="2022-08-24T12:29:10Z" level=info msg="/dev/sda2 mounted on "
Aug 24 12:29:10 node5 os-agent[1157]: time="2022-08-24T12:29:10Z" level=info msg="side is /dev/sda2"
Aug 24 12:29:17 node5 os-agent[1157]: time="2022-08-24T12:29:17Z" level=error msg="update error fail to run command:grub2-editenv [/boot/efi/EFI/openEuler/grubenv set saved_entry=A] out:grub2-editenv: error: cannot open `/boot/efi/EFI/openEuler/grubenv.new': No such file or directory.\n err:exit status 1"
Aug 24 12:29:18 node5 os-agent[1157]: time="2022-08-24T12:29:18Z" level=info msg="start to update to KubeOS EulerOS_X86_2209LTS_test_dc_2"
Aug 24 12:29:18 node5 os-agent[1157]: time="2022-08-24T12:29:18Z" level=info msg="start pull rnd-dockerhub.huawei.com/official/kubeos_euleros_x86_2209lts_test_dc_2:1.0"
Aug 24 12:29:22 node5 os-agent[1157]: time="2022-08-24T12:29:22Z" level=info msg="downloading to file /persist/update.img"
Aug 24 12:29:29 node5 os-agent[1157]: time="2022-08-24T12:29:29Z" level=info msg="/dev/sda2 mounted on "
Aug 24 12:29:29 node5 os-agent[1157]: time="2022-08-24T12:29:29Z" level=info msg="side is /dev/sda2"
```
挂载信息:
```
[root@node5 ~]# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sda 8:0 0 1.1T 0 disk
|-sda1 8:1 0 94M 0 part
|-sda2 8:2 0 2.3G 0 part
|-sda3 8:3 0 2.3G 0 part /
`-sda4 8:4 0 1.1T 0 part
sdb 8:16 0 7.3T 0 disk
|-sdb1 8:17 0 94M 0 part /boot/efi
|-sdb2 8:18 0 2.3G 0 part
|-sdb3 8:19 0 2.3G 0 part
`-sdb4 8:20 0 7.3T 0 part /var/lib/kubelet
/var/lib/docker
/var
/persist
[root@node5 ~]# mount -o remount,rw /
[root@node5 ~]# mkdir aaa
[root@node5 ~]# mount /dev/sda1 aaa
[root@node5 ~]# ll aaa
total 2
drwxr-xr-x 4 root root 2048 Aug 24 06:40 EFI
[root@node5 ~]# ll aaa/EFI/
BOOT/ openEuler/
[root@node5 ~]# ll aaa/EFI/BOOT/
total 232
-rwxr-xr-x 1 root root 237568 Aug 24 11:59 BOOTX64.EFI
-rwxr-xr-x 1 root root 237568 Aug 24 11:59 grubx64.efi
drwxr-xr-x 2 root root 22528 Aug 24 11:59 x86_64-efi
```
新值
【问题复现步骤】
物理机节点(UEFI)升级后,再次升级
【预期结果】
再次升级成功
【实际结果】
再次升级失败:
```
Aug 24 12:28:42 node5 os-agent[1157]: time="2022-08-24T12:28:42Z" level=error msg="update error fail to run command:grub2-editenv [/boot/efi/EFI/openEuler/grubenv set saved_entry=A] out:grub2-editenv: error: cannot open `/boot/efi/EFI/openEuler/grubenv.new': No such file or directory.\n err:exit status 1"
Aug 24 12:28:42 node5 os-agent[1157]: time="2022-08-24T12:28:42Z" level=info msg="start to update to KubeOS EulerOS_X86_2209LTS_test_dc_2"
Aug 24 12:28:42 node5 os-agent[1157]: time="2022-08-24T12:28:42Z" level=info msg="start pull rnd-dockerhub.huawei.com/official/kubeos_euleros_x86_2209lts_test_dc_2:1.0"
Aug 24 12:28:46 node5 os-agent[1157]: time="2022-08-24T12:28:46Z" level=info msg="downloading to file /persist/update.img"
Aug 24 12:28:52 node5 os-agent[1157]: time="2022-08-24T12:28:52Z" level=info msg="/dev/sda2 mounted on "
Aug 24 12:28:52 node5 os-agent[1157]: time="2022-08-24T12:28:52Z" level=info msg="side is /dev/sda2"
Aug 24 12:29:00 node5 os-agent[1157]: time="2022-08-24T12:29:00Z" level=error msg="update error fail to run command:grub2-editenv [/boot/efi/EFI/openEuler/grubenv set saved_entry=A] out:grub2-editenv: error: cannot open `/boot/efi/EFI/openEuler/grubenv.new': No such file or directory.\n err:exit status 1"
Aug 24 12:29:00 node5 os-agent[1157]: time="2022-08-24T12:29:00Z" level=info msg="start to update to KubeOS EulerOS_X86_2209LTS_test_dc_2"
Aug 24 12:29:00 node5 os-agent[1157]: time="2022-08-24T12:29:00Z" level=info msg="start pull rnd-dockerhub.huawei.com/official/kubeos_euleros_x86_2209lts_test_dc_2:1.0"
Aug 24 12:29:04 node5 os-agent[1157]: time="2022-08-24T12:29:04Z" level=info msg="downloading to file /persist/update.img"
Aug 24 12:29:10 node5 os-agent[1157]: time="2022-08-24T12:29:10Z" level=info msg="/dev/sda2 mounted on "
Aug 24 12:29:10 node5 os-agent[1157]: time="2022-08-24T12:29:10Z" level=info msg="side is /dev/sda2"
Aug 24 12:29:17 node5 os-agent[1157]: time="2022-08-24T12:29:17Z" level=error msg="update error fail to run command:grub2-editenv [/boot/efi/EFI/openEuler/grubenv set saved_entry=A] out:grub2-editenv: error: cannot open `/boot/efi/EFI/openEuler/grubenv.new': No such file or directory.\n err:exit status 1"
Aug 24 12:29:18 node5 os-agent[1157]: time="2022-08-24T12:29:18Z" level=info msg="start to update to KubeOS EulerOS_X86_2209LTS_test_dc_2"
Aug 24 12:29:18 node5 os-agent[1157]: time="2022-08-24T12:29:18Z" level=info msg="start pull rnd-dockerhub.huawei.com/official/kubeos_euleros_x86_2209lts_test_dc_2:1.0"
Aug 24 12:29:22 node5 os-agent[1157]: time="2022-08-24T12:29:22Z" level=info msg="downloading to file /persist/update.img"
Aug 24 12:29:29 node5 os-agent[1157]: time="2022-08-24T12:29:29Z" level=info msg="/dev/sda2 mounted on "
Aug 24 12:29:29 node5 os-agent[1157]: time="2022-08-24T12:29:29Z" level=info msg="side is /dev/sda2"
```
挂载信息:
```
[root@node5 ~]# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sda 8:0 0 1.1T 0 disk
|-sda1 8:1 0 94M 0 part
|-sda2 8:2 0 2.3G 0 part
|-sda3 8:3 0 2.3G 0 part /
`-sda4 8:4 0 1.1T 0 part
sdb 8:16 0 7.3T 0 disk
|-sdb1 8:17 0 94M 0 part /boot/efi
|-sdb2 8:18 0 2.3G 0 part
|-sdb3 8:19 0 2.3G 0 part
`-sdb4 8:20 0 7.3T 0 part /var/lib/kubelet
/var/lib/docker
/var
/persist
[root@node5 ~]# mount -o remount,rw /
[root@node5 ~]# mkdir aaa
[root@node5 ~]# mount /dev/sda1 aaa
[root@node5 ~]# ll aaa
total 2
drwxr-xr-x 4 root root 2048 Aug 24 06:40 EFI
[root@node5 ~]# ll aaa/EFI/
BOOT/ openEuler/
[root@node5 ~]# ll aaa/EFI/BOOT/
total 232
-rwxr-xr-x 1 root root 237568 Aug 24 11:59 BOOTX64.EFI