Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 11306 - portage stops working if /var/cache/edb/mtimedb is corrupted
Summary: portage stops working if /var/cache/edb/mtimedb is corrupted
Status: RESOLVED INVALID
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Unclassified (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Nicholas Jones (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-11-27 11:36 UTC by Eric Thibodeau
Modified: 2011-10-30 22:21 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
The corrupted mtimedb (mtimedb.bak,68.00 KB, application/x-trash)
2002-11-27 11:37 UTC, Eric Thibodeau
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Thibodeau 2002-11-27 11:36:44 UTC
All portage components stop working if /var/cache/edb/mtimedb is corrupted. 
There should be some way to recover from this.
Comment 1 Eric Thibodeau 2002-11-27 11:37:59 UTC
Created attachment 5994 [details]
The corrupted mtimedb
Comment 2 Nicholas Jones (RETIRED) gentoo-dev 2002-11-28 11:43:13 UTC
This won't happen in a current (2.0.44) portage.
Include 'emerge info' and a traceback in your report
if upgrading doesn't fix the problem.
Comment 3 TGL 2002-12-16 10:21:45 UTC
Someting closely related I think:

Two days ago, while I was using portage-2.0.45-r? (don't remember exactly, but
I'm using ~x86 and update quite often), I had a segfault at the end of an
emerge. I then tried to re-run the command, but had some error messages from
emerge (sorry, I don't have any log, but it was pointing to code that checks
thing in the mtimedb). My first thought was to untar the emergency portage
(sorry, don't know the version, but my tree was only a few days old) to check if
it was a bug of my current version... but it raised the same error. I've then
moved away the mtimedb file, which was probably corrupted, and ask for an
"emerge -u world".
  This time, without the corrupted mtimedb, portage was able to run fine. The
first package to update was "sed"... building worked fine, then merging, then
cleaning out the old version... ouch! the newly installed "sed" program was also
removed. 
  It was really painfull for me to get back a working system, because without
"sed" you can't run a single configure script, even the sed's one... But this is
a different story, it was just very bad luck that sed was the first one to be
updated this day.

  The real problem is that if you remove your mtimedb, then portage (at least
this recovery version, which is supposed to be a safe one) can remove some just
merged files. Maybe it was a very bad idea to remove the mtimedb, or maybe I
should have run some commands to rebuild a db after having installed recovery
portage, I don't know... but their is something dangerous somewhere that portage
can probably prevent (for example: avoid cleaning files if you can't check their
date).

PS: sorry for the lack of precise version numbers, logs, etc... but my first
thought was really far from the bugreporting.
Comment 4 Nicholas Jones (RETIRED) gentoo-dev 2002-12-16 10:48:53 UTC
Sounds like you have a corrupt set of counters...

portage-2.0.46 fixes this a lot better.