Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
Hi,
I use a DLT4000 for backups. I backup a local file system and use the no-rewind device so that I can backup a remote file system as the second volume on the tape.
From the remote machine I would use a command such as:tar cvBbf 20 - /var/www | ssh XYZ -l root dd of=/dev/rmt/0hn obs=20b
where XYZ is the machine name with the tape drive. I backup several file systems from the remote machine this way, and thus I belive I am creating several volumes on the tape. When doing the last volume I use the /dev/rmt/0h (norewind) device instead of the rewind device.
If I want to restore from the first volume I use: dd if=/dev/rmt/0h | tar xvBfb - 20 Filename
How do I restore something from the second or latter volumes. I tried using mt fsf 1 and then doing the above dd | tar command and no luck.
Any suggestions would be greatly appreciated.
Sorry for the complexity of this posting!

You must always use the norewind device when writing/reading sequencial archives (volumes) from a tape. For example, if you wrote two archives on a tape and then wanted to restore the 2nd archive:
|Archive_1 |Archive_2 |.....
and positioned the tape with:
# mt -f /dev/rmt/0n fsf 1and then tried to restore it with:
# tar xvf /dev/rmt/0As soon as you open tape device /dev/rmt/0, it will rewind. So you have to use /dev/rmt/0n
I would just get in the habit of always using the norewind device. You can rewind with the mt command when finished.

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |