Skip to content

CLI tools cleaning up Bareos database and file storage

License

Notifications You must be signed in to change notification settings

jpylypiw/bareos-cleaner

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 

Repository files navigation

bareos-cleaner

Codacy Badge

BASH tools cleaning up Bareos database and file storage.

This is a purely pragmatic toolset, i.e. no plans for making it a "product" of any kind for now!

Commands

-e
   delete empty (JobBytes=0) jobs
-p
   prune all volumes
-t
   update all volumes to "actiononpurge=Truncate"
-n
   update all volumes to "actiononpurge=None"
-Dc
   delete all jobs that have a copy job
-Do
   delete obsolete volume files from the disk (those not listed in catalog)
     NOTE: this operation can take several minutes to complete
-Dp
   delete all purged volumes from Bacula catalog
-h
   print this screen

Usage

export BAREOS_POOLDIR=/mnt/bareos
bareos-cleanup -e

Configuration

POOLDIR
    Directory where pool files are placed on hard drive.
    In Default setup you can find the directory in file /etc/bareos/bareos-sd.d/device/FileStorage.conf

MYSQL_USER
    Username for MySQL Connection

MYSQL_PASSWORD
    Password for MySQL Connection

About

CLI tools cleaning up Bareos database and file storage

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 100.0%