由於 ZFS,Ubuntu 22.04 升級到 linux-image-5.15.0-53-generic 失敗

由於 ZFS,Ubuntu 22.04 升級到 linux-image-5.15.0-53-generic 失敗

當我嘗試在 22.04(系統 76)筆記型電腦上升級到最新核心映像時,從 tmp 卸載似乎是 ZFS 磁碟區的磁碟區時出現錯誤:

$  sudo apt upgrade
[sudo] password for rotten:
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
The following packages were automatically installed and are no longer required:
  libflashrom1 libftdi1-2 linux-headers-5.15.0-48
  linux-headers-5.15.0-48-generic linux-image-5.15.0-48-generic
  linux-modules-5.15.0-48-generic linux-modules-extra-5.15.0-48-generic
  python3-charset-normalizer python3-defusedxml python3-pygments
  python3-requests-toolbelt
Use 'sudo apt autoremove' to remove them.
#
# News about significant security updates, features and services will
# appear here to raise awareness and perhaps tease /r/Linux ;)
# Use 'pro config set apt_news=false' to hide this and future APT news.
#
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up linux-image-5.15.0-53-generic (5.15.0-53.59) ...
Processing triggers for linux-image-5.15.0-53-generic (5.15.0-53.59) ...
/etc/kernel/postinst.d/dkms:
 * dkms: running auto installation service for kernel 5.15.0-53-generic
   ...done.
/etc/kernel/postinst.d/initramfs-tools:
update-initramfs: Generating /boot/initrd.img-5.15.0-53-generic
W: Possible missing firmware /lib/firmware/amdgpu/yellow_carp_gpu_info.bin for module amdgpu
W: Possible missing firmware /lib/firmware/amdgpu/vangogh_gpu_info.bin for module amdgpu..........................................................................W: Possible missing firmware /lib/firmware/amdgpu/cyan_skillfish_rlc.bin for module amdgpu........................................................................W: Possible missing firmware /lib/firmware/amdgpu/cyan_skillfish_mec2.bin for module amdgpu
W: Possible missing firmware /lib/firmware/amdgpu/cyan_skillfish_mec.bin for module amdgpu
W: Possible missing firmware /lib/firmware/amdgpu/cyan_skillfish_me.bin for module amdgpu
W: Possible missing firmware /lib/firmware/amdgpu/cyan_skillfish_pfp.bin for module amdgpu
W: Possible missing firmware /lib/firmware/amdgpu/cyan_skillfish_ce.bin for module amdgpu
W: Possible missing firmware /lib/firmware/amdgpu/cyan_skillfish_sdma1.bin for module amdgpu
W: Possible missing firmware /lib/firmware/amdgpu/cyan_skillfish_sdma.bin for module amdgpu
W: Possible missing firmware /lib/firmware/amdgpu/sienna_cichlid_mes.bin for module amdgpu
W: Possible missing firmware /lib/firmware/amdgpu/navi10_mes.bin for module amdgpu
/etc/kernel/postinst.d/zz-update-grub:
Sourcing file `/etc/default/grub'
Sourcing file `/etc/default/grub.d/init-select.cfg'
Generating grub configuration file ...
Found linux image: vmlinuz-5.15.0-53-generic in rpool/ROOT/ubuntu_4nnk71
Found initrd image: initrd.img-5.15.0-53-generic in rpool/ROOT/ubuntu_4nnk71
Found linux image: vmlinuz-5.15.0-52-generic in rpool/ROOT/ubuntu_4nnk71
Found initrd image: initrd.img-5.15.0-52-generic in rpool/ROOT/ubuntu_4nnk71
Found linux image: vmlinuz-5.15.0-48-generic in rpool/ROOT/ubuntu_4nnk71
Found initrd image: initrd.img-5.15.0-48-generic in rpool/ROOT/ubuntu_4nnk71
umount: /tmp/zfsmnt.IHNzvH: target is busy.
umount: /tmp/zfsmnt.IHNzvH: target is busy.
rmdir: failed to remove '/tmp/zfsmnt.IHNzvH': Device or resource busy
run-parts: /etc/kernel/postinst.d/zz-update-grub exited with return code 1
dpkg: error processing package linux-image-5.15.0-53-generic (--configure):
 installed linux-image-5.15.0-53-generic package post-installation script subprocess returned error exit status 1
Errors were encountered while processing:
 linux-image-5.15.0-53-generic
E: Sub-process /usr/bin/dpkg returned an error code (1)

掛載點:

$  mount | grep zfsmnt.IHNzvH
rpool/ROOT/ubuntu_4nnk71 on /tmp/zfsmnt.IHNzvH type zfs (rw,noatime,xattr,posixacl)

我確實啟用了加密,如果這很重要的話。

目前我的筆記型電腦重新啟動乾淨,沒有其他問題。我只是堅持升級到最新的圖像。

我認為 amdgpu 警告是轉移注意力,可以忽略。

答案1

我的錯誤訊息基本上與你相同。失敗的安裝部分也可以apt upgrade透過 複製到進程之外sudo update-grub

我們認為它可能與最近安裝的 sophos 防毒軟體有關,因此透過 停用sudo systemctl stop sophos-spl.service。此後就sudo update-grub成功了。由於我們一直在嘗試其他命令來手動刪除舊的核心映像等,所以我們這樣做了sudo apt-get dist-upgradesudo apt --fix-broken install這讓系統回到了一個愉快的地方。

相關內容