LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
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.

Notices


Reply
  Search this Thread
Old 03-28-2012, 02:16 PM   #1
rperlberg
LQ Newbie
 
Registered: May 2006
Posts: 18

Rep: Reputation: 0
xfsrestore -t -- Why is it reading the whole tape?


I have a lot of experience with the dump and restore utilities, and one of the things I love about dump is that it writes the whole table of contents to the beginning of the first tape so you can get a table of contents listing without having to read the whole archive. I've started experimenting with xfsdump under Linux and I am confused. When I do an "xfsrestore -t" it seems to have to read through all of the volumes of the dump to produce the table of contents. But, when I do "xfsrestore -i", it lets me navigate the hierarchy after just reading the beginning of the first tape. Why does "xfsrestore -t" have to read the whole archive?
 
Old 03-29-2012, 07:23 AM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
Most UNIX/Linux commands have manual (man) pages.

Typing "man xfsrestore" could help.

I don't use xfsrestore but found its man page online at:
http://linux.die.net/man/8/xfsrestore

Based on my read of that you should use the -I option rather than the -t.

Extracts from that:

Quote:
-I

Causes the xfsdump inventory to be displayed (no restore is performed). Each time xfsdump is used, an online inventory in /var/lib/xfsdump/inventory is updated. This is used to determine the base for incremental dumps. It is also useful for manually identifying a dump session to be restored (see the -L and -S options). Suboptions to filter the inventory display are described later.
Quote:
An additional media file is placed at the end of each dump stream. This media file contains the inventory information for the current dump session. If the online inventory files in /var/lib/xfsdump/inventory are missing information for the current dump session, then the inventory information in the media file is automatically added to the files in /var/lib/xfsdump/inventory. If you wish to incorporate the inventory information from the media file without restoring any data, you may do so using the -t option:

# xfsrestore -t -f /dev/tape

This is useful to rebuild the inventory database if it is ever lost or corrupted. The only caveat is that xfsrestore needs to read through the entire dump in order to reach the inventory media file. This could become time consuming for dump sessions with large media files.
The latter discussion of -t clearly indicates it will read the entire dump to find the inventory at the end rather than using the one on your system as -I apparently does.

Last edited by MensaWater; 03-29-2012 at 07:24 AM.
 
Old 04-19-2021, 01:09 AM   #3
rperlberg
LQ Newbie
 
Registered: May 2006
Posts: 18

Original Poster
Rep: Reputation: 0
But why?
 
Old 04-20-2021, 03:01 PM   #4
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,978

Rep: Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624
"rebuild the inventory database"

https://access.redhat.com/documentat...sbackuprestore
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
need help reading data files from DDS-4 SCSI tape empulse Linux - Software 1 05-29-2009 04:47 PM
Debugging slow tape: Big disparity between iostat and tape speed wsanders Linux - Server 2 05-23-2009 09:02 AM
Reading the Contents of a Dump Tape kaplan71 Linux - General 2 11-08-2006 02:34 PM
reading back a tape Wimpie22 Linux - General 1 09-13-2003 07:15 PM
Reading from a tape backup jmarsh Linux - Networking 4 02-19-2003 03:33 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

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