From owner-freebsd-questions@FreeBSD.ORG Tue Aug 26 20:47:37 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A14B216A4BF; Tue, 26 Aug 2003 20:47:37 -0700 (PDT) Received: from tevn.com (www.tevn.com [203.39.125.34]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0170243F93; Tue, 26 Aug 2003 20:47:36 -0700 (PDT) (envelope-from jennifer@tevn.com) Received: from jennifertoshiba ([10.10.10.193]) by tevn.com (8.11.3/8.11.3) with SMTP id h7R3ojP00754; Wed, 27 Aug 2003 13:50:46 +1000 (EST) (envelope-from jennifer@tevn.com) Message-ID: <005301c36c4d$f308fd00$c10a0a0a@jennifertoshiba> From: "Jennifer" To: Date: Wed, 27 Aug 2003 13:47:33 +1000 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_0050_01C36CA1.C47B1140" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 cc: freebsd-newbies@freebsd.org Subject: freebsd boot and fsck problem X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Aug 2003 03:47:37 -0000 This is a multi-part message in MIME format. ------=_NextPart_000_0050_01C36CA1.C47B1140 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Dear FreeBSD people I started to learn and used FreeBSD from last year. And I found FreeBSD is really very powerful and lovely. But I am also a little scared of it, for then it has problem, I just do not know how to fix it. Here I came up a big emergent problem this morning, and I wish you can give me your precious advice and help. I have been using a script drivecopy.sh for a couple of months to do full backup once a week. This drivecopy.sh is a small scripts to copy whole IDE HDD (of freeBSD) to another HDD. Please have a look at the attached script drivecopy.sh It worked very fine till yesterday. Last night, As usual,I started ./drivecopy.sh to backup my FreeBSD4.3 server (Disk1) on another HDD(Disk2). Disk2 has been used successfully as backup for more than 10 times with same procedure of ./drivecopy.sh. So it seemed the start up going smoothly, then I left the server room. This morning, when I came to check the server and backup. (which was supposed to have finished). And I surprised to find all those horrible error messages on the console screen: ***start to quote error message ad0s2e: had error reading fsbn 97103692 of 3473456-3473467(ad0s2 bn 97103692; cn 6044 fn 108 sn 28) status=59 error=40 cannot read: BLK 3473456 UNEXPECTED SOFT UPDATE INCONSISTENCY. **end of error message quote So I had to force to suspend the backup process by pressing Ctrl+Z. Then I tried to reboot Disk1. I had problem during the booting process. **start to quote error message .... chflags: not found chown: not found cd: can't cd to /var/run cd: can't cd to /var/spool/lock /etc/rc: cann't create /var/run/dmesg.boot directory nonexistent cd: can't cd to /var/run /etc/rc: cannot ceate /var/run/clean_var:dirctory nonexitent. Enter full path of shell or return for /bin/sh ..... **end of error message quote Then I just press Enter and came to the single boot mode. I typed the following command to try to munually fsck the problem partition. #fsck /dev/ad0s2e The console then showed the following message. **/dev/ad0s2e **Last mounted on /www **Phase 1 -check block & size cannot read: BLK 19596336 UNEXPECTED SOFT UPDATE INCONSISTENCY continue [y/n] ....... Looks like the manual fsck doesn't working here. Then I tried my luck to boot Disk2.Unfortunately, it showed the same errors as Disk2 during booting. Your advice will be highly appreciated. Jennifer P.S. The attached is my drivecopy.sh,which had worked fine for the previous backup processes except yesterday. So I do not think anything wrong with the drivecopy.sh itself. There must be something wrong with my yesterday's backup process, though I can not find out what it is. ------=_NextPart_000_0050_01C36CA1.C47B1140 Content-Type: application/octet-stream; name="drivecopy.sh" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="drivecopy.sh" #!/bin/sh=0A= newfs /dev/ad1s1a=0A= newfs /dev/ad1s2g=0A= newfs /dev/ad1s2f=0A= newfs /dev/ad1s1g=0A= newfs /dev/ad1s1e=0A= newfs /dev/ad1s1f=0A= newfs /dev/ad1s2e=0A= =0A= mount /dev/ad1s1a /back/root=0A= mount /dev/ad1s2g /back/backup=0A= mount /dev/ad1s2f /back/ftp =0A= mount /dev/ad1s1g /back/home=0A= mount /dev/ad1s1e /back/usr =0A= mount /dev/ad1s1f /back/var =0A= mount /dev/ad1s2e /back/www =0A= =0A= ( dump -0f - / ) | ( cd /back/root ; restore -rf - )=0A= ( dump -0f - /backup ) | ( cd /back/backup ; restore -rf - )=0A= ( dump -0f - /ftp ) | ( cd /back/ftp ; restore -rf - )=0A= ( dump -0f - /home ) | ( cd /back/home ; restore -rf - )=0A= ( dump -0f - /usr ) | ( cd /back/usr ; restore -rf - )=0A= ( dump -0f - /var ) | ( cd /back/var ; restore -rf - )=0A= ( dump -0f - /www ) | ( cd /back/www ; restore -rf - )=0A= =0A= umount /back/root=0A= umount /back/backup=0A= umount /back/ftp=0A= umount /back/home=0A= umount /back/usr=0A= umount /back/var=0A= umount /back/www=0A= =0A= tunefs -n enable /dev/ad1s1a=0A= tunefs -n enable /dev/ad1s2g=0A= tunefs -n enable /dev/ad1s2f =0A= tunefs -n enable /dev/ad1s1g =0A= tunefs -n enable /dev/ad1s1e =0A= tunefs -n enable /dev/ad1s1f =0A= tunefs -n enable /dev/ad1s2e =0A= =0A= #end=0A= ------=_NextPart_000_0050_01C36CA1.C47B1140--