Backups and Restores


NOTE: Depreciated. Bacula is no longer used.


Bacula

Bacula provides the backup services for servers in MT. Bacula consists of the following components:


Backup Procedures


Backups are grouped by clients and jobs, stored in volumes which are grouped in pools and labeled accordingly, and scheduled in cycles. Details are in poprocks /etc/bacula/bacula-dir.conf, essentials available via bconsole. Manually running a backup job is a rare occurrence, but can be done via 'run' in bconsole.

Offsite Backups

Kitkat
Chickostick

Restore Procedures


Bconsole 'restore' command, select jobid for the client. For pvsadmin, backups are for client kitkat-fd, and file is pvsadmin.lite.db (or use job PvsadminLite) (lite because zip2district and addr2zip are empty)


Database Restores


For database restores of deleted items, use a clean restore schema (or at least specify clean in pg_restore command). /export/bacula/restore/restore_tables.* has groups of tables that frequently need to be restored together.

Example for restore of deleted sig data:

root@kitkat:/home/clinton# cat /export/bacula/restore/restore_tables.sig |  while read table; do pg_restore  -n public -t $table pvsadmin.lite.db \
 | sed "s/SET client_encoding = 'UTF8'/SET client_encoding = 'latin1'/" |  sed "s/SET search_path = public/SET search_path= restore/" \
| psql -h poprocks -Upgsql -1 pvsadmin ; done;

admin.votesmart.org[pvsadmin]# begin;
BEGIN
admin.votesmart.org[pvsadmin]*# insert into endorse SELECT e.* FROM restore.endorse e JOIN restore.sig USING (sig_id) WHERE sig_id = 1944;
INSERT 0 47
admin.votesmart.org[pvsadmin]*# in
sert into rating SELECT e.* FROM restore.rating e JOIN restore.sig USING (sig_id) WHERE sig_id = 1944;
INSERT 0 0
admin.votesmart.org[pvsadmin]*# insert into endorse_candidate SELECT e.* FROM restore.endorse_candidate e JOIN endorse en USING (endorse_id) JOIN restore.sig USING (sig_id) WHERE sig_id = 1944;
INSERT 0 96
admin.votesmart.org[pvsadmin]*# insert into sig SELECT s.* FROM restore.sig s WHERE sig_id = 1944;
INSERT 0 1
admin.votesmart.org[pvsadmin]*# insert into sig_categ
ory SELECT s.* FROM restore.sig_category s WHERE sig_id = 1944;
INSERT 0 4

admin.votesmart.org[pvsadmin]*# insert into sig_tag SELECT s.* FROM restore.sig_tag s WHERE sig_id = 1944;
INSERT 0 3
admin.votesmart.org[pvsadmin]*# commit;
COMMIT



Gotchas
Special datatypes, domains (such as flexdate) need to be created prior to the restore of any table using them.

Online Documentation

bconsole.conf: http://www.bacula.org/5.0.x-manuals/en/main/main/Console_Configuration.html
bacula-sd.conf: http://www.bacula.org/5.0.x-manuals/en/main/main/Storage_Daemon_Configuratio.html

Diagrams


Current Services

Bacula Services

Current Jobs

Current Jobs

Proposed Jobs

Proposed Services


CategoryITDefunct
There is one comment on this page. [Display comment]
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki