LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-16-2012, 05:43 AM   #1
sree.m
Member
 
Registered: Feb 2012
Posts: 56

Rep: Reputation: Disabled
Smile Cant backup to tape


Hi ,

I have been trying to take backup to my scsi tape drive, but m afraid i cant do the backup uing either dump or tar utility. Both returns "backup completed" though i cannot see any files appended in the tape catridge after the backup. The status of tape drive is as follows

# mt -f /dev/st0 status
SCSI 2 tape drive:
File number=0, block number=0, partition=0.
Tape block size 0 bytes. Density code 0x42 (unknown).
Soft error count since last status=0
General status bits on (41010000):
BOT ONLINE IM_REP_EN


But giving a 'tell' throws this

# mt -f /dev/st0 tell
/dev/st0: Input/output error



Can somebody suggest me some steps to go ahead from this point ??

regards,
Sree
 
Old 03-16-2012, 06:12 AM   #2
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,475

Rep: Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553
Not all tape drives support "tell"

The BOT at the bottom of your status line shows that the drive is currently at the beginning of the tape.

How exactly are you doing your backup and what is the tape device.

(I'm doing a fair bit with tapes at the moment as I'm having to work with a nice new LTO4 8 tape changer)
 
1 members found this post helpful.
Old 03-16-2012, 06:20 AM   #3
TenTenths
Senior Member
 
Registered: Aug 2011
Location: Dublin
Distribution: Centos 5 / 6 / 7
Posts: 3,475

Rep: Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553Reputation: 1553
Post

If you're just wanting to check the tape is working etc. then you can do a short backup of your /etc folder and then check it's on the tape.

To backup to the tape: You'll see that before and after the tar the tape will show BOT, that's because using /dev/st0 causes the tape to rewind after each operation.
Code:
mt -f /dev/st0 status
tar -cvf /dev/st0 /etc
mt -f /dev/st0 status
You can get a listing of what's on the tape with these commands, the first will show you the contents, and the second will show you that after the tar the tape has rewound.
Code:
tar -tf /dev/st0
tape -f /dev/st0 status
If you replace /dev/st0 with /dev/nst0 then it tells the tape drive NOT to rewind.
 
1 members found this post helpful.
Old 03-16-2012, 07:05 AM   #4
sree.m
Member
 
Registered: Feb 2012
Posts: 56

Original Poster
Rep: Reputation: Disabled
Thanks for your response.

Since i was not using /dev/nst0 it was rewinding the tape after every backup hence i couldnot see the backup files appended one after the other.

The status after 'dump' backup now is

[root@htbdb1 ~]# mt -f /dev/nst0 status
SCSI 2 tape drive:
File number=1, block number=0, partition=0.
Tape block size 0 bytes. Density code 0x42 (unknown).
Soft error count since last status=0
General status bits on (81010000):
EOF ONLINE IM_REP_EN


Now i got that point. I gotta appreciate this nice work of guiding me through the right way. Thanks.

regards,
Sree
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to backup more than one time on same tape using DLT tape? hocheetiong Linux - Newbie 3 01-30-2008 06:54 AM
Using a DDS5 tape drive to restore from a DDS3 backup tape. AndrewCAtWayofthebit Linux - Hardware 1 05-14-2006 09:15 AM
Tape incremental backup to different tape tungaw2001 Linux - Software 0 08-13-2003 09:42 PM
Tape Backup Falieson Linux - Hardware 4 06-12-2003 08:07 PM
Tape backup help WorldBuilder Linux - Software 1 03-27-2003 01:26 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 01:06 PM.

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