Update Manager broken

Asked by Jan Schaafsma

I downloaded the update packages offered on 3 Dec 2007 with Update Manager (Gutsy Gibbon). Now Update Manager doesn't load. The error messages read:

E: Problem parsing dependency Replaces
E: Error occurred while processing kexi (NewVersion1)
E: Problem with MergeList /var/lib/apt/lists/za.archive.ubuntu.com_ubuntu_dists_gutsy-updates_main_binary-1386_Packages
E: The package lists or status file could not be parsed or opened
E: _cache->open () failed, please report.

Should I uninstall the newly installed packages?

If so which ones, and how?

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
repley
Solved:
Last query:
Last reply:
Revision history for this message
Ricardo Cropalato de Melo (ricardo-cropalato) said :
#1

what happend when you run; "sudo aptitude update; sudo aptitude upgrade"?

Revision history for this message
Jan Schaafsma (jaschaaf) said :
#2

Those commands return the same error messages.

Ricardo Cropalato de Melo wrote:
> Your question #19383 on Ubuntu changed:
> https://answers.edge.launchpad.net/ubuntu/+question/19383
>
> Status: Open => Needs information
>
> Ricardo Cropalato de Melo requested for more information:
> what happend when you run; "sudo aptitude update; sudo aptitude
> upgrade"?
>
>

Revision history for this message
Ricardo Cropalato de Melo (ricardo-cropalato) said :
#3

try "sudo dpkg-reconfigure -a"

Revision history for this message
Jan Schaafsma (jaschaaf) said :
#4

Wow! This involves reconfiguring the kernel, not so? This is a
complicated process, and I don't think I have the nerve for all of that ...

Ricardo Cropalato de Melo wrote:
> Your question #19383 on Ubuntu changed:
> https://answers.edge.launchpad.net/ubuntu/+question/19383
>
> Status: Open => Answered
>
> Ricardo Cropalato de Melo proposed the following answer:
> try "sudo dpkg-reconfigure -a"
>
>

Revision history for this message
Ricardo Cropalato de Melo (ricardo-cropalato) said :
#5

be strong. :-D

it's not so hard. You can do it.

Use the default answers.

Revision history for this message
Jan Schaafsma (jaschaaf) said :
#6

Thanks - I'll give it a go when I have the time (I am a freelance
translator with impossible deadlines to meet, and I need to finish my
day's work before I can spend time on other things).

Ricardo Cropalato de Melo wrote:
> Your question #19383 on Ubuntu changed:
> https://answers.edge.launchpad.net/ubuntu/+question/19383
>
> Status: Open => Answered
>
> Ricardo Cropalato de Melo proposed the following answer:
> be strong. :-D
>
> it's not so hard. You can do it.
>
> Use the default answers.
>
>

Revision history for this message
Olivier (olivier-lacroix) said :
#7

Hi !

I do not this you have to run the proposed command : I would take a loooooong time anyway. from the error you describe, There may have be a problem when downloading package information.

delete what is in /var/lib/apt/lists/. ie enter in a terminal

cd /var/lib/apt/lists/
sudo rm *
sudo apt-get update

and see if you still have a problem

Revision history for this message
Olivier (olivier-lacroix) said :
#8

Sorry for the typos above...

Revision history for this message
Jan Schaafsma (jaschaaf) said :
#9

Thanks - there has been some progress, in that the error message has
disappeared from the Update Manager starburst icon. I was also able to
download and install 45 updates from this icon.

However, I still can't get Add/Remove Programs to load from the
Applications menu (and neither an associated program like Software
Sources from the System > Administration menu). Now that the updates
from the Update Manager icon have been completed (and the icon itself
has disappeared at top right on the screen), I can't get Update Manager
to load from the System > Administration Menu either. The Synaptic
Package Manager does load.

As a further clue I should mention that just after downloading the
updates that seem to have caused all the trouble, I also had problems
with the Search applet on booting. This showed a window with the option
of deleting it, which I did.

Hope this helps.

Olivier wrote:
> Your question #19383 on Ubuntu changed:
> https://answers.launchpad.net/ubuntu/+question/19383
>
> Status: Open => Answered
>
> Olivier proposed the following answer:
> Hi !
>
> I do not this you have to run the proposed command : I would take a
> loooooong time anyway. from the error you describe, There may have be a
> problem when downloading package information.
>
> delete what is in /var/lib/apt/lists/. ie enter in a terminal
>
> cd /var/lib/apt/lists/
> sudo rm *
> sudo apt-get update
>
> and see if you still have a problem
>
>

Revision history for this message
Olivier (olivier-lacroix) said :
#10

that is really weird....

to know what is happening,

search for the command associated with the programs that fail to launch. to do that, right click on the "Application menu" and choose edit. browse the menu editor to find the right launcher and the associated command. copy&paste this command in a terminal and report here the errors

Revision history for this message
Jan Schaafsma (jaschaaf) said :
#11

Error report for Software Sources:

jan@Jan:~$ gksu --desktop
/usr/share/applications/software-properties.desktop
/usr/bin/software-properties-gtk
  File "/usr/bin/software-properties-gtk", line 44, in <module>
    from softwareproperties.gtk.SoftwarePropertiesGtk import
SoftwarePropertiesGtk
  File
"/usr/lib/python2.5/site-packages/softwareproperties/gtk/SoftwarePropertiesGtk.py",
line 25, in <module>
    import apt
ImportError: No module named apt
Error in sys.excepthook:
Traceback (most recent call last):
  File "/var/lib/python-support/python2.5/apport_python_hook.py", line
38, in apport_excepthook
    from apport.fileutils import likely_packaged
  File "/var/lib/python-support/python2.5/apport/__init__.py", line 1,
in <module>
    from apport.report import Report
  File "/var/lib/python-support/python2.5/apport/report.py", line 20, in
<module>
    from problem_report import ProblemReport
  File "/var/lib/python-support/python2.5/problem_report.py", line 15,
in <module>
    import zlib, base64, time, UserDict, sys, gzip, struct
ImportError: No module named base64

Original exception was:
Traceback (most recent call last):
  File "/usr/bin/software-properties-gtk", line 44, in <module>
    from softwareproperties.gtk.SoftwarePropertiesGtk import
SoftwarePropertiesGtk
  File
"/usr/lib/python2.5/site-packages/softwareproperties/gtk/SoftwarePropertiesGtk.py",
line 25, in <module>
    import apt
ImportError: No module named apt

--------------------------------------------------------------------------------------------------------

Error report for Add/Remove Programs:

jan@Jan:~$ /usr/bin/gnome-app-install
Traceback (most recent call last):
  File "/usr/bin/gnome-app-install", line 30, in <module>
    main()
  File "/usr/lib/python2.5/site-packages/AppInstall/activation.py", line
435, in main
    from AppInstall import AppInstall
  File "/usr/lib/python2.5/site-packages/AppInstall/AppInstall.py", line
50, in <module>
    from widgets.AppListView import AppListView
  File
"/usr/lib/python2.5/site-packages/AppInstall/widgets/AppListView.py",
line 9, in <module>
    from xml.sax.saxutils import escape
  File "/usr/lib/python2.5/site-packages/_xmlplus/sax/saxutils.py", line
8, in <module>
    import os, urlparse, urllib2, types
  File "/usr/lib/python2.5/urllib2.py", line 90, in <module>
    import base64
ImportError: No module named base64
Error in sys.excepthook:
Traceback (most recent call last):
  File "/var/lib/python-support/python2.5/apport_python_hook.py", line
38, in apport_excepthook
    from apport.fileutils import likely_packaged
  File "/var/lib/python-support/python2.5/apport/__init__.py", line 1,
in <module>
    from apport.report import Report
  File "/var/lib/python-support/python2.5/apport/report.py", line 20, in
<module>
    from problem_report import ProblemReport
  File "/var/lib/python-support/python2.5/problem_report.py", line 15,
in <module>
    import zlib, base64, time, UserDict, sys, gzip, struct
ImportError: No module named base64

Original exception was:
Traceback (most recent call last):
  File "/usr/bin/gnome-app-install", line 30, in <module>
    main()
  File "/usr/lib/python2.5/site-packages/AppInstall/activation.py", line
435, in main
    from AppInstall import AppInstall
  File "/usr/lib/python2.5/site-packages/AppInstall/AppInstall.py", line
50, in <module>
    from widgets.AppListView import AppListView
  File
"/usr/lib/python2.5/site-packages/AppInstall/widgets/AppListView.py",
line 9, in <module>
    from xml.sax.saxutils import escape
  File "/usr/lib/python2.5/site-packages/_xmlplus/sax/saxutils.py", line
8, in <module>
    import os, urlparse, urllib2, types
  File "/usr/lib/python2.5/urllib2.py", line 90, in <module>
    import base64
ImportError: No module named base64

-----------------------------------------------------------------------------------------------------------------------------------------------

Error report for Update Manager

jan@Jan:~$ /usr/bin/update-manager
Traceback (most recent call last):
  File "/usr/bin/update-manager", line 32, in <module>
    from UpdateManager.UpdateManager import UpdateManager
  File
"/usr/lib/python2.5/site-packages/UpdateManager/UpdateManager.py", line
38, in <module>
    import apt
ImportError: No module named apt
Error in sys.excepthook:
Traceback (most recent call last):
  File "/var/lib/python-support/python2.5/apport_python_hook.py", line
38, in apport_excepthook
    from apport.fileutils import likely_packaged
  File "/var/lib/python-support/python2.5/apport/__init__.py", line 1,
in <module>
    from apport.report import Report
  File "/var/lib/python-support/python2.5/apport/report.py", line 20, in
<module>
    from problem_report import ProblemReport
  File "/var/lib/python-support/python2.5/problem_report.py", line 15,
in <module>
    import zlib, base64, time, UserDict, sys, gzip, struct
ImportError: No module named base64

Original exception was:
Traceback (most recent call last):
  File "/usr/bin/update-manager", line 32, in <module>
    from UpdateManager.UpdateManager import UpdateManager
  File
"/usr/lib/python2.5/site-packages/UpdateManager/UpdateManager.py", line
38, in <module>
    import apt
ImportError: No module named apt

Olivier wrote:
> Your question #19383 on Ubuntu changed:
> https://answers.launchpad.net/ubuntu/+question/19383
>
> Status: Open => Answered
>
> Olivier proposed the following answer:
> that is really weird....
>
> to know what is happening,
>
> search for the command associated with the programs that fail to launch.
> to do that, right click on the "Application menu" and choose edit.
> browse the menu editor to find the right launcher and the associated
> command. copy&paste this command in a terminal and report here the
> errors
>
>

Revision history for this message
Jan Schaafsma (jaschaaf) said :
#12

Hi

I sent error reports for Software Sources; Add/Remove...; and Update
Manager.

Since then I re-installed the deskbar-applet 2.20.0 (which seems to have
caused the problem in the first place). When I tried to add it to the
Panel, the Bug Buddy window popped up again and showed a report which
also alluded to base64 not being available. See that report below.

-------------------------------------------------------------------------------------------------------------------------------

Distribution: Ubuntu 7.10 (gutsy)
Gnome Release: 2.20.1 2007-10-19 (Ubuntu)
BugBuddy Version: 2.18.1

System: Linux 2.6.22-14-generic #1 SMP Sun Oct 14 23:05:12 GMT 2007 i686
X Vendor: The X.Org Foundation
X Vendor Release: 10300000
Selinux: No
Accessibility: Disabled
GTK+ Theme: Glider
Icon Theme: gnome

Memory status: size: 0 vsize: 0 resident: 0 share: 0 rss: 0 rss_rlim: 0
CPU usage: start_time: 0 rtime: 0 utime: 0 stime: 0 cutime:0 cstime: 0
timeout: 0 it_real_value: 0 frequency: 0

----------- .xsession-errors (310 sec old) ---------------------
Original exception was:
Traceback (most recent call last):
  File "/usr/bin/gnome-app-install", line 30, in <module>
    main()
  File "/usr/lib/python2.5/site-packages/AppInstall/activation.py", line
435, in main
    from AppInstall import AppInstall
  File "/usr/lib/python2.5/site-packages/AppInstall/AppInstall.py", line
50, in <module>
    from widgets.AppListView import AppListView
  File
"/usr/lib/python2.5/site-packages/AppInstall/widgets/AppListView.py",
line 9, in <module>
    from xml.sax.saxutils import escape
  File "/usr/lib/python2.5/site-packages/_xmlplus/sax/saxutils.py", line
8, in <module>
    import os, urlparse, urllib2, types
  File "/usr/lib/python2.5/urllib2.py", line 90, in <module>
    import base64
ImportError: No module named base64
--------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/deskbar-applet/deskbar-applet", line 50, in <module>
    from deskbar.ui.DeskbarApplet import DeskbarApplet
  File "/usr/lib/python2.5/site-packages/deskbar/ui/DeskbarApplet.py",
line 9, in <module>
    from deskbar.ui.CuemiacWindowController import CuemiacWindowController
  File
"/usr/lib/python2.5/site-packages/deskbar/ui/CuemiacWindowController.py",
line 7, in <module>
    from deskbar.ui.preferences.DeskbarPreferences import DeskbarPreferences
  File
"/usr/lib/python2.5/site-packages/deskbar/ui/preferences/DeskbarPreferences.py",
line 8, in <module>
    from deskbar.core.updater.NewStuffUpdater import NewStuffUpdater
  File
"/usr/lib/python2.5/site-packages/deskbar/core/updater/NewStuffUpdater.py",
line 2, in <module>
    import dbus
  File "/var/lib/python-support/python2.5/dbus/__init__.py", line 96, in
<module>
    from dbus._dbus import Bus, SystemBus, SessionBus, StarterBus
  File "/var/lib/python-support/python2.5/dbus/_dbus.py", line 24, in
<module>
    from __future__ import generators
ImportError: No module named __future__

-----------------------------------------------------------------------------------

Any ideas about how to get my Add/Remove...; Software Sources; and
Update Manager back again?

Where do I get "apt", "base64"; and "_future_" so that these programmes
(including the deskbar-applet) can import them?

Olivier wrote:
> Your question #19383 on Ubuntu changed:
> https://answers.launchpad.net/ubuntu/+question/19383
>
> Status: Open => Answered
>
> Olivier proposed the following answer:
> that is really weird....
>
> to know what is happening,
>
> search for the command associated with the programs that fail to launch.
> to do that, right click on the "Application menu" and choose edit.
> browse the menu editor to find the right launcher and the associated
> command. copy&paste this command in a terminal and report here the
> errors
>
>

Revision history for this message
Olivier (olivier-lacroix) said :
#13

Try to enter in a terminal

sudo apt-get install --reinstall python2.5

Tell me if that helps

Revision history for this message
Best repley (repley) said :
#14

Probably you have changed /usr/bin/python link from 2.5 to 2.4, try:

sudo ln -sf /usr/bin/python2.5 /usr/bin/python

I had the same problem

Revision history for this message
Jan Schaafsma (jaschaaf) said :
#15

I have in the meantime bought a new computer and re-installed Ubuntu, so the problem no longer exists.

Revision history for this message
Jan Schaafsma (jaschaaf) said :
#16

Thank you for your effort, which I appreciate very much.

I have in the menatime bought a new computer and have re-installed
Ubuntu, so the problem no longer exists.

repley wrote:
> Your question #19383 on Ubuntu changed:
> https://answers.launchpad.net/ubuntu/+question/19383
>
> repley proposed the following answer:
> Probably you have changed /usr/bin/python link from 2.5 to 2.4, try:
>
> sudo ln -sf /usr/bin/python2.5 /usr/bin/python
>
> I had the same problem
>
>

Revision history for this message
Philipp Kewisch (kewisch) said :
#17

I had this problem on one box too. I solved it by temporarily making the default version 2.4. This can be done in

/usr/share/python/debian_defaults

I also needed to change the first line of the update script that was extracted into /tmp/tmp123123/hardy from python2.5 to python or python2.4

Note it is probably not recommended to change the default python version.

Revision history for this message
Jan Schaafsma (jaschaaf) said :
#18

Thanks a lot. I have, however, upgraded to a new box, so the question no
longer applies. Bit it is heartening to know there is such a dedicated
and concerned community out there willing to give their time to solve
problems like this.

Fallen wrote:
> Your question #19383 on Ubuntu changed:
> https://answers.launchpad.net/ubuntu/+question/19383
>
> Fallen posted a new comment:
> I had this problem on one box too. I solved it by temporarily making the
> default version 2.4. This can be done in
>
> /usr/share/python/debian_defaults
>
> I also needed to change the first line of the update script that was
> extracted into /tmp/tmp123123/hardy from python2.5 to python or
> python2.4
>
> Note it is probably not recommended to change the default python
> version.
>
>