Download your favorite Linux distribution at LQ ISO.
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 12-06-2006, 08:45 AM   #1
Registered: Sep 2004
Location: NH
Distribution: FC6, FC1-4, RH9, Gentoo 2006.0/1, Slackware 10.1/2,11, Vector SOHO 5.0.1
Posts: 237

Rep: Reputation: 30
Having trouble with tape backups

Hello all,

I have recently acquired a Dell PowerEdge 2550 with internal tape drive (with tapes ).

I would like to set it up to be my file server and backup. The file serving I have all set. It is the backups I am having trouble with.

When I perform the command:
tar -cvf /dev/st0 mybackup
The command executes fine and all seems well.

However, when I execute the command:
mt -f /dev/st0 eject
To remove my tape, I find that the actual "tape position" has not moved.

To test to make sure I had the correct device I ran:
mt -f /dev/st0 status
Several times, once with no disk (reported no disk), once with disk (reported disk and online), and once with a write-protected tape (again reported write-protected). So, at this stage, I feel I have the right device.

But again I am confused. For when I eject the tape and run:
 ls -lh /dev | grep st0
The file size reported is the size of my backup (roughly 3.1 GB).

So I dug further. I found that /dev/st0 is a rewinding tape drive designation, and at the completion of a command on it causes it to rewind.

For giggles I tried this command:
 tar -cvf /dev/nst0 mybackup
As "nst0" is a non-rewinding drive. Again the backup went off without a hitch. But again upon an eject of the tape, I found that the tape's "position" hasn't moved.

I went through the same tests above to see if I could even access "nst0" and to my surprise all the commands came back and in the same manner as they did for "st0"!

So I decided to go back to "st0". First with an erase:
mt -f /dev/st0 erase
to start fresh. But no! Now I receive this error
/dev/st0: File too large
. This error comes back on any "mt" command I wish to use on /dev/st0.

As a side note, whenever I do run a command whether for "st0" or "nst0" the drive activity light comes on, and shuts off when the command completes.

Any help in this matter would be greatly appreciated.

Thanks in advance
Old 12-06-2006, 10:12 AM   #2
Senior Member
Registered: Oct 2003
Posts: 2,396

Rep: Reputation: 163Reputation: 163
What do you get if you do:

$ mt -f /dev/nst0 erase

or this:

$ mt -f /dev/nst0 rewind
Old 12-06-2006, 10:37 AM   #3
Registered: Sep 2004
Location: NH
Distribution: FC6, FC1-4, RH9, Gentoo 2006.0/1, Slackware 10.1/2,11, Vector SOHO 5.0.1
Posts: 237

Original Poster
Rep: Reputation: 30
Rewind returns quickly back to the prompt (as the tape is already at the beginning).

As for erase it becomes a defunct process and locks up. Even a "kill -9" doesn't get rid of it. Waiting it out does though.

However, when I compared the output of:
 ls -lh /dev | grep nst0
to that of:
 ls -lh /dev | grep st0
I found that while /dev/st0 reports a file size (now due to testing a whopping 8.7 GB that I can't get rid of ) /dev/nst0 doesn't report a file size but rather this:
crw-r-----  1 root disk     9, 128 1994-07-18 12:05 nst0
Another weird thing about the output is that /dev/st0 doesn't have the proceeding "c" in it's long listing indicating that it is a character device, but as you can see from the above output /dev/nst0 does.

Thanks for the help.


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
Restoring data from tape backups enygma Linux - General 8 11-11-2004 01:29 PM
tar or cpio - Which is better for tape backups? Br. Nicholas Linux - Software 2 07-02-2003 04:06 PM
trouble with tape bimble Linux - Hardware 1 12-03-2002 02:11 PM
trouble using dd for tape backups. Jason Foat Linux - Hardware 1 05-21-2002 02:03 PM
Tape Drive Trouble Paul_assheton Linux - General 8 01-31-2002 07:18 AM

All times are GMT -5. The time now is 12:55 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