From owner-freebsd-bugs Wed Apr 12 9:18:52 2000 Delivered-To: freebsd-bugs@freebsd.org Received: from aaz.links.ru (aaz.links.ru [193.125.152.37]) by hub.freebsd.org (Postfix) with ESMTP id 8CFAA37BBF8 for ; Wed, 12 Apr 2000 09:16:36 -0700 (PDT) (envelope-from babolo@links.ru) Received: (from babolo@localhost) by aaz.links.ru (8.9.3/8.9.3) id UAA09489; Wed, 12 Apr 2000 20:15:30 +0400 (MSD) Message-Id: <200004121615.UAA09489@aaz.links.ru> Subject: Re: freebsd 3.4 disklabel bug In-Reply-To: <38F354BA.F633075A@algroup.co.uk> from "Adam Laurie" at "Apr 11, 0 05:37:14 pm" To: adam@algroup.co.uk (Adam Laurie) Date: Wed, 12 Apr 2000 20:15:30 +0400 (MSD) Cc: freebsd-bugs@FreeBSD.ORG From: "Aleksandr A.Babaylov" MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Adam Laurie writes: > FreeBSD stranger.aldigital.co.uk 3.4-RELEASE FreeBSD 3.4-RELEASE #1: Mon > Apr 10 14:57:49 GMT 2000 > root@stranger.aldigital.co.uk:/usr/src/sys/compile/STRANGER i386 > > > ...on an IDE drive, it wrongly decides to use 1 more cylinder than it > actually has: > > root@stranger /root# disklabel -r wd1 > # /dev/rwd1c: > type: ESDI > disk: wd1s1 > label: > flags: > bytes/sector: 512 > sectors/track: 63 > tracks/cylinder: 255 > sectors/cylinder: 16065 > cylinders: 2491 > sectors/unit: 40032696 > rpm: 3600 > interleave: 1 > trackskew: 0 > cylinderskew: 0 > headswitch: 0 # milliseconds > track-to-track seek: 0 # milliseconds > drivedata: 0 > > 8 partitions: > # size offset fstype [fsize bsize bps/cpg] > c: 40032696 0 unused 0 0 # (Cyl. 0 - > 2491*) > e: 40032696 0 4.2BSD 1024 8192 16 # (Cyl. 0 - > 2491*) ------^ asterick mean that not full cylinder 0skiv~(1)>dc 16065 2491 *p 40017915 40032696 40017915 -p 14781 so 2491 cylinders full and part of one more cylinder. > note that it thinks it has 2491 cylinders, but then uses 0 - 2491, i.e. > 2492. > > This will go unnoticed if your offending partition is swap, as it > doesn't try to write to swap until it errr... swaps. However, if you > have a 2nd hard disk, and you allocate the entire disk, you will be > unable to newfs it (from dmesg): > > wd1e: hard error writing fsbn 40031999 (wd1 bn 40031999; cn 2491 tn > 223 sn 35) (status 51 error 10) what dmesg say about disk size? I often use disks in such a way - with not full last cylinder. It needs apply right -t -u -c to use whole disk. > Setting it to this: > > # size offset fstype [fsize bsize bps/cpg] > c: 40032696 0 unused 0 0 # (Cyl. 0 - > 2491*) > e: 40016631 0 4.2BSD 1024 8192 16 # (Cyl. 0 - > 2490*) what about e: 40031999 0 ? may be full disk size is 40032000? > cures the problem. > > Apologies if this is already known... I'm not a regular subscriber to > this list... -- @BABOLO http://links.ru/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message