[Wolves] backing up methods

Ron Wellsted ron at wellsted.org.uk
Tue May 5 10:15:23 UTC 2009

Hash: SHA1

Mo Awkati wrote:
>> Hi folk
>> Hope you can help.
>> I have an external (USB) storage drive which I use to backup my data to.So
>> far I just used drag and drop to transfer the data over but that takes
>> ages. I tried Simple Backup but could not be sure if it was doing the
>> business. There is no indications that Simple Back up has done the job and
>> when I try to view the archive folder it created (after 3 hours) I just
>> get the egg timer and nothing else. It appears that Simple Backup does the
>> job in a matter of minutes, is that usual? I know it depends on th amount
>> of data, but we are talking about 4.5G of data, photos, videos etc
>> Any suggestions on a simple and speedy backing up process?
>> Cheers
>> Mo
>  > Now I admit I haven't tried this yet myself, but there is a nice looking
>>script at http://andri.dk/tech/linux/usb-backup which should help - or
>>at least point you in a direction that you can work on from... ;-)
> I will give a try, many thanks. I put Simple Backup on and went out this
> afternoon, so I am going to try and transfer data onto the new Ubuntu
> 9.04 install :-)
> Many thanks

I use a shell script.  This was originally written for a tape drive but
could be modified to work with a USB harddrive (just modify the TAPE=
line and comment out/remove the lines starting with mt
==== CUT HERE ====
#	shell script to perform automatic backups

export PATH
cd /
echo Backup started at `date`
#echo Dumping PostgreSQL databases
#pg_dumpall -U postgres >/var/backup/pgdump.sql
echo Dumping MySQL databases
# the following is just one line (extra line due to email)
mysqldump --user=backup --password=password --all-databases
# set drive blocksize
mt -f $TAPE setblk 16384
# turn on drive compression
mt -f $TAPE setdensity 0x83
mt -f $TAPE status
tar cvbf 32 $TAPE --atime-preserve --sparse --exclude-from=/etc/autobackup .
echo Backup finished at `date`
mt -f $TAPE status

# now verify the tape
echo Verify started at `date`
tar dbf 32 $TAPE
mt -f $TAPE status
echo Verify finished at `date`

#eject the tape
mt -f $TAPE eject
==== CUT HERE ====

- --
Ron Wellsted
ron at wellsted.org.uk http://www.wellsted.org.uk
N 52.567623, W 2.136111 Linux Counter No. 202120
Ekiga: 645022

Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org


More information about the Wolves mailing list