From owner-freebsd-current@FreeBSD.ORG Mon Nov 14 13:48:55 2005 Return-Path: X-Original-To: current@freebsd.org Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E1C5616A41F for ; Mon, 14 Nov 2005 13:48:55 +0000 (GMT) (envelope-from sullrich@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.192]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2997743D46 for ; Mon, 14 Nov 2005 13:48:55 +0000 (GMT) (envelope-from sullrich@gmail.com) Received: by zproxy.gmail.com with SMTP id i11so1300348nzi for ; Mon, 14 Nov 2005 05:48:53 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=A9RXxyyxsgJAQRzVS5nRA0SayyknYtuFRp6VRTsyyTQ5DzYvHM2oMHcamHpj4/4cVYKMo9gwjLGBntiNJmFqU6LZ2Jor1kHpqlNFO9BFEBtm9imcmX9EB/Z0bUkOwTDQ+CyFRouHw7j+eui5EoknFAcRfrtSdmrOer7On2vH8p4= Received: by 10.65.233.6 with SMTP id k6mr5685055qbr; Mon, 14 Nov 2005 05:48:53 -0800 (PST) Received: by 10.64.184.1 with HTTP; Mon, 14 Nov 2005 05:48:53 -0800 (PST) Message-ID: Date: Mon, 14 Nov 2005 08:48:53 -0500 From: Scott Ullrich To: Deomid Ryabkov In-Reply-To: <43785A97.3010204@rojer.pp.ru> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <20051027200448.1ba236fe.cpressey@catseye.mine.nu> <43753528.7030802@freesbie.org> <20051114091911.GD64196@eddie.nitro.dk> <43785A97.3010204@rojer.pp.ru> Cc: Chris Pressey , geom@freebsd.org, Dario Freni , current@freebsd.org, "Simon L. Nielsen" Subject: Re: fdisk(8) no longer capable of altering geometry X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 14 Nov 2005 13:48:56 -0000 We are not using sysinstall. We are in the process of porting BSD Installer which uses fdisk. On 11/14/05, Deomid Ryabkov wrote: > Simon L. Nielsen wrote: > > On 2005.11.12 01:19:52 +0100, Dario Freni wrote: > > > >> My little follow-up to this issue. This bug is quite critical on > >> products using bsdinstaller such as FreeSBIE or pfSense. I heard rumou= rs > >> that PC-BSD also encounter this problem and had to workaround it by > >> sysinstall. > >> > >> Can somebody please take a look at it? > >> > > > > Just curious... why do you need to alter the geometry? I never once > > had a problem just ignoring the fact that fdisk/sysinstall warned > > about geometry... > > > sysinstall warns and fixes it for you. i had to duplicate sysinstall's > behavior in my home-made quick'n'dirty installer > or otherwise disks larger than (some size, like 60G, i don't remember > exactly) are not bootable after install. > the fixup, rewritten in perl, looks like this: > > print "geom: cyl=3D$cyl, hd=3D$hd, sect=3D$sect\n"; > if ($cyl > 1024 or $hd > 16 or $sect > 63) { > $hd =3D 16; $sect =3D 63; > $cyl =3D int ($size / ($hd * $sect)); > if ($cyl > 1024) { > $hd =3D 255; > $cyl =3D int ($size / ($hd * $sect)); > } > print "new geom: cyl=3D$cyl, hd=3D$hd, sect=3D$sect\n"; > @ret =3D ($cyl, $hd, $sect); > } > > i don't know the exact meaning of ths, but it is indeed required to be > able to boot off the disk. > > -- > Deomid Ryabkov aka Rojer > myself@rojer.pp.ru > rojer@sysadmins.ru > ICQ: 8025844 > > > >