Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 07-05-2002, 06:01 AM   #1
Registered: Mar 2002
Location: Sydney, Australia
Distribution: RHEL, Fedora, Yellow Dog
Posts: 43

Rep: Reputation: 15
Problem with SCSI DDS3 tape drive

Hi All,

I have a tape drive on /dev/nst0 which I've been tarring my filesystems two for over a year now.

The tar command I use to write to tape is
tar -cvpf /dev/nst0 --label="Backup:`date '+%d-%B-%Y'`" --directory / --exclude=mnt --exclude=proc --exclude=dev --exclude=tmp --exclude=root . > /tmp/Backup-`date '+%d-%B-%Y'`-Log

Which writes the tar file to the tape and puts a log file in /tmp. After that I rewind the tape with
mt -f /dev/nst0 rewind
and take it offline with
mt -f /dev/nst0 offline

This has been working fine for ages however when I try to dothis now I ge the error
tar: /dev/nst0: Wrote only 0 of 10240 bytes
tar: Error is not recoverable: exiting now

From looking at the log file this tar command generates sometimes this happens after only a few files, sometimes after almost the whole backup is written, however it invariably always happens and something is not backed up. Oh the other thing is it always says 10240 bytes? Mabye this is signitficant?

Can anyone fill me in on what this means. Is the drive bad or is this something to do with a configuration perhaps? Each time I try to backup its on a different tape so Idont think its dodgy tapes.

thanks heaps for reading this far !!
Old 07-05-2002, 09:51 AM   #2
Senior Member
Registered: Dec 2001
Location: The Netherlands
Distribution: Ubuntu
Posts: 1,316

Rep: Reputation: 47
The commands look fine as long as you position the tape at the right location before you start archiving.

The 10240 is just the default blocksize. If you look at the tar man page you will see the default is 20 blocks (block is 512 bytes).

Have you tried just archiving just one file to make sure reading and writing to the tape works. You could do something like:

mt -f /dev/nst0 rewind #rewind tape
mt -f /dev/st0 weof #quick erase and rewind when done
tar cvf /dev/st0 /etc/services #archive /etc/services and rewind
tar tvf /dev/st0 #display contents of the archive


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
SCSI Card/Tape Drive Problem Optimistic Debian 8 03-14-2005 04:19 AM
Sony DDS3 SCSI Tape Drive in Slack 10 CactusLoyale Slackware 1 07-26-2004 07:08 PM
PowerEdge 2200 Sony DDS3 Tape Drive in Slack 10 CactusLoyale Linux - Hardware 1 07-20-2004 04:58 PM
Problem with my SCSI Tape Drive Liquid Crystal Linux - Newbie 0 05-08-2004 08:25 AM
Problem with SCSI tape drive on RH8 machine nicktoop Linux - Hardware 9 02-12-2004 11:10 AM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 02:53 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration