I have some newbie questions about tar and cp in relation to tape drives on RedHat 7.1

I want to create an archive on disk then write a copy of it to tape. Can I do the following?
tar -cf backup1.tar /dir1 /dir2 /dir3
cp backup1.tar /dev/st0

If I do repeated cp commands each with a different file
cp backup1.tar /dev/st0
cp backup2.tar /dev/st0
cp backup3.tar /dev/st0
and then do
cp backup1.tar /dev/st0
what happens? Does it erase the original file?

There appears to be no tape manipulation utility such as mt. What is good one to install? Do I really need one?

Is it a good idea to rewind the tape before copying to it?
tar -cf backup1.tar /dir1 /dir2 /dir3
mt -f /dev/st0 rewind
cp --force backup1.tar /dev/st0
If cp does not work to a tape drive then should I use:
#Create the archive write to disk
tar -cf backup1.tar /dir1 /dir2 /dir3
#Create the archive(again) and write to tape
tar -c backup1.tar /dir1 /dir2 /dir3
Or would the following be better
#Create the archive and write to disk
tar -cf backup1.tar /dir1 /dir2 /dir3
#Write the single archive file to tape via tar
tar -c backup1.tar backup1.tar

Eventually this will be in a script invoked by cron.

Thanks for your help

Robert
I am a NetCorps volunteer
NetCorps is a nonprofit that provides technical support to other nonprofits.




_______________________________________________
Eug-LUG mailing list
[EMAIL PROTECTED]
http://mailman.efn.org/cgi-bin/listinfo/eug-lug

Reply via email to