From owner-freebsd-fs@FreeBSD.ORG Thu Jun 2 09:31:35 2005 Return-Path: X-Original-To: freebsd-fs@freebsd.org Delivered-To: freebsd-fs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 602BF16A41C for ; Thu, 2 Jun 2005 09:31:35 +0000 (GMT) (envelope-from ut@bhi-hamburg.de) Received: from mail.terralink.de (mail.tlink.de [217.9.16.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id E3AB143D1F for ; Thu, 2 Jun 2005 09:31:34 +0000 (GMT) (envelope-from ut@bhi-hamburg.de) Received: from schweinkram.pleach-hamburg.de (p548EE00B.dip.t-dialin.net [84.142.224.11]) by mail.terralink.de (Postfix) with ESMTP id BA641B8F6 for ; Thu, 2 Jun 2005 11:31:36 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by schweinkram.pleach-hamburg.de (Postfix) with ESMTP id C47BB6A2E43; Thu, 2 Jun 2005 11:29:13 +0200 (CEST) Received: from by localhost (amavisd-new, port ) id cOhRqN2t; Thu, 2 Jun 2005 11:29:12 +0200 (CEST) Received: by schweinkram.pleach-hamburg.de (Postfix, from userid 65534) id 532EC6A22CE; Thu, 2 Jun 2005 11:29:12 +0200 (CEST) Received: from titusn (titusn.pleach-hamburg.de [192.168.1.19]) by schweinkram.pleach-hamburg.de (Postfix) with SMTP id 388506A17FE; Thu, 2 Jun 2005 11:29:10 +0200 (CEST) From: "Titus von Boxberg" To: Date: Thu, 2 Jun 2005 11:32:00 +0200 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2911.0) X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527 Importance: Normal X-Spam-Checker-Version: SpamAssassin 2.60 (1.212-2003-09-23-exp) on schweinkram.pleach-hamburg.de X-Spam-Status: No, hits=0.0 required=5.0 tests=BAYES_50 autolearn=no version=2.60 X-Spam-Level: X-Virus-Scanned: by amavisd-new at pleach-hamburg.de Subject: Inconsistent snapshot contents during backup X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Jun 2005 09:31:35 -0000 Hi there, on two servers we do daily backups onto a tape of a mounted snapshot via tar. The problem is that on both machines almost always one or a few files differ. Here's what we do: #!/bin sh .... mksnap_ffs / /.snap/backupsnap mdconfig -a -t vnode -f /.snap/backupsnap -u 5 mount -o ro /dev/md5 /mnt cd /mnt cp fileinquestion /tmp/x1 # see below tar cf /dev/sa0 .... cp fileinquestion /tmp/x2 # see below tar df /dev/sa0 .... if [ $? -eq 1 ] ; then # see below tar -C /tmp -xf /dev/sa0 fileinquestion mv /tmp/fileinquestion /tmp/x3 fi .... On both machines, the second tar complains that the contents of a file is differing (but not the size). It's always the same file (a cyrus imap database). To see whats happening, we copied the file immediately after the mount of the snapshot into a directory outside the snapshot, also took a copy of the snapshotted file after the backup tar and read back the file from tape after the complaint of the verifying tar (see indented code above). We noticed that almost always none of the copies (x1, x2, x3) were identical. This means that also the files x1 and x2 that are never copied and read back to/from tape differ. We tried to analyze the differences over several days but could not see anything magical. Is there anything wrong with the script or the underlying assumptions ? If not, any ideas what could we do to analyze the problem? The system on the first machine is 5.2.1 RELEASE, the system on the second is 5.3 RELEASE Cheers Titus