问题一:

通过sudo命令更新文件时,dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

报如下的错误:

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

原因:

需删除目录/var/lib/dpkg下的文件夹lock和updates

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

解决办法:

1、通过rm -rf命令删除这两个文件夹

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

 

2、sudo apt clean:清除apt缓存

3、sudo apt update:再次更新程序

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

 

问题二:但是此时重新执行命令会报以下的错误

cannot scan updates directory '/var/lib/dpkg/updates/': No such file or directory

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

 

解决办法:

依次执行以下命令

1、sudo mkdir -p /var/lib/dpkg/updates

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

 

2、sudo mkdir -p /var/lib/dpkg/updates

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

 

3、sudo apt-get purge wine1.4 ia32-libs-multiarch

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

4、sudo apt-get upgrade

dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

相关文章:

  • 2021-12-20
  • 2022-12-23
  • 2022-12-23
  • 2021-10-15
  • 2021-04-29
  • 2022-12-23
  • 2021-10-02
猜你喜欢
  • 2021-06-07
  • 2021-07-22
  • 2021-07-14
  • 2022-12-23
  • 2022-03-02
  • 2022-02-09
相关资源
相似解决方案