From owner-freebsd-questions@FreeBSD.ORG Fri Feb 23 16:08:31 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D404A16A403 for ; Fri, 23 Feb 2007 16:08:31 +0000 (UTC) (envelope-from martster@gmail.com) Received: from wr-out-0506.google.com (wr-out-0506.google.com [64.233.184.235]) by mx1.freebsd.org (Postfix) with ESMTP id 8EA5413C4B3 for ; Fri, 23 Feb 2007 16:08:31 +0000 (UTC) (envelope-from martster@gmail.com) Received: by wr-out-0506.google.com with SMTP id i22so533636wra for ; Fri, 23 Feb 2007 08:08:31 -0800 (PST) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=GSWnpiNIGXClQwS+kA3bUq6e93P620xXSZQSmtqFNj5pWzE5+bPA+3FS/tQMxw4kzW4AU+NBCPcyUYVCXi2r3tOQyiYoqkyG7uvbmFvBj2p5j5KFwGTaIHTN8121eprBaBN9ijUkM3k7XjgE4jbm3PVbcbWi24vPZx8b+XgLoXQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=fJVzc85Zs4Tljz/MImaU+iek+MoU+EN6oXiX5VL6N91QztN+Hlu8d1P1uSOm9YPe5ukCLw0+yoHYGHbE52PehcLbQBFM2z9tUg7cigIueNprEBqrcEZXs/RcMnGcmDVRsxYIG2OqWirK+lNyzMh9DtVm+fFYocdxFlM9eGqZPYQ= Received: by 10.114.124.1 with SMTP id w1mr971042wac.1172246909809; Fri, 23 Feb 2007 08:08:29 -0800 (PST) Received: by 10.114.132.1 with HTTP; Fri, 23 Feb 2007 08:08:29 -0800 (PST) Message-ID: <70063950702230808h433f61cscfd1abe43b578292@mail.gmail.com> Date: Fri, 23 Feb 2007 11:08:29 -0500 From: "Marty Landman" To: "Ian Smith" In-Reply-To: MIME-Version: 1.0 References: <20070223054641.12DD316A41B@hub.freebsd.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-questions@freebsd.org Subject: Re: input/output error on hd X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Feb 2007 16:08:31 -0000 On 2/23/07, Ian Smith wrote: So just show 'fdisk ad1' to see the disk's partition (slice) table (which > may be damaged, but it's the only one you're interested in). %sudo fdisk ad1 ******* Working on device /dev/ad1 ******* parameters extracted from in-core disklabel are: cylinders=486344 heads=16 sectors/track=63 (1008 blks/cyl) Figures below won't work with BIOS for partitions not in cyl 1 parameters to be used for BIOS calculations are: cylinders=486344 heads=16 sectors/track=63 (1008 blks/cyl) Media sector size is 512 Warning: BIOS sector numbering starts with sector 1 Information from DOS bootblock is: The data for partition 1 is: sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) start 63, size 490223412 (239366 Meg), flag 80 (active) beg: cyl 0/ head 1/ sector 1; end: cyl 1023/ head 254/ sector 63 The data for partition 2 is: The data for partition 3 is: The data for partition 4 is: % If 'fdisk ad1' isn't showing any sensible data for 'partition 1' (ad1s1) > then your boot sector is hosed. Does the above result mean that my boot sector is ok? > %sudo fsck /dev/ad1cs1 > > fsck: Could not determine filesystem type > > %sudo fsck /dev/ad1c > > fsck: exec fsck_unused for /dev/ad1c in /sbin:/usr/sbin: No such file or > > directory > > You shouldn't be doing any of this with the 'c' partition, which is meant > to cover the whole disk, but doesn't describe any of its slices. Unfortunately I had incorrectly been using ad1s1c for this disk, is there anything I can do about it now? Would that help with the effort to recover the data? I gather you think your data should be on ad1s1. Does 'bsdlabel ad1s1' say > anything sensible? %sudo bsdlabel ad1s1 # /dev/ad1s1: 8 partitions: # size offset fstype [fsize bsize bps/cpg] c: 490223412 0 unused 0 0 # "raw" part, don't edit % If not, does bsdlabel ad1s2, ad1s3 or ad1s4, if fdisk ad1 shows anything in > s2, s3 or s4. s2-4 all show "No such file or directory" for bsdlabel As you mentioned elsewhere, you appear to have a bunch of bad blocks early > on this disk. Yes, based on working with the dd cmd on /dev/ad1s1 and playing with the skip parm have found that blocks 129-144 give input/output errors. Does this indicate a hardware error necessarily? This problem came about as the result of a power outage; might there "just" be hosed data on those sectors? Have you a spare drive you can dd this one to, in its current state? No, it's a 250GB drive, the largest on my LAN. Would have to buy a replacement drive and then dd to that. If it came to that, while a backup hd might be a good idea, I'd possibly just live with recreating the data instead. What does 'ls -l /dev/ad1*' have to say? %ls -al /dev/ad1* crw-r----- 1 root operator 0, 70 Feb 22 17:56 /dev/ad1 crw-r----- 1 root operator 0, 74 Feb 22 17:56 /dev/ad1a crw-r----- 1 root operator 0, 75 Feb 22 17:56 /dev/ad1c crw-r----- 1 root operator 0, 82 Feb 22 17:56 /dev/ad1cs1 crw-r----- 1 root operator 0, 94 Feb 22 17:56 /dev/ad1cs1c crw-r----- 1 root operator 0, 73 Feb 22 17:56 /dev/ad1s1 crw-r----- 1 root operator 0, 84 Feb 22 17:56 /dev/ad1s1c > And please don't top-post .. Sorry about that Ian, appreciate your help. Marty -- Web Installed Formmail - http://face2interface.com/formINSTal/ Webmaster's BBS - http://bbs.face2interface.com/