[Yum] Re: [PATCH] metadata cache expiration fix (seth vidal)
Steve Magoun
steve at pepper.com
Tue Aug 22 17:50:15 UTC 2006
On Aug 20, 2006, at 12:00 PM, yum-request at lists.dulug.duke.edu wrote:
> I ended up doing something similar in cvs head.
>
> Specifically, I added a check. If the ctime of the cooking file was
> greater than the current time then assume the metadata needs updating.
>
> oh and ntp or rdate is your friend.
Thanks for the update on this. A minor nit: shouldn't you check
ctime>=now rather than ctime>now? My assumption is the two values
could only be the same if the clock had been set back at some point
after the cookie was written.
As I understand it there are reasonably common situations in which
NTP can cause the clock to change by a significant amount, so using
NTP/rdate alone doesn't solve the problem. For example, dual-boot
environments may need to leave the RTC in local time rather than UTC,
which can cause trouble during seasonal time changes.
Thanks,
Steve
More information about the Yum
mailing list