Bacula-users

Re: [Bacula-users] Re ducing the size of the database.

2008-10-21 12:22:30
Subject: Re: [Bacula-users] Re ducing the size of the database.
From: Hemant Shah <hjrrs AT yahoo DOT com>
To: bacula-users AT lists.sourceforge DOT net, ebollengier <eric AT eb.homelinux DOT org>
Date: Tue, 21 Oct 2008 09:18:38 -0700 (PDT)


--- On Tue, 10/21/08, ebollengier <eric AT eb.homelinux DOT org> wrote:

> From: ebollengier <eric AT eb.homelinux DOT org>
> Subject: Re: [Bacula-users] Re ducing the size of the database.
> To: bacula-users AT lists.sourceforge DOT net
> Date: Tuesday, October 21, 2008, 2:25 AM
> If it's 40,000 rows of the filename or path table, each
> rows are something
> like 10 or 15 bytes long....
> 
> If you want to reduce the size of your database, you need
> to review your
> retention periode or to prune jobs (ie, remove backup
> content information
> from the catalog).
> 
> See the manual for more information (Automatic Volume
> Recycling chapter)
> 

  My retention periods are fine, I have it configured like I want it. My 
problem was I did not understand how PostgreSQL handles the disk space for the 
deleted rows. I figured out how to reclaim disks pace.
 
> 
> shahhe wrote:
> > 
> > This is probably a question for a PostgreSQL group,
> but I though users
> > using bacula may have come across this problem.
> > 
> > I am using PostgreSQL for the database, last week when
> I checked, my
> > database size was 10GB. I removed one month worth of
> volumes from the
> > bacula database and ran dbcheck command. It deleted
> about 40,000 rows from
> > the database, but the database size was still 10GB.
> Next, I ran postgresql
> > vacuumdb (vacuumdb -q -d bacula -z -f)command to
> reclaim the space used by
> > deleted rows, but the database size is still 10GB. How
> do I reduce the
> > size of the database?
> > 
> > I also backup the catalog every night using pgdump
> command. Before I
> > deleted the 40,000 rows the backup file size was
> 800MB, after deleting
> > 40,000 rows the backup file size is still 800MB.
> > 
> > 
> > # df -h /baculaDB
> > Filesystem            Size  Used Avail Use% Mounted on
> > /dev/mapper/VolGroup01-baculaDB
> >                       99G   11G   83G  12% /baculaDB
> > 
> > 
> > bacula=# select pg_database.datname,
> > pg_size_pretty(pg_database_size(pg_database.datname))
> as size from
> > pg_database;
> >  datname  |  size   
> > -----------+---------
> > template1 | 4272 kB
> > template0 | 4272 kB
> > postgres  | 4272 kB
> > bacula    | 10 GB
> > (4 rows)
> > 
> > 
> > Hemant Shah
> > 
> 
> -- 
> View this message in context:
> http://www.nabble.com/Reducing-the-size-of-the-database.-tp20073848p20084840.html
> Sent from the Bacula - Users mailing list archive at
> Nabble.com.
> 
> 
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move
> Developer's challenge
> Build the coolest Linux based applications with Moblin SDK
> & win great prizes
> Grand prize is a trip for two to an Open Source event
> anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Bacula-users mailing list
> Bacula-users AT lists.sourceforge DOT net
> https://lists.sourceforge.net/lists/listinfo/bacula-users



Hemant Shah
E-mail: hjrrs AT yahoo DOT com


      

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users