PDA

View Full Version : tape backup


talkstock888
2005-03-28, 07:47 AM CST
what is command for backup tape back up

My csci id on 06


Host: scsi0 Channel: 00 Id: 06 Lun: 00
Vendor: ARCHIVE Model: Python 04106-XXX Rev: 715G
Type: Sequential-Access ANSI SCSI revision: 02

awdac
2005-03-28, 07:51 AM CST
'man mt' is a good start, anyway.

tashirosgt
2005-03-28, 08:07 AM CST
You have to figure out what the device file(s) is associated with you tape. Thanks to the miracle of udev, if you didn't have your tape unit turned on when you booted, you might not have any /dev/... files for the tape device. Scsi tape devices are often named things like /dev/st0. (Using dmesg, you might find if the computer saw your tape drive. )

You can write a tar archive to a tape with something like:
tar cvf /dev/st0 myfile1 myfile2
and you read-it-back with something like
tar xvf /dev/st0

You must be careful to distinguish between a no-rewind device and a rewind device. If the "driver" /dev/st0 is a rewind device then the two commands:
tar cf /dev/st0 myfile1
tar cf /dev/st1 myfile2
will result in only myfile2 being written since the tape will rewind after each command.

Now, does anyone know how to tell what device files are supposed to do what? Is there a systematic way to find out on a Linux system what kind of physical device a /dev/... file applies to? Or is it supposed to be done by trial-and-error, like so many configuration tasks ?

mt, as awdac suggested, might be a better way, but I have no experience with it.

Yatima
2005-03-28, 09:54 AM CST
Some hints:

mt basically controls the tape device, i.e. you can wind it forward/back, switch compression or of off etc.

You would indeed use 'tar' to dump stuff to the device. Probably want to put some script
around it to do file selection etc. Or look into http://sourceforge.net/projects/afbackup or
amanda (comes with Red Hat). Incidentally, I'm right now trying to configure it. 8-/

To see what SCSI devices there are, 'cat /proc/scsi/scsi'

talkstock888
2005-03-28, 11:34 AM CST
Host: scsi0 Channel: 00 Id: 06 Lun: 00
Vendor: ARCHIVE Model: Python 04106-XXX Rev: 715G
Type: Sequential-Access ANSI SCSI revision: 02