Don Harper wrote:
On Thu, Jun 25, 2009 at 05:33:52PM -0400, Michael DeHaan wrote to To
cobbler development list:
> I've been told it's a bad idea for RPM scriptlets to call RPM in post.
>
Bad idea? It is impossible due to locking of the RPM database.
It's not actually impossible. It would be better if it was. It's
apparently a race condition, which probably explains why some folks
(rare) didn't have their %post
sections execute.
> Calling condrestart on cobbler does this, certaintly.
>
? There is nothing in there that I see that calls RPM (just check
1.6.6)
I am confused.
The API handle cares about the current OS version, and eventually calls
rpm (see utils.py) to do this.
It is rather minimal.
> As a result, I'm thinking about /not/ calling condrestart in %post... so
> effectively after an upgrade, you are still running the old cobbler with
> the new CLI, and we'll have to detect that problem
> and work around it... things looking for version data should of course
> use /var/lib/cobbler/version first ... though perhaps we can avoid
> calling RPM altogether where we do today ... thoughts?
>
Bad juju.
don
Presumably we should just scrub any RPM calls that might be actuated in
%post and replace them with other means.
> (Yes, I know we don't call RPM on non-RPM platforms, this
much is
> obvious... and we don't do so today)
>
> --Michael
> _______________________________________________
> cobbler-devel mailing list
> cobbler-devel(a)lists.fedorahosted.org
>
https://fedorahosted.org/mailman/listinfo/cobbler-devel
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> cobbler-devel mailing list
> cobbler-devel(a)lists.fedorahosted.org
>
https://fedorahosted.org/mailman/listinfo/cobbler-devel
>