Ubuntu 12.04 中的更新管理器每次都会冻结

Ubuntu 12.04 中的更新管理器每次都会冻结

当。。。的时候安装更新在更新管理器中按下按钮,更新管理器冻结。

解释该问题的屏幕截图

更新和升级并未解决问题。

我收到以下错误信息:

Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/defer/__init__.py", line 475, in _inline_callbacks
    result = gen.send(result)
  File "/usr/lib/python2.7/dist-packages/aptdaemon/client.py", line 1622, in _run_transaction_helper
    daemon = get_aptdaemon(self.bus)
  File "/usr/lib/python2.7/dist-packages/aptdaemon/client.py", line 1696, in get_aptdaemon
    False),
  File "/usr/lib/python2.7/dist-packages/dbus/bus.py", line 241, in get_object
    follow_name_owner_changes=follow_name_owner_changes)
  File "/usr/lib/python2.7/dist-packages/dbus/proxies.py", line 248, in __init__
    self._named_service = conn.activate_name_owner(bus_name)
  File "/usr/lib/python2.7/dist-packages/dbus/bus.py", line 180, in activate_name_owner
    self.start_service_by_name(bus_name)
  File "/usr/lib/python2.7/dist-packages/dbus/bus.py", line 278, in start_service_by_name
    'su', (bus_name, flags)))
  File "/usr/lib/python2.7/dist-packages/dbus/connection.py", line 651, in call_blocking
    message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.Spawn.ChildExited: Launch helper exited with unknown return code 1
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/defer/__init__.py", line 475, in _inline_callbacks
    result = gen.send(result)
  File "/usr/lib/python2.7/dist-packages/aptdaemon/client.py", line 1622, in _run_transaction_helper
    daemon = get_aptdaemon(self.bus)
  File "/usr/lib/python2.7/dist-packages/aptdaemon/client.py", line 1696, in get_aptdaemon
    False),
  File "/usr/lib/python2.7/dist-packages/dbus/bus.py", line 241, in get_object
    follow_name_owner_changes=follow_name_owner_changes)
  File "/usr/lib/python2.7/dist-packages/dbus/proxies.py", line 248, in __init__
    self._named_service = conn.activate_name_owner(bus_name)
  File "/usr/lib/python2.7/dist-packages/dbus/bus.py", line 180, in activate_name_owner
    self.start_service_by_name(bus_name)
  File "/usr/lib/python2.7/dist-packages/dbus/bus.py", line 278, in start_service_by_name
    'su', (bus_name, flags)))
  File "/usr/lib/python2.7/dist-packages/dbus/connection.py", line 651, in call_blocking
    message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.Spawn.ChildExited: Launch helper exited with unknown return code 1
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.Spawn.ChildExited: Launch helper exited with unknown return code 1
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/defer/__init__.py", line 473, in _inline_callbacks
    result = gen.throw(result.type, result.value, result.traceback)
  File "/usr/lib/python2.7/dist-packages/UpdateManager/backend/InstallBackendAptdaemon.py", line 52, in commit
    downgrade, defer=True)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.Spawn.ChildExited: Launch helper exited with unknown return code 1

答案1

你的 python 包中的权限可能不起作用,请使用以下命令更改其权限-

sudo chown -R $USER /usr/local/lib/python2.7/dist-packages/

-用你的登录名替换 USER,如果不起作用,请检查输出 -

/usr/lib/ubuntu-sso-client/ubuntu-sso-login

如果它抛出任何错误ImportError: No module named pkg_resources

那么这背后的原因可能是我的 Python 环境中的安装工具包已被删除。要解决这个问题,请使用以下脚本-

curl https://bitbucket.org/pypa/setuptools/raw/bootstrap/ez_setup.py | python

希望它能够起作用。

答案2

尝试运行以下命令作为替代:

sudo apt-get update
sudo apt-get upgrade

这将为您运行更新,也许运行更新后您的更新管理器就会起作用。

相关内容