[Bulk] Re: Manually partitioning using gpart

Ralf Mardorf ralf.mardorf at rocketmail.com
Sun Nov 25 12:43:53 UTC 2012


On Sun, 2012-11-25 at 13:29 +0100, Polytropon wrote:
> On Sun, 25 Nov 2012 12:26:14 +0100, Ralf Mardorf wrote:
> > This is what I've got:
> > 
> > # gpart show ada0
> > =>      63   625142385 ada0 MBR (298G)
> >         63   121274683 - free - (57G)
> > [snip]
> > 
> > IIUC I now have to do:
> > 
> > # gpart add -s 64k -t freebsd-boot -l boot0 ada0
> > # gpart add -s 8G -t freebsd-swap -l swap0  ada0
> > # gpart add -t freebsd-ufs -a 256k -l root0 ada0
> > 
> > Here I already don't understand how large the swap should be. Really 2 *
> > size of the RAM?
> 
> Won't be wrong; my understanding of the rule was "2 * size of
> _possible_ RAM in the machine". But disk space is cheap, so
> 8 G should be fine. But again, the requirement for the swap
> partition depends on what you're doing with the machine and
> what you're expecting (e. g. will you want to save kernel dumps
> to the swap partition?).
> 
> You can find an example here:
> 
> http://www.wonkity.com/~wblock/docs/html/disksetup.html
> 
> Also see "man newfs" for options.

I'll read this. I want to test what's possible and/or impossible
regarding to MIDI and audio productions using FreeBSD.

> > I also don't know if 256k is a sane alignment value, I just copied this
> > from a howto.
> 
> Modern disks work faster when everything is aligned to 4k.
> But they _work_ with any other alignment.

I'll use 4k.

> > How to continue after this is done?
> 
> You will have new partitions /dev/ada0pN. You need to format
> them with newfs. If I see this correctly, you have created
> one big / partition (for everything); this is _valid_ and
> possible, but may be less optimum for a couple of reasons.

Until now I haven't done anything. It's still free.

> Doing "functional partitioning" requires at least an idea
> of how much disk space will be needed per functional part,
> and this can differ from use as server or desktop, or what
> kind of software you run.

On Linux I only use /. So I don't have to think about how much space
what directory might need and I never run into issues, when the file
system hierarchy does change. Off cause I've got special partitions for
audio productions mounted with noatime and a own partition for emails,
but anything else, including /home is inside /.


>  The advantage is that you can
> backup data partition-wise (using dump + restore) and have
> a functional base system on / in case there's a severe
> disk corruption. The disadvantage is that if finally one
> partition is "too full", you cannot easily resize them
> (even though this is possible).

On Linux I can backup partition-wise too, but it's also possible to
backup directory-wise ;).

Btw. I never sync backups, I always keep several backups of the system,
since setting up a hard real-time jitter free DAW is a special task for
modern computers. In the 80s hard real-time really was hard real-time
(C64, Atari ST), nowadays it is hard work to get something similar.

> When done, add them to your /etc/fstab. You can use the
> labels for that instead of the device names.

> > I want to use GRUB from my Linux installs, this is the Linux menu.lst:
> > 
> > timeout   8
> > default   0
> > color light-blue/black light-cyan/blue
> > 
> > title FreeBSD 9.0
> > root   (hd0,a)
> > kernel /boot/loader
> 
> My Linux multiboot experience is limited, but this looks okay.
> You will delegate boot control to the loader, hd0a = sda1 = adap1,
> the partition of "freebsd-boot" type.

Thank you.

Regards,
Ralf




More information about the freebsd-questions mailing list