At 6:24 PM -0500 11/29/06, Jeff Johnson wrote:
On Nov 29, 2006, at 6:20 PM, seth vidal wrote:
I'm not saying yum does guarantee those. I'm asking why does the
above
cause the rpmdb to have errors?
Dunno (yet), there are likely several intersecting causes.
No matter what, yum should go back to last known good. It's easier
debugging,
and seemed to work at some point in time.
The only reason that I've heard for the open-extract-close change is
to handle
signals within yum, and that can easily be achieved in other ways.
Nasrat has
details.
If handling of Ctl-C is the main reason for yum's new repeated RPM
database
opens / closes, I have a suggestion or two.
RPM wants to catch the signals so it can be sure to close the RPM
database
properly in all cases. Yum also tries to close the RPM database
properly
in all instances. It should be enough if yum does it.
1) Yum could steal back the SIGINT handler, as I do in my
Stablemirror yum
plugin <http://georgeanelson.com/stablemirror.htm> (for FC5 yum,
not really
needed anymore with the mirrorlist improvements). It calls
signal.signal(signal.SIGINT, signal.default_int_handler)
in an override of _mirror_try() in a subclass of MirrorGroup, to
repeatedly
steal back the SIGINT signal. Yum could do the same right after
opening
the RPM database, but also in other places, as I think that RPM will
sometimes take the signals again later just to be "safe". This can
be done
now.