Amanda-Users

Re: SMB backups of windows boxes

2003-04-10 13:34:43
Subject: Re: SMB backups of windows boxes
From: "Tom Brown" <tom.brown AT goodtechnology DOT com>
To: "Laas Toom" <laas AT haldjas.folklore DOT ee>, <amanda-users AT amanda DOT org>
Date: Thu, 10 Apr 2003 17:04:27 +0100
> > Hi,
> >
> > Seems i posted the wrong error! I just tried a restore now and this is
> > exactly what i get, apart from machine names......
> >
> > -- snip --
> > amrestore:  27: skipping xxxxxxx._dev_rd_c0d0p5.20030402.1
> > amrestore:  28: skipping xxxxxxx._dev_sda1.20030402.1
> > amrestore:  29: skipping xxxxxxx._dev_rd_c0d0p5.20030402.1
> > amrestore:  30: restoring xxxxx.__xxxxx_web__stage.20030402.1
> > restore: Tape is not a dump tape
> > Error 32 (Broken pipe) offset 32768+32768, wrote 0
> > amrestore: pipe reader has quit in middle of file.
> > amrestore: skipping ahead to start of next file, please wait...
> >
> > and then it exits to the shell
>
> This looks familiar to me.
>
> Once i had this kind of error. just restore denies that the backup is done
> with dump, though it really was.
>
> I did this:
>
> (i saw, that the file you need is 30th on the tape)
>
> $mt -f norewind-tapedev fsf 30
> $dd if=norewind-tapedev bs=32k of=/direcory/with/lotsof/room/bigfile
>
> now
> $cd /directory/with/lotsof/room
> $dd if=bigfile bs=32k count=1
>
> (this outputs the amanda header, where is written with what you need to
> restore the backup with).
>
> $amrestore bigfile
> (this outputs a file, similar to machine.usr.20030312.0)
>
> (lets say you need to restore with RESTORE):
> $restore -x -f machine.usr.20030312.0
> (this restores all of the files in the dump to the current directory. See
> restore(8) for other options, -i for example)
>
> If the last 'dd'-phrase states that you need to restore with TAR, then
> most (if not all) of this text is worthless to you and you just have to
> replace the 'restore' part with appropriate 'tar' part in your restore
> command.
>
> To others - can anyone explain me, how is this possible that restore
> woulnd't accept file amrestored from tape, but accepted the file
> amrestored from a file read from tape with dd (they should be the same
> IMHO).
>
> Laas Toom

I have tried this as you suggested - different tape this time as i was
trying to get a level0.... Seems that the wrong partition is being
advertised in the header?


[operator@xxxxxx restore]$ mt -f /dev/nst0 rewind
[operator@xxxxxx restore]$ amrestore -p /dev/nst0 xxxxxx //xxxxxx/web |
restore ivf -
Verify tape and initialize maps
amrestore:   0: skipping start of tape: date 20030404 label gthost06
amrestore:   1: skipping xxxxxx._dev_sda2.20030404.1
amrestore:   2: skipping xxxxxx.sda2.20030404.1
amrestore:   3: skipping xxxxxx.sdb6.20030404.1
amrestore:   4: skipping xxxxxx._dev_rd_c0d0p3.20030404.1
amrestore:   5: skipping xxxxxx._dev_sda5.20030404.1
amrestore:   6: skipping xxxxxx.sda6.20030404.1
amrestore:   7: skipping xxxxxx.sda3.20030404.1
amrestore:   8: skipping xxxxxx.sdb3.20030404.1
amrestore:   9: skipping xxxxxx._dev_rd_c0d0p5.20030404.2
amrestore:  10: skipping xxxxxx._dev_sda2.20030404.2
amrestore:  11: skipping xxxxxx._dev_rd_c0d0p5.20030404.1
amrestore:  12: restoring xxxxxx.__xxxxx_web__stage.20030404.1
restore: Tape is not a dump tape
Error 32 (Broken pipe) offset 32768+32768, wrote 0
amrestore: pipe reader has quit in middle of file.
amrestore: skipping ahead to start of next file, please wait...
[operator@xxxxxx restore]$ mt -f /dev/nst0 fsf 13
[operator@xxxxxx restore]$ dd if=/dev/nst0 bs=32k
of=/opt/amanda/restore/xxxxxx_restore
18125+0 records in
18125+0 records out
[operator@xxxxxx restore]$ dd if=xxxxxx_restore bs=32k count=1
AMANDA: FILE 20030404 wrongmachinename sda3 lev 2 comp .gz program
/sbin/dump
To restore, position tape at start of file and run:
        dd if=<tape> bs=32k skip=1 | /bin/gzip -dc | sbin/restore -f... -


1+0 records in
1+0 records out
[operator@xxxxxx restore]$

as you can see from the amanda header - its saying the wrongmachinename in
the header even though restore stopped at file 13?

any thoughts?

Tom