Re: amanda-20070530 amrecover problem with restoring from older amanda version.

2007-06-06 Thread Jean-Louis Martineau

Robert,

Did you configure with --with-maxtapeblocksize? What is the value?
What is your blocksize setting in the tapetype?
Did the tape labeled D5 was written with the same blocksize?

Can you try the attached patch.

Jean-Louis

McGraw, Robert P. wrote:


Jean-Louis,

 


Here is the amidxtaped that you requested.

 

   



amidxtaped: short file header block: 32768 bytes

Not an amanda tape




diff -u -r --show-c-function --new-file --exclude-from=/home/martinea/src.orig/amanda.diff --ignore-matching-lines='$Id:' amanda-2.5.2/restore-src/restore.c amanda-2.5.2.restore/restore-src/restore.c
--- amanda-2.5.2/restore-src/restore.c	2007-05-04 07:39:06.0 -0400
+++ amanda-2.5.2.restore/restore-src/restore.c	2007-06-06 10:31:55.0 -0400
@@ -647,7 +647,7 @@ read_file_header(
 	fprintf(stderr, %s: error reading file header: %s\n,
 		get_pname(), strerror(errno));
 	file-type = F_UNKNOWN;
-} else if((size_t)bytes_read  blocksize) {
+} else if((size_t)bytes_read  DISK_BLOCK_BYTES) {
 	if(bytes_read == 0) {
 	fprintf(stderr, %s: missing file header block\n, get_pname());
 	} else {


Re: amanda-20070530 amrecover problem with restoring from older amanda version.

2007-06-01 Thread Jean-Louis Martineau

What's in the amidxtaped.*.debug on the server?

Jean-Louis

McGraw, Robert P. wrote:


My configuration:

build: VERSION=Amanda-2.5.2-20070530

BUILT_DATE=Thu May 31 09:14:26 EDT 2007

BUILT_MACH=SunOS zorn.math.purdue.edu 5.10 Generic_118833-03 sun4u 
sparc SUNW,Sun-Fire-280R


CC=/pkgs/gcc-3.4.3/bin/gcc

CONFIGURE_COMMAND='./configure' 'CC=/pkgs/gcc-3.4.3/bin/gcc' 
'MT=/opt/csw/bin/mt' 'MTF=-f' 'MTX=/opt/csw/sbin/mtx' 
'PERL=/opt/csw/bin/perl' 
'--prefix=/local/Amanda/amanda-2.5.2-20070530' '--with-user=amanda' 
'--with-group=operator' '--with-gnutar=/opt/csw/bin/gtar' 
'--with-gnutar-listdir=/var/amanda/gnutar-lists' 
'--with-includes=/opt/csw/include' '--with-libraries=/opt/csw/lib' 
'--with-index-server=zorn' 
'--with-smbclient=/pkgs/samba/bin/smbclient' 
'--with-tape-device=/dev/rmt/1bn' 
'--with-changer-device=/dev/changer/1' '--with-maxtapeblocksize=2048'


paths: bindir=/local/Amanda/amanda-2.5.2-20070530/bin

sbindir=/local/Amanda/amanda-2.5.2-20070530/sbin

libexecdir=/local/Amanda/amanda-2.5.2-20070530/libexec

mandir=/local/Amanda/amanda-2.5.2-20070530/man

AMANDA_TMPDIR=/tmp/amanda AMANDA_DBGDIR=/tmp/amanda

CONFIG_DIR=/local/Amanda/amanda-2.5.2-20070530/etc/amanda

DEV_PREFIX=/dev/dsk/ RDEV_PREFIX=/dev/rdsk/

DUMP=/usr/sbin/ufsdump RESTORE=/usr/sbin/ufsrestore

VDUMP=UNDEF VRESTORE=UNDEF XFSDUMP=UNDEF XFSRESTORE=UNDEF

VXDUMP=UNDEF VXRESTORE=UNDEF

SAMBA_CLIENT=/pkgs/samba/bin/smbclient

GNUTAR=/opt/csw/bin/gtar COMPRESS_PATH=/bin/gzip

UNCOMPRESS_PATH=/bin/gzip LPRCMD=/local/bin/lpr

MAILER=/usr/ucb/Mail

listed_incr_dir=/var/amanda/gnutar-lists

defs: DEFAULT_SERVER=zorn DEFAULT_CONFIG=DailySet1

DEFAULT_TAPE_SERVER=zorn

DEFAULT_TAPE_DEVICE=/dev/rmt/1bn NEED_STRSTR HAVE_SYSVSHM

LOCKING=**NONE** SETPGRP_VOID DEBUG_CODE AMANDA_DEBUG_DAYS=4

BSD_SECURITY RSH_SECURITY USE_AMANDAHOSTS

CLIENT_LOGIN=amanda FORCE_USERID HAVE_GZIP

COMPRESS_SUFFIX=.gz COMPRESS_FAST_OPT=--fast

COMPRESS_BEST_OPT=--best UNCOMPRESS_OPT=-dc

I tested amrecover on a file that was backed up with amanda-20070530 
and had no problem.


Today I tried to do a amrecover on a file the was backed up with 
amanda-2.5.1p2 and get the following:


Extracting files using tape drive /dev/rmt/1bn on host zorn.

Load tape D5 now

Continue [?/Y/n/s/t]? y

Not an amanda tape

Looking for tape D5...

Not an amanda tape

Load tape D5 now

Continue [?/Y/n/t]? y

Not an amanda tape

Not an amanda tape

Looking for tape D5...

^[[ANot an amanda tape

Load tape D5 now

Continue [?/Y/n/t]? y

Continue [?/Y/n/t]?

Not an amanda tape

Not an amanda tape

Looking for tape D5...

Not an amanda tape

Load tape D5 now

Continue [?/Y/n/t]? n

The following is from amrecover.20070601151822.debug:

amidxtaped_streams[0].fd = 810a0

amrecover: time 353.630: security_streaminit(stream=8bf88, 
driver=ff2d8f6c (BSD))


amrecover: time 353.635: connect_port: Try port 0: Available -

amrecover: time 353.635: connected to 128.210.3.177.50856

amrecover: time 353.635: our side is 0.0.0.0.50860

amrecover: time 353.635: try_socksize: send buffer size is 65536

amrecover: time 353.635: try_socksize: receive buffer size is 65536

amidxtaped_streams[1].fd = 8bf88

amrecover: time 353.635: security_close(handle=7d2f8, driver=ff2d8f6c 
(BSD))


amrecover: time 581.477: security_stream_close(8bf88)

amrecover: time 581.478: Can't read file header

amrecover: time 581.479: pid 2521 finish time Fri Jun 1 15:28:03 2007

amrecover: time 581.484: security_stream_close(810a0)

amrecover: time 822.433: security_stream_close(732d8)

amrecover: time 822.434: pid 1863 finish time Fri Jun 1 15:32:04 2007

which seems to fit “Not an amanda tape” message from the amrecover script.

I do not remember seeing anything about this any of the amanda-users 
forum but could have over looked.


Robert

_

Robert P. McGraw, Jr.

Manager, Computer System EMAIL: [EMAIL PROTECTED]

Purdue University ROOM: MATH-807

Department of Mathematics PHONE: (765) 494-6055

150 N. University Street FAX: (419) 821-0540

West Lafayette, IN 47907-2067