Red Hat Bugzilla – Bug 633447
/var/cache/mock/ and /var/lib/mock/ are difficult to allocate to temporary space.
Last modified: 2014-11-20 07:57:19 EST
Description of problem:
Mock can become extremely bulky, especially when working in multiple environments. It would help disk space allocations, backup, expiration, and exclusion of mock working copies from "updatedb" to keep all mock output in "/var/mock/cache/" and "/var/mock/lib/", instead of "/var/cache/mock/" and "/var/lib/mock/".
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Install mock
2. Build software for several different OS configurations
3. du -s /var/lib/mock/
4. du -s /var/cache/mock/
This might take some SELinux changes to support new location, and updates to the 'cachedir' and 'basedir' settings in /etc/mock/. But the ability to separate mock out in /etc/updatedb.conf and to designate an added partition or LVM for mock use, especially in virtualized environment migration, more than justify the work.
What does FHS have to say on the manner? I don't want to break FHS.
(In reply to comment #1)
> What does FHS have to say on the manner? I don't want to break FHS.
That we're in the right place.
Our cache data was moved from /var/lib/mock/cache to /var/cache/mock, per FHS.
Likewise the chroot dirs were placed in /var/lib/mock/<cfg> as "variable state information"
We were originally in /var/mock and moved out due to wanting to be compliant with FHS (which doesn't seem to have a provision for /var/<pkg>).
I see your point. I disagress with it for purely practical reasons. The upstream FHS was not written with this sort of tightly associated, dual, bulky, expiring components in mind. In particular I think that the "/var/lib/mock/[config] directory could be modified to also contain the pre-built cache of previous mock tarbaslls.
So please, either decide that ease of space allocation is more important than strict upstream FHS compliance, or close the ticket. It's over a year old.
Closing. This will not happen.
You can either create /srv/mock/lib /srv/mock/cache and make symlinks there.
Or even better use new lvm_root plugin and have cache in LVM, which is even better.