>>>>> On Wed, 25 Oct 2006 20:04:27 +0200, Christoph Haas said: > > On Wednesday 25 October 2006 15:15, Wolfgang Powisch (privat) wrote: > > My Setup: > > bacula-1.38.8 > > Catalog on PostgreSQL 8.0 Server > > File Storage > > > > I'm seeing my Catalog Database getting larger and larger. > > the "file" table has >45 million records now and uses over > > 10GB on disk. > > > > Doing a "list jobtotals" shows only about 5 million files total. > > (this looks much more realistic than 45millions) > > > > It seems, that for some reason, file entries (and maybe others too) > > are not pruned from the catalog. Calling "prune files client=xxx" > > gives a "No files to prune". > > > > As I've seen in the database, there are records for Clients, which are > > no more in the configuration of bacula-dir. > > > > Is it possible, either from bconsole or with some great SQL query, to > > make some sort of database cleanup and delete such unused entries from > > catalog ? > > Use the "dbcheck" utility to wipe off orphaned entries. Example on Debian > for a possible crontab entry: > > 3 4 * * * /usr/sbin/dbcheck -b -f -c /etc/bacula/bacula-dir.conf > > By the way... the documentation reads that orphaned entries are removed > automatically. That's not true with at least 1.38.9 here. 'dbcheck' finds > orphaned entries every night. Who's fault is that?
Orphaned records are never removed automatically. What kind of records is this wiping every night? In general there shouldn't be any orphaned file records because pruning should remove the file records before removing any job records. There might be orphans in the filename or path tables though. Do you have crashes that are leaving the tables in an inconsistent state? __Martin ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users