Links

Content Skeleton

This Page

Previous topic

Partial Backup Machinery

Next topic

LOW LEVEL EXIST USAGE FUNCTIONS

BACKUP ANT BUILDΒΆ

The ant targets are typically not normally invoked directly. These targets are invoked from the bash function layer.

Documentation for the xdb:move etc..

partial backup (the hfagc form input instances) of database on the target:

G> cd ~/heprez/backup/part ; xant      ( ant -Dtarget.host=$X )
G> ls -l  ~/hh/backup/part            ## view the backups

archive the current /db/hfagc aside to eg /db/archive/2008/:

G>  cd ~/heprez/backup/part ;   ant part-archive

then restore into localhost with:

G> cd ~/heprez/backup/part ;   ant part-restore

caution:

G>  xant part-restore     ( would restore back to the target )

target alternates with:

ant -Dtarget.host=$I
ant -Dtarget.host=140.112.101.199
ant -Dtarget.host=hfag.phys.ntu.edu.tw

example of restoring a lost directory (NB the default is to the localhost):

ant  -Drestore.dir=hfag.phys.ntu.edu.tw/2006/Jan18-0957 -Demergency.path=/db/hfagc/cdf/cjl  emergency-restore

to copy backups between machines, eg I to G:

I> cd /work/blyth/hfag/hfag-0.0.2/backup/part/hfag.phys.ntu.edu.tw/2006
I> scp -r Jan18-0957 G:/work/blyth/hfag/hfag-0.0.2/backup/part/hfag.phys.ntu.edu.tw/2006/
G> cd /work/blyth/hfag/hfag-0.0.2/backup/part/hfag.phys.ntu.edu.tw/
G> rm -f last ; ln -s 2006/Jan18-0957 last             # manually resetting the "last" link

go live with the restoration:

xant  -Drestore.dir=hfag.phys.ntu.edu.tw/2006/Jan18-0957 -Demergency.path=/db/hfagc/cdf/cjl  emergency-restore

part-archive

creates a timestamped archive directory and move the /db/hfagc into it with file structure like : /db/archive/2006/Sep27-1820/db/hfagc/belle/blyth/blah...

part-correct

applies a correction stylesheet to the database, placing the corrected serialized database segment under a new timestampled directory NB would normally do “xant part-correct” to transform the database corres to hfag.phys.ntu.edu.tw

part-restore

restores from filesystem backup into /db/hfagc /db/hfagc_tags /db/test upon successful completion leaves a symbolic link in filesystem