Solved

Tape backup using tar

Posted on 2004-10-14
3
1,164 Views
Last Modified: 2013-12-16
I perform the following command to backup a file to tape.  But, we I want to list the content of the tape I get no output and error.

mt -f /dev/nst0 rewind
tar cvf /dev/nst0 sqlnet.sql

and when I want to list the content of tape with

Tar tf /dev/nst0 ( there is no output)

What am I doing wrong.

When I do
mt -f /dev/nst0 status ( the output is )
SCSI 2 Tape Drive:
Filenumber=-1,  blocknumber=-1, partition=-1.
Tape block size 0 bytes.  Density code 0x40 (DLTI 40gb, or Ultrium)
 
0
Comment
Question by:NBilly
  • 2
3 Comments
 
LVL 40

Accepted Solution

by:
jlevie earned 500 total points
ID: 12313381
After doing 'tar cvf /dev/nst0 sqlnet.sql' and before executing 'tar tf /dev/nst0' are you doing an 'mt -f /dev/nst0 rewind'? You are using a no-rewind on close tape device so after writing the archive the tape will be left at the end of the archive. So attempting to list the archive without rewinding will result in no output.
0
 

Author Comment

by:NBilly
ID: 12321527
I did a mt - f /dev/nst0 rewind where you suggested.  Then I did a tar -tf /dev/nst0 and it outputs sqlnet.log.  Just to test another file, I did a mt -f /dev/nst0 fsf 1 and did tar cvf /dev/nst0 nbtest.log.

After that I did a mt -f /dev/nst0 rewind and then did a tar -tf /dev/nst0 but it only lists the sqlnet.log from the first tar command.  Do you know why it's not outputting the nbtest.log.
0
 

Author Comment

by:NBilly
ID: 12323599
I figured out my second in my last comment.  I understand how it works now. Thanks.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

This is the error message I got (CODE) Error caused by incompatible libmp3lame 3.98-2 with ffmpeg I've googled this error message and found out sometimes it attaches this note "can be treated with downgrade libmp3lame to version 3.97 or 3.98" …
If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now