Just wanted to add that I experienced this after a new install of 10.4 on a new 
box.
It has been some time since I had installed Linux and was super impressed with 
how far Ubuntu has come.

* Clicked on "Update Manager" in the admin menu, it flashed up like it was 
going to load then disappeared
* Clicked on "Software Centre" same as above
* Opened a terminal and tried "aptitude"
Segfault

As an old time Linux user, my first guess when multiple programs are
segfaulting is to assume bad hardware (I did not make the connection at
this time that all of the programs were related to package management).
I spent the next several hours running memory tests, disk tests and
googling without a solution. I ran more tests from the Live CD and
noticed that I was not getting any segfaults. So I booted in recovery
mode from the hard drive and ran:

"apt-get upgrade" 
output:
Reading package lists... Done
Segmentation faulty tree... 50%

Googling for this error yielded the following thread which provided me the 
solution:
http://ubuntuforums.org/showthread.php?t=803215

"sudo rm /var/cache/apt/*.bin"

After executing this delete I was able to finally run apt-get upgrade
successfully.

Then If found this bug report, and was surprised that it has existed for 4 
years through several Ubuntu releases.
I don't consider hand deleting the cache to be an acceptable work-around.

The box I was building was for someone who is not a Linux user and has
no technical skills. It scares me that the cache could get corrupted
(during install!) and the user has no recourse, since they are unable to
update software.

Could this condition (unable to read apt cache binary files) on file open be 
caught and handled effectively?
- Error message to the user saying that something was wrong with the 
"temporary" files in the package manager and have them click through delete 
step; or
- Simply clearing the offending cache without telling the user; or at least
- A better error message with instructions on how to get help

hope this helps

-- 
apt segfaults if /var/cache/apt/srcpkgcache.bin is wrong
https://bugs.launchpad.net/bugs/57393
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to