Ubuntu 22.04 apt-upgrade 失败(libperl5.34、perl5、perl-base_5.34.0 dpkg 错误)

Ubuntu 22.04 apt-upgrade 失败(libperl5.34、perl5、perl-base_5.34.0 dpkg 错误)

我正在使用 Ubuntu Desktop 22.04,现在无法升级。错误如下:

**$ sudo apt upgrade**
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  grub-common grub-pc grub-pc-bin grub2-common
The following packages will be upgraded:
  avahi-autoipd avahi-daemon avahi-utils cups cups-bsd cups-client cups-common cups-core-drivers cups-daemon cups-ipp-utils cups-ppdc cups-server-common fonts-opensymbol google-chrome-stable iptables libavahi-client3 libavahi-common-data libavahi-common3 libavahi-core7
  libavahi-glib1 libavahi-ui-gtk3-0 libcups2 libcupsimage2 libip4tc2 libip6tc2 libperl5.34 libpython3.10 libpython3.10-dev libpython3.10-minimal libpython3.10-stdlib libraw20 libreoffice-avmedia-backend-gstreamer libreoffice-base-core libreoffice-calc libreoffice-common
  libreoffice-core libreoffice-draw libreoffice-gnome libreoffice-gtk3 libreoffice-help-common libreoffice-help-en-us libreoffice-impress libreoffice-math libreoffice-ogltrans libreoffice-pdfimport libreoffice-style-breeze libreoffice-style-colibre
  libreoffice-style-elementary libreoffice-style-yaru libreoffice-writer libssh-4 libssh-gcrypt-4 libuno-cppu3 libuno-cppuhelpergcc3-3 libuno-purpenvhelpergcc3-3 libuno-sal3 libuno-salhelpergcc3-3 libxtables12 perl perl-base perl-modules-5.34 python3-uno python3.10
  python3.10-dev python3.10-minimal python3.10-venv tzdata uno-libs-private ure
69 upgraded, 0 newly installed, 0 to remove and 4 not upgraded.
63 standard LTS security updates
Need to get 0 B/233 MB of archives.
After this operation, 47,1 kB disk space will be freed.
Do you want to continue? [Y/n] 
Extracting templates from packages: 100%
Preconfiguring packages ...
dpkg (subprocess): unable to execute package control information extraction (dpkg-deb): Input/output error
dpkg: error processing archive /var/cache/apt/archives/libperl5.34_5.34.0-3ubuntu1.2_amd64.deb (--unpack):
 dpkg-deb --control subprocess returned error exit status 2
dpkg (subprocess): unable to execute package control information extraction (dpkg-deb): Input/output error
dpkg: error processing archive /var/cache/apt/archives/perl_5.34.0-3ubuntu1.2_amd64.deb (--unpack):
 dpkg-deb --control subprocess returned error exit status 2
dpkg (subprocess): unable to execute package control information extraction (dpkg-deb): Input/output error
dpkg: error processing archive /var/cache/apt/archives/perl-base_5.34.0-3ubuntu1.2_amd64.deb (--unpack):
 dpkg-deb --control subprocess returned error exit status 2
Errors were encountered while processing:
 /var/cache/apt/archives/libperl5.34_5.34.0-3ubuntu1.2_amd64.deb
 /var/cache/apt/archives/perl_5.34.0-3ubuntu1.2_amd64.deb
 /var/cache/apt/archives/perl-base_5.34.0-3ubuntu1.2_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

答案1

Input/output error是关键信息。

您的存储设备工作不正常。

了解如何在存储设备上运行 SMART 测试以验证其是否出现故障或有故障。

如果 SMART 测试失败,则更换故障/即将报废的存储设备。是的,这是一件痛苦的事情。

您的存储设备也可能没有问题,并且通过了 SMART 测试,但只是有一些坏块。所有存储设备都会随着时间的推移积累坏块。了解如何使用badblocks标记这些坏块,使其不进入您的系统。

相关内容