From owner-freebsd-questions@FreeBSD.ORG Sun Nov 25 13:50:26 2012 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4549FAD4 for ; Sun, 25 Nov 2012 13:50:26 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mx02.qsc.de (mx02.qsc.de [213.148.130.14]) by mx1.freebsd.org (Postfix) with ESMTP id C5ACF8FC13 for ; Sun, 25 Nov 2012 13:50:25 +0000 (UTC) Received: from r56.edvax.de (port-92-195-51-39.dynamic.qsc.de [92.195.51.39]) by mx02.qsc.de (Postfix) with ESMTP id D3C9E2762E for ; Sun, 25 Nov 2012 14:50:24 +0100 (CET) Received: from r56.edvax.de (localhost [127.0.0.1]) by r56.edvax.de (8.14.5/8.14.5) with SMTP id qAPDoQnJ002417 for ; Sun, 25 Nov 2012 14:50:26 +0100 (CET) (envelope-from freebsd@edvax.de) Date: Sun, 25 Nov 2012 14:50:26 +0100 From: Polytropon To: freebsd-questions@freebsd.org Subject: Re: Manually partitioning using gpart Message-Id: <20121125145026.c273a06b.freebsd@edvax.de> In-Reply-To: <1353850217.2508.64.camel@q> References: <1353842774.2508.18.camel@q> <50B20FD9.9070405@bnrlabs.com> <1353848249.2508.41.camel@q> <1353850217.2508.64.camel@q> Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Polytropon List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 25 Nov 2012 13:50:26 -0000 On Sun, 25 Nov 2012 14:30:17 +0100, Ralf Mardorf wrote: > At the moment I still have: > This is what I've got: > # gpart show ada0 > => 63 625142385 ada0 MBR (298G) > 63 121274683 - free - (57G) > [snip] > > Regarding to http://www.wonkity.com/~wblock/docs/html/disksetup.html > for my set up it should be ok to run: > > # gpart add -t freebsd-boot -l boot -b 40 -s 512K ada0 > > # gpart add -t freebsd-swap -l swap -s 8G ada0 > > # gpart add -t freebsd-ufs -l root -b 1M ada0 > Should use all the free space, so no option -s?! See "man gpart" for details (yes, there are _excellent_ man pages installed locally, or accessible via web): If -s option is omitted then new size is automatically calculated to maximum available from given geom geom. Here: http://www.freebsd.org/cgi/man.cgi?query=gpart&apropos=0&sektion=0&manpath=FreeBSD+9.0-RELEASE&arch=default&format=html > # newfs -U /dev/gpt/root Maybe you would also consider using -J (journaling). Still the traditional approach when using functional partitioning is to format the / partition without soft updates (-U), but in your case, using them on a "everything in one /" partition is okay. > # gpart bootcode -b /boot/pmbr -p /boot/gptboot -i 1 ada0 > Will install the FreeBSD bootloader independent of the GRUB in the MBR? Hmmm... I'd assume that ada0 (the "beginning of the disk") contains GRUB already (or a "redirect" to where it's actually located), so I think ada0p1 would be the location to write to... still I'm not sure if you need to have any boot code at all because GRUB will perform the "redirection" to the FreeBSD loader which will then load the FreeBSD kernel. See "man 8 boot" for details. I'm not a "multi-booter" so I can't be more specific, sorry. > My GRUB menu.lst still is: > > timeout 8 > default 0 > color light-blue/black light-cyan/blue > > title FreeBSD 9.0 > root (hd0,a) > kernel /boot/loader > > [snip] > > So kernel /boot/loader has to be replaced by /boot/foo? No, I think /boot/loader is correct here; it's a program that sets up the kernel environment, loads it, maybe loads modules, and passes control to the kernel. It's located on the ada0p1 partition. > /etc/fstab: > > # Device Mountpoint FS Options Dump Pass# <-- is this "#" needed at the end? > Or is it ok like this: > # Device Mountpoint FS Options Dump Pass No, it means "pass number"; according to "man 5 fstab": The sixth field, (fs_passno), is used by the fsck(8) and quotacheck(8) programs to determine the order in which file system and quota checks are done at reboot time. The fs_passno field can be any value between 0 and `INT_MAX-1'. But it's a comment line anyway. :-) > And this are the entries I need: > > /dev/gpt/swap none swap sw 0 0 > /dev/gpt/root / ufs rw 1 1 Looks correct. (You can later on add lines to access data partitions or even your Linux partitions if you want, optical drives or NFS shares if you need.) -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...