From owner-freebsd-stable Sat Jan 27 4: 0:17 2001 Delivered-To: freebsd-stable@freebsd.org Received: from mailsrv.otenet.gr (mailsrv.otenet.gr [195.170.0.5]) by hub.freebsd.org (Postfix) with ESMTP id CE12637B400 for ; Sat, 27 Jan 2001 03:59:58 -0800 (PST) Received: from hades.hell.gr (root@patr530-b019.otenet.gr [195.167.121.147]) by mailsrv.otenet.gr (8.11.1/8.11.1) with ESMTP id f0RBxlK17656; Sat, 27 Jan 2001 13:59:48 +0200 (EET) Received: (from charon@localhost) by hades.hell.gr (8.11.1/8.11.1) id f0RARYD49513; Sat, 27 Jan 2001 12:27:34 +0200 (EET) Date: Sat, 27 Jan 2001 12:27:33 +0200 From: Giorgos Keramidas To: Josef Karthauser Cc: Warner Losh , Matt Heckaman , Shawn Barnhart , freebsd-stable@FreeBSD.ORG Subject: Re: Limit on the number of disklabel entries? Message-ID: <20010127122733.C49085@hades.hell.gr> References: <200101212233.f0LMXVs03655@billy-club.village.org> <20010121235644.A29517@tao.org.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.4i In-Reply-To: <20010121235644.A29517@tao.org.uk>; from joe@tao.org.uk on Sun, Jan 21, 2001 at 11:56:44PM +0000 X-PGP-Fingerprint: 3A 75 52 EB F1 58 56 0D - C5 B8 21 B6 1B 5E 4A C2 X-URL: http://students.ceid.upatras.gr/~keramida/index.html Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Sun, Jan 21, 2001 at 11:56:44PM +0000, Josef Karthauser wrote: > On Sun, Jan 21, 2001 at 03:33:31PM -0700, Warner Losh wrote: > > In message Matt Heckaman writes: > > : Brand new system, installed 3 days ago, 4.2-RELEASE. Creating the > > : partition on the newly sliced da1 via sysinstall put it on "e". > > > > 'e' is the first slice that sysinstall uses. Since you wanted the > > whole disk, it gave you the whole disk as 'e'. Nothing magical about > > it. 'c' being the whole disk *IS* magical. > > Does 'c' include the disklabel itself, and the boot blocks? Actually in /usr/src/sys/sys/disklabel.h you can see three constants defined. #define LABEL_PART 2 /* partition containing label */ #define RAW_PART 2 /* partition containing whole disk */ #define SWAP_PART 1 /* partition normally containing swap */ The code uses LABEL_PART when it wants to access the partition containing the entire disk, together with the disklabel, but as you can see, this is the same as RAW_PART which is defined to `2'. Now, lemme guess... 'a', 'b', 'c'.. '0', '1', '2'.. SWAP_PART is '1' and default swap partition is 'b'. RAW_PART is '2' and the default `entire disk' partition is 'c'. HAHHAHHH. I'm beginning to love this source thing! Absolutely amazing, how clearly ideas and things can jump out on you, if you read a few lines of code :-) Cheers, Giorgos. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message