如何修复 12.04 中的更新管理器sudo apt-get upgrade
?它工作正常,但每次我尝试安装任何更新时都会挂起。我强烈怀疑这与我的 Python 安装有关,而不是软件中的错误。这是错误消息:
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
重新安装aptdaemon
似乎解决了问题:
sudo apt-get install --reinstall aptdaemon