Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 12 Apr 2000 20:15:30 +0400 (MSD)
From:      "Aleksandr A.Babaylov" <babolo@links.ru>
To:        adam@algroup.co.uk (Adam Laurie)
Cc:        freebsd-bugs@FreeBSD.ORG
Subject:   Re: freebsd 3.4 disklabel bug
Message-ID:  <200004121615.UAA09489@aaz.links.ru>
In-Reply-To: <38F354BA.F633075A@algroup.co.uk> from "Adam Laurie" at "Apr 11, 0 05:37:14 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
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<rdy,seekdone,err> error 10<no_id>)
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




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200004121615.UAA09489>