Archlinux 滚动升级失败的解决办法

当我使用sudo pacman -Syu进行滚动升级时,显示错误如下:

error: failed to commit transaction (conflicting files)
python2-setuptools: /usr/lib/python2.7/site-packages/pkg_resources/__init__.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/__init__.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/archive_util.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/__init__.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/bdist_egg.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/bdist_wininst.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/build_py.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/easy_install.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/egg_info.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/install.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/install_egg_info.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/install_lib.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/install_scripts.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/py36compat.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/sdist.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/command/setopt.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/depends.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/dist.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/extension.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/glob.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/lib2to3_ex.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/monkey.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/msvc.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/namespaces.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/package_index.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/py26compat.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/py27compat.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/py31compat.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/sandbox.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/ssl_support.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/unicode_utils.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/version.pyc exists in filesystem
python2-setuptools: /usr/lib/python2.7/site-packages/setuptools/windows_support.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/appdirs.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/appdirs.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/distro.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/distro.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_ihatexml.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_ihatexml.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_inputstream.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_inputstream.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_tokenizer.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_tokenizer.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_trie/__init__.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_trie/__init__.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_trie/_base.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_trie/_base.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_trie/datrie.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_trie/datrie.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_trie/py.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_trie/py.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_utils.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/_utils.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/filters/base.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/filters/base.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/serializer.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/serializer.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treeadapters/genshi.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treeadapters/genshi.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treebuilders/base.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treebuilders/base.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treewalkers/base.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treewalkers/base.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treewalkers/etree_lxml.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treewalkers/etree_lxml.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treewalkers/genshi.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/html5lib/treewalkers/genshi.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/ordereddict.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/ordereddict.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/__init__.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/__init__.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/labels.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/labels.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/mklabels.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/mklabels.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/tests.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/tests.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/x_user_defined.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/_vendor/webencodings/x_user_defined.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/commands/check.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/commands/check.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/operations/check.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/operations/check.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/utils/glibc.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/utils/glibc.pyc exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/utils/packaging.py exists in filesystem
python2-pip: /usr/lib/python2.7/site-packages/pip/utils/packaging.pyc exists in filesystem
Errors occurred, no packages were upgraded.

解决方案是:

sudo pacman -S python2-setuptools --force
sudo pacman -S python2-pip --force

这样之后就好了

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值