Bacula-users

Re: [Bacula-users] Still don't get auto-pruning

2015-08-12 04:32:23
Subject: Re: [Bacula-users] Still don't get auto-pruning
From: Kern Sibbald <kern AT sibbald DOT com>
To: Luc Van der Veken <lucvdv AT wimionline DOT com>, "Bacula-users AT lists.sourceforge DOT net" <bacula-users AT lists.sourceforge DOT net>
Date: Wed, 12 Aug 2015 10:29:15 +0200
Hello,

I suspect (but this is just a guess) that you may not understand what prune and purge do.  The first important point is that both apply only to records kept in the catalog -- that is nothing actually physically happens with the volumes.

Prune removes records from the catalog based on retention periods.

Purge removes Job records without regards to the retention periods.  This command is somewhat dangerous so should almost never be needed unless you have a fixed number of volumes (i.e. tapes) and they are all in use, so you (as I sometimes do) select the oldest one and prune it (or better yet, I simply buy more tapes).

Bacula attempts to keep the physical Volume data a long as possible.  That is, it overwrites old data only when it has no other option.

The pruning algorithm has been modified (more correct is "enhanced") several times in the last 10 years so what is in the manual could be slightly out of date at least in some area.  One of the main changes that is probably not clearly spelled out in the manual is that compared to the first implementation many years ago, during autoprune Bacula tries to prune only the Volume that is actually needed.  Previously it pruned pretty much everything that it could find.

Best regards,
Kern



On 12.08.2015 10:05, Luc Van der Veken wrote:

I still don’t really get auto-pruning, I think.

Am I seeing ‘prune’ and ‘purge’ as more closely related than they are?

 

Snippet from the manual, about what happens when Bacula needs a volume:

 

AutoPrune = yes|no

If AutoPrune is set to yes (default), Bacula will automatically apply the Volume retention period when running a Job and it needs a new Volume but no appendable volumes are available. At that point, Bacula will prune all Volumes that can be pruned (i.e. AutoPrune set) in an attempt to find a usable volume.

 

Either my configuration is still wrong after reviewing it several times, or that “prune all volumes” doesn’t mean that more than one will be purged at that time.

The way I see it happen, it just recycles the oldest volume and leaves all others alone, no matter how far ‘over date’ they are.

I’ve got file volumes with volume, file and job retention all set to 3 months, that are 4 months old and still sitting on disk marked “full”.

When I try to list jobs or files on those volumes, it doesn’t find them in the database anymore.

 

In another pool (used for incremental backups) it’s the same with retentions of 15 days, full files of 3 months old still sitting there.

 

Is the only way to purge the excess volumes to do it manually (or create a bconsole script)?

 



------------------------------------------------------------------------------


_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users

------------------------------------------------------------------------------
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users
<Prev in Thread] Current Thread [Next in Thread>