newbie tar/tape backup questions
Im having some issues backing up tar to a tape drive, hoping someone can give me some info on seeing status of things. I have read a few howto's and man pages but can't find answers to the questinos below. if anyone has a link to certain docs that answer my ?'s id be very grateful. heres the skinny:
I have setup nonprofit with FC4 , a sony ait (ide) tape drive (40/104gb). i can do small backups/restores/compares just fine to /dev/st0
Once we started backing up all of the organizations (only about 20gb) Istarted getting inconsistant results.
My failures seem to be on the compare: certain files fail compare randonly, no one had the files open and tar is still running in the morning , so it looks like its actually getting hung up and not just failing the compare and moving on. Ive tried removing the files in question on occasion it still fails on random files. Last night it went fine however, after changing my scripts slightly. but I still had a couple of questions i cannot find the answer to and im hoping theyre easy:
from what ive read accessing the device as st0 autorewinds it after every access, is this true?
what is the default behavior of tar as to tape overwriting? I want the job to overwrite the tape each night, do i have to use mt to erase it prior or not? the backup command im using is "tar cf /dev/st0 /home/netshare"
I have tried the compression switches but had issues restoring, so for now its disabled. will this increase the backup speed (its taking many more hours than the same amount on a windows system with backup exec).
how do i know/set the tape capacity in linux with tar?
where/how to set compression, as in windows it appears a default setting , we always get more than the uncompressed capacity. does piping through gzip give similiar results, and is that the best approach to utilize compression?
I have the output of the tar df compare to a text file to see backup compare status, but since it occasionally fails at this stage, is there a more detailed log i can see? I see nothing in /var/log/messages, and the output of the file doesnt give much info either except what files failed (and the fact that tar is still active task in the am). last night i used tar dvf, doesnt tell me much more when it fails.
so, lotsa ?'s (sorry!). is there any docs that cover these issues? surely there are and ive had bad luck not finding them. thanks for any help!
I do not have a big tape drive but it does bomb on me some times also. Mainly is when I get close to the size of what I am backing up and the tape just doesn't have much room left on it. I personaly would not do massive backups on tape because tape does stretch and that would be a good guess for me to start with. I always erase before I do a backup. When I do backups now I just do certain directory's not the whole system.
tar -cjvjpf /dev/st0 /boot /root /etc /usr .... will copy the four directory's and do it in a bzip2 copy, to your tape. I do not see any difference zipping it or not on backups. Rotate your tapes don't just dump on one tape all the time. I also use xdiskusage to see how big my directory's are so I can judge the backup I am doing.
I will do some experiments with compression, thanks for responding!
well, a little update:
I continued to have issue with tar getting hung up on various files. I ried cpio and its been running great once i ironed out syntax and where i need to be (folder location) to run restores/backups. i also found that using --buffer-size=2048 _tremendously_ improved the backup speed.
the first backup took something like 12+ hrs for 30gb. with that buffer change its only about 3 hrs, pretty normal. thanks for the help and suggestions!
|All times are GMT -5. The time now is 03:26 AM.|