X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=chiark-utils.git;a=blobdiff_plain;f=backup%2Ffull;h=668b5fdaec6fa9216e1ad1c7bcd1fe299261de2a;hp=dddb343be2b12ed0fc5b520f62d4b8ecefd56b57;hb=85bed522cbce35f5428382ea749540a2e1aeb8fd;hpb=d906fbd72072c6953922e0627bbcf3d4c62ce7c0 diff --git a/backup/full b/backup/full index dddb343..668b5fd 100755 --- a/backup/full +++ b/backup/full @@ -23,7 +23,7 @@ # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. BEGIN { - $etc= '/etc/backup'; + $etc= '/etc/chiark-backup'; require "$etc/settings.pl"; require 'backuplib.pl'; } @@ -35,16 +35,14 @@ $|=1; # dumped in both full and incremental dumps. setstatus "FAILED configuration check"; print "Configuration check ...\n" or die $!; -system 'checkallused'; $? and die $?; +system 'backup-checkallused'; $? and die $?; printdate(); setstatus "FAILED reading TAPEID"; # Try to read the tape ID from the tape into the file TAPEID -unlink 'TAPEID'; -system "mt -f $tape rewind"; $? and die $?; -system "mt -f $tape setblk $blocksizebytes"; $? and die $?; -system "dd if=$tape bs=${blocksize}b count=10 | tar -b$blocksize -vvxf - TAPEID"; + +readtapeid_raw(); setstatus "FAILED during startup"; @@ -130,14 +128,13 @@ openlog(); $doing= "dump of $fsys to tape $tapedesc in drive $tape"; print LOG "$doing:\n" or die $!; +setstatus "FAILED retensioning"; +system "mt -f $tape reten"; $? and die $?; + setstatus "FAILED writing tape ID"; # First write the tape ID to this tape. -open T, ">TAPEID" or die $!; -print T "$tapeid\n" or die $!; -close T or die $!; -system "tar -b$blocksize -vvcf TAPEID.tar TAPEID"; $? and die $?; -system "dd if=TAPEID.tar of=$ntape bs=${blocksize}b count=10"; $? and die $?; +writetapeid($tapeid); unlink 'this-md5sums';