PostgreSQL Example

In the example presented below, the Scan Plugin will connect the local PostgreSQL database via the PostgreSQL Plugin installed on the Bacula Client www-fd. Each database detected will be handled by a separate Job and Fileset. The Job directives will be defined via the JobDefs BackupsToDisk.

bacula$ /opt/bacula/bin/scan_plugin --client www-fd --plugin postgresql --jobdefs BackupsToDisk --plugin_option abort_on_error

Report for scan_plugin 0.5 www-fd:postgresql
----------------------------------------------
Client:         www-fd
Plugin:         postgresql
Total Objects:  11
---------------------------------------------
 ~ updated, + added, X removed, D disabled
---------------------------------------------
 + J_www-fd_postgresql_other
 + J_www-fd_postgresql_weird database81225
 + J_www-fd_postgresql_regress
 + J_www-fd_postgresql_dev
 + J_www-fd_postgresql_template1
 + J_www-fd_postgresql_ssss1
 + J_www-fd_postgresql_git
 + J_www-fd_postgresql_postgres
 + J_www-fd_postgresql_bacula
 + J_www-fd_postgresql_db1437565
 + J_www-fd_postgresql_master

----------------------------------------------
Status: Configuration not applied

The following configuration will be created:

Job {
  Name = "J_www-fd_postgresql_master"
  Description = "{\"parameter\":\"database\",\"id\":\"www-fd:postgresql\",\"version\":\"0.5\",\"uuid\":\"uuid=www-fd:postgresql:master\",\"database\":\"master\",\"plugin\":\"postgresql\",\"description\":\"Generated by scan_plugin. Do not edit.\"}"
  Type = "Backup"
  Client = "www-fd"
  Fileset = "J_www-fd_postgresql_master"
  JobDefs = "BackupsToDisk"
}

Fileset {
  Name = "F_www-fd_postgresql_master"
  Description = "{\"parameter\":\"database\",\"version\":\"0.5\",\"id\":\"www-fd:postgresql\",\"uuid\":\"uuid=www-fd:postgresql:master\",\"description\":\"Generated by scan_plugin. Do not edit.\",\"plugin\":\"postgresql\",\"database\":\":master\"}"
  Include {
    Options {
    }
    Plugin = "postgresql: database=\"master\" abort_on_error"
  }
}

Go back to the Examples page.

Go back to the main Automatic Object Integration (Scan Plugin) page.