Usenet comp.unix.osf.misc (1992-2004)
 help / color / mirror / Atom feed
* testing dump validity
@ 1998-09-09  4:00 Bob FIndlay
  1998-09-10  4:00 ` Rev. Don Kool
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Bob FIndlay @ 1998-09-09  4:00 UTC (permalink / raw)


Hello,
Does anyone have any recommendations on how to test the validity of a
dump file?  On VMS I would have performed a restore to the NUL device
and then checked for any errors, but I can't see how to do that with DEC
unix's restore.

thanks in advance
Bob




^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: testing dump validity
  1998-09-09  4:00 testing dump validity Bob FIndlay
@ 1998-09-10  4:00 ` Rev. Don Kool
  1998-09-10  4:00   ` Emil Visdal
  1998-09-10  4:00   ` Alan Rollow - Dr. File System's Home for Wayward Inodes.
  1998-09-10  4:00 ` Thomas Leitner
  1998-09-10  4:00 ` Alan Rollow - Dr. File System's Home for Wayward Inodes.
  2 siblings, 2 replies; 6+ messages in thread
From: Rev. Don Kool @ 1998-09-10  4:00 UTC (permalink / raw)


Bob FIndlay wrote:
> 
> Hello,
> Does anyone have any recommendations on how to test the validity of a
> dump file?  On VMS I would have performed a restore to the NUL device
> and then checked for any errors, but I can't see how to do that with DEC
> unix's restore.

	Do the restore (restore or vrestore) with the "-i" option (for
interactive).  Then you can "cd" and "ls" around the archive much
like with "ftp".  If you just get to the interactive prompt, chances
are that your backup is good.

			Hope this helps,
			      Don


--
**********************      You a bounty hunter?
* Rev. Don McDonald  *      Man's gotta earn a living.
* Baltimore, MD      *      Dying ain't much of a living, boy.
**********************             "Outlaw Josey Wales"
http://members.home.net/oldno7



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: testing dump validity
  1998-09-10  4:00 ` Rev. Don Kool
@ 1998-09-10  4:00   ` Emil Visdal
  1998-09-10  4:00   ` Alan Rollow - Dr. File System's Home for Wayward Inodes.
  1 sibling, 0 replies; 6+ messages in thread
From: Emil Visdal @ 1998-09-10  4:00 UTC (permalink / raw)


Rev. Don Kool skrev i meldingen <35F71D9C.2A984F27@home.com>...
>Bob FIndlay wrote:
>>
>> Hello,
>> Does anyone have any recommendations on how to test the validity of a
>> dump file?  On VMS I would have performed a restore to the NUL device
>> and then checked for any errors, but I can't see how to do that with DEC
>> unix's restore.
>
> Do the restore (restore or vrestore) with the "-i" option (for
>interactive).  Then you can "cd" and "ls" around the archive much
>like with "ftp".  If you just get to the interactive prompt, chances
>are that your backup is good.

WARNING:
The problem with this is that the media could be corrupt in the data area of
dump (and vdump), when you do an "restore -i" you just go to the index of
the dump. To check that the media and backup is OK, you should do a
"restore -t" first and after that a "dd" to /dev/null or faster a "mt fsf n"
where n is one more than the numbers of dump on the tape. "dd" is probably
safer than "mt"....

I have seen that "restore -t" works fine, but in the middle of the dump the
media was corrupt and it was not possible to restore the rest of that dump
area. In this case the tapedrive was bad, but only after writing about 1 GB.
This occurs on all of the tapes, but "restore -t" said it was OK....

^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Emil Visdal
These are my opinions not SNI's






^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: testing dump validity
  1998-09-09  4:00 testing dump validity Bob FIndlay
  1998-09-10  4:00 ` Rev. Don Kool
  1998-09-10  4:00 ` Thomas Leitner
@ 1998-09-10  4:00 ` Alan Rollow - Dr. File System's Home for Wayward Inodes.
  2 siblings, 0 replies; 6+ messages in thread
From: Alan Rollow - Dr. File System's Home for Wayward Inodes. @ 1998-09-10  4:00 UTC (permalink / raw)



In article <35F6584A.5D442313@uea.ac.uk>, Bob FIndlay <bob.findlay@uea.ac.uk> writes:

>Hello,
>Does anyone have any recommendations on how to test the validity of a
>dump file?  On VMS I would have performed a restore to the NUL device
>and then checked for any errors, but I can't see how to do that with DEC
>unix's restore.

You can read back the archive using dd(1).  Left to itself dump would
have used a 10 KB block size:

dd if=/dev/rmt#h of=/dev/null bs=10k

If you want to spot check for undetected data errors, restore some
files at random to a different file system and if they apparently
haven't changed with respect to the original compare them.

>Bob

--
Alan Rollow				alan@nabeth.cxo.dec.com




^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: testing dump validity
  1998-09-09  4:00 testing dump validity Bob FIndlay
  1998-09-10  4:00 ` Rev. Don Kool
@ 1998-09-10  4:00 ` Thomas Leitner
  1998-09-10  4:00 ` Alan Rollow - Dr. File System's Home for Wayward Inodes.
  2 siblings, 0 replies; 6+ messages in thread
From: Thomas Leitner @ 1998-09-10  4:00 UTC (permalink / raw)


In comp.unix.osf.osf1 Bob FIndlay <bob.findlay@uea.ac.uk> wrote:
> Hello,
> Does anyone have any recommendations on how to test the validity of a
> dump file?  On VMS I would have performed a restore to the NUL device
> and then checked for any errors, but I can't see how to do that with DEC
> unix's restore.

I do it like this:

mt -f /dev/nrmt0h rewind
checksum0=`vdump 0ubf 60 - /    | btee 60 /dev/nrmt0h | cksum`
checksum1=`vdump 0ubf 60 - /usr | btee 60 /dev/nrmt0h | cksum`
mt -f /dev/nrmt0h rewind
verify0=`dd if=/dev/nrmth0 ibs=60k obs=60k | cksum`
if [ "$checksum0" != "$verify0" ]; then
    echo ERROR: vdump / checksum failed. $checksum0 != $verify0
fi
verify1=`dd if=/dev/nrmth0 ibs=60k obs=60k | cksum`
if [ "$checksum1" != "$verify1" ]; then
    echo ERROR: vdump /usr checksum failed. $checksum0 != $verify0
fi

The trick is the "btee" program which is a "tee" program with
fixed 60k blocking input and output. I have written it just for
this purpose. Of course the whole story works with "dump" as well
and not only with "vdump" and you can even use it over the network
for remote backups and verifications where the verify pass does *not*
consume any network bandwidth:

checksum0=`vdump 0ubf 60 - / | rsh remote "btee 60 /dev/nrmt0h" | cksum"`
...
verify0=`rsh remote "dd if=/dev/nrmt0h ibs=60k obs=60k | cksum"`
....

Tom

BTW: "btee.c" can be had from my FTP server:

     ftp://finwds01.tu-graz.ac.at/pub/unix_utils/btee.c

-- 
--------------------------------------------------------------------------
T o m   L e i t n e r                       Dept. of Communications
                                            Graz University of Technology, 
e-mail    : tom@finwds01.tu-graz.ac.at      Inffeldgasse 12
Phone     : +43-316-873-7455                A-8010 Graz / Austria / Europe
Fax       : +43-316-463-697
Home page : http://wiis.tu-graz.ac.at/people/tom.html
PGP public key on : ftp://wiis.tu-graz.ac.at/pgp-keys/tom.asc or send 
mail with subject "get Thomas Leitner" to pgp-public-keys@keys.pgp.net
--------------------------------------------------------------------------
    Before we have the paperless office, we have the paperless toilet!



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: testing dump validity
  1998-09-10  4:00 ` Rev. Don Kool
  1998-09-10  4:00   ` Emil Visdal
@ 1998-09-10  4:00   ` Alan Rollow - Dr. File System's Home for Wayward Inodes.
  1 sibling, 0 replies; 6+ messages in thread
From: Alan Rollow - Dr. File System's Home for Wayward Inodes. @ 1998-09-10  4:00 UTC (permalink / raw)



In article <35F71D9C.2A984F27@home.com>, "Rev. Don Kool" <oldno7@home.com> writes:

>Bob FIndlay wrote:
>> 
>> Hello,
>> Does anyone have any recommendations on how to test the validity of a
>> dump file?  On VMS I would have performed a restore to the NUL device
>> and then checked for any errors, but I can't see how to do that with DEC
>> unix's restore.
>
>	Do the restore (restore or vrestore) with the "-i" option (for
>interactive).  Then you can "cd" and "ls" around the archive much
>like with "ftp".  If you just get to the interactive prompt, chances
>are that your backup is good.

Not really.  Dump writes a directory of the contents of the archive
at the beginning with the data after.  It would be easy for the few
blocks of the backup, and the thus the directory to be fine, but the
rest be garbage.  If you want to be sure the whole thing can be read,
read the whole thing.
>
--
Alan Rollow				alan@nabeth.cxo.dec.com




^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~1998-09-10  4:00 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1998-09-09  4:00 testing dump validity Bob FIndlay
1998-09-10  4:00 ` Rev. Don Kool
1998-09-10  4:00   ` Emil Visdal
1998-09-10  4:00   ` Alan Rollow - Dr. File System's Home for Wayward Inodes.
1998-09-10  4:00 ` Thomas Leitner
1998-09-10  4:00 ` Alan Rollow - Dr. File System's Home for Wayward Inodes.

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox