欢迎访问我的网站,希望内容对您有用,感兴趣的可以加入免费知识星球。

ubuntu 16.04 apt-get update报错appstreamcli?

Linux 迷途小书童 3年前 (2021-07-12) 1893次浏览 0个评论

环境

  • ubuntu 16.04 64位

前言

今天在折腾一台老机器时,碰到了一个问题,本文记录一下。

操作系统是 ubuntu 16.04,很老的系统了,在进行 apt-get update 的时候报错了

Aborted (core dumped)
Reading package lists... Done
E: Problem executing scripts APT::Update::Post-Invoke-Success 
 'if /usr/bin/test -w /var/cache/app-info -a -e /usr/bin/appstreamcli; 
 then appstreamcli refresh > /dev/null; fi'
E: Sub-process returned an error code

ubuntu appstreamcli

解决方法一

卸载软件包 libappstream3

sudo apt-get purge libappstream3

然后重新执行

sudo apt-get update

解决方法二

如果不想删除,或者害怕这个包在其它地方被使用,我们可以这样

sudo mv /etc/apt/apt.conf.d/50appstream /etc/apt/apt.conf.d/50appstream.disable

然后重新执行

sudo apt-get update

参考资料

喜欢 (0)

您必须 登录 才能发表评论!