On Dec 1, 2009, at 5:07 AM, Bernhard Rosenkraenzer wrote:
> Hi,
> we've been using rpm5 head on our build machines for about 2 weeks now -
> after increasing the number of locks in DB_CONFIG, it works very reliably,
> but now the build machines are running out of diskspace because the rpm
> database takes up several (>20) gigabytes of space.
>
Cool! Your log files are bigger than the VM I work in ;-)
Yep. Log management using db utilities (in /usr/lib/rpm/bin, or
within rpmlib) is needed, and is not yet implemented. I was
waiting to see how much of the abstract logging framework might be
shared with Mancoosi WP3. Alas, not much can be shared and the
implementations cannot be merged soon, afaict at the moment.
The secondary content stores for files/packages remain to be done as well.
Getting file content and headers out of logs will reduce the
needed space.
> The files that have always been there are about the size they used to be,
> but every rpm invocation creates a new log.000* files, each 10 MB in size.
>
I question "every invocation", but the rest is accurate. The log file size
is set to 10Mb in DB_CONFIG.
> I can see why the rollback features they bring along can be important to
> some people, but for desktop users who install lots of updates on
> relatively small disks (and for developers who build lots of stuff) this
> can be a real problem -- is there a way to limit the number/size of log.*
> to keep it within reasonable boundaries, short of running
>
There are usage cases for RPM ACID even on the desktop and build systems,
just not "everything forever". Consider the case of saving just the last
transaction ...
> cd /var/lib/rpm
> rm -f `ls |grep -vE (Packages|DB_CONFIG)`
> rpm --rebuilddb
>
> whenever it gets too large?
>
It won't be --rebuilddb for log management.
For now, installing rpm-5.1.9 and doing --rebuilddb should uncouple
the Packages primary store from the logs and then reinstall from HEAD.
I meant to remove the file content for now from the logs last week, but I got
crunched by the Thanksgiving holidays. I'll add a enabler/disabler mechanism
in the next day or two.
You might want to look at
/usr/lib/rpm/bin/db_archive -l -h /var/lib/rpm
first to list log files no longer in use. I see that all
log files are listed as being used, have yet to check
whether that is accurate or not.
73 de Jeff
Received on Tue Dec 1 14:39:37 2009