[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: rpm installation inside another rpm - database locked [wd-vc]




On Dec 22, 2005, at 3:09 PM, dkegel wrote:

Sorry, I don't think you can install RPMs from inside another RPM.


You're wrong.

As long as concurrent access to /var/lib/rpm is enabled (the default since rpm-4.1),
then one can run rpm -q (and rpm -Uvh) in %post.

In rpm-4.4.2 and later, there is another wrinkle needed, to get rid of the transaction fcntl lock.

This can be done by adding either
    rm -f /var/lock/rpm/transaction
or
    rm -f /var/lib/rpm/__db.000
depending on what path is in use. Removing both won't hurt anything, the concurrent access locks in Berkeley DB are more than sufficient to ensure concurrency.

The real trick is doing all this portably and reliably. That's called trying and testing.

Or keep guessing whether rpm can actually do whatever, that works too.

73 de Jeff


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]