From owner-freebsd-current Tue Oct 15 23:36:58 2002 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 90C4B37B406 for ; Tue, 15 Oct 2002 23:36:56 -0700 (PDT) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id D25D343EA3 for ; Tue, 15 Oct 2002 23:36:54 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id QAA26403; Wed, 16 Oct 2002 16:36:50 +1000 Date: Wed, 16 Oct 2002 16:47:26 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: walt Cc: freebsd-current@FreeBSD.ORG Subject: Re: GEOM question In-Reply-To: <3DAC737D.1020504@hotmail.com> Message-ID: <20021016161837.B4090-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, 15 Oct 2002, walt wrote: > bde@zeta.org.au (Bruce Evans) writes: > > > On Tue, 15 Oct 2002, walt wrote: > > > > Well, disklabel won't work on an extended/logical partition... > > > Um, disklabel works on any slice. E.g.: > > We have a semantic problem, as often happens when the DOS and BSD worlds collide. > > s3 is a 'slice' which is the same as a 'DOS primary partition' and yes, disklabel > works on any 'primary' partition. It works on anything that resembles a disk. All slices of disks resemble disks, and 'DOS logical drives' are mapped to slices. There is nothing special about the slices for 'DOS primary partitions' and 'DOS logical drives' as far as disklabel can tell. > My new BSD filesystem is on ad2s8, which is a DOS 'logical' partition in my > 'DOS-extended' (primary) partition ad2s4: > > #fdisk ad2 > The data for partition 4 is: > sysid 15 (0x0f),(Extended DOS (LBA)) > > The logical drive is numbered 's8' because it is the 4th 'logical' drive in > the 'extended DOS' slice, and the 'logical' drives are numbered beginning > with s5 and work upwards from there, and they don't show up in FBSD's fdisk, > unfortunately, though they do show up in /dev. The 'primary' partitions are > numbered 1 thru 4 only. > > I think we have M$ (and perhaps IBM) to thank for this marvelous feature > of the PC which has caused so many headaches over the decades. Actually, we have Linux to thank for providing an fdisk that supports extended partitions and logical drives, so that we don't need to fix update FreeBSD fdisk to get a free fdisk that supports them :-). > If there is a way to create 'logical' partitions in FreeBSD I'm not aware > of it. I usually use PartitionMagic to do all the grunt work of creating > and resizing such partitions. And now I can use them as native BSD ufs > filesystems, which I never knew until now. Cool! I haven't used extended partitions for many years. I would boot Linux or DOS to create them. The Linux fdisk binary that I have handy (a version from 1997) used to run well enough under FreeBSD to at least display everything. It is now broken by linkage problems (it wants to use the FreeBSD libc.so.5). I never tried it to create partitions, but would expect it to work. Once logical drives are created, you can just use them. This was a design goal in the origianl version of the slice code in 1995. (Don't use extended partitions directly. It is easy to make a mess by clobbering the pointers to the logical drive within them.) Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message