尝试安装 python3-samba 时出现“dpkg:错误处理存档”

尝试安装 python3-samba 时出现“dpkg:错误处理存档”

我对 Linux 和计算机的总体理解还处于早期阶段。我有一个 Raspberry Pi 3,我正在尝试安装 python3-samba,但遇到了一些错误,我不太确定如何修复。此外,我在 Google 和 stack Exchange 上进行了搜索,但似乎没有任何效果。这是终端中的输出:

pi@raspberrypi:/ $ sudo apt-get -f install
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
  attr libfuse2 liburing1 tdb-tools
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  python3-samba
The following NEW packages will be installed:
  python3-samba
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
12 not fully installed or removed.
Need to get 2,319 kB of archives.
After this operation, 18.3 MB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf python3-samba armhf 2:4.13.13+dfsg-1~deb11u5 [2,319 kB]
Fetched 2,319 kB in 1s (1,984 kB/s) 
Traceback (most recent call last):
  File "/usr/bin/apt-listchanges", line 29, in <module>
    import apt_pkg
ImportError: /usr/lib/python3/dist-packages/apt_pkg.cpython-39-arm-linux-gnueabihf.so: invalid ELF header
(Reading database ... 107133 files and directories currently installed.)
Preparing to unpack .../python3-samba_2%3a4.13.13+dfsg-1~deb11u5_armhf.deb ...
Unpacking python3-samba (2:4.13.13+dfsg-1~deb11u5) ...
dpkg: error processing archive /var/cache/apt/archives/python3-samba_2%3a4.13.13+dfsg-1~deb11u5_armhf.deb (--unpack):
 unable to stat './usr/share/lintian/overrides/python3-samba' (which was about to be installed): Bad message
Errors were encountered while processing:
 /var/cache/apt/archives/python3-samba_2%3a4.13.13+dfsg-1~deb11u5_armhf.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

我只是想知道如果有人有时间的话是否可以为我指出正确的方向。谢谢。

我尝试安装使用 Raspberry Pi 创建 NAS 的教程中的一些程序,但有一个程序由于错误而无法安装。我原以为它会安装,但没有。

相关内容