Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 28 Mar 2014 20:25:40 -0600 (MDT)
From:      Warren Block <wblock@wonkity.com>
To:        "Lawrence K. Chen, P.Eng." <lkchen@ksu.edu>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Partition alignment
Message-ID:  <alpine.BSF.2.00.1403282017280.1884@wonkity.com>
In-Reply-To: <53360177.60001@ksu.edu>
References:  <53333669.7000802@netfence.it> <alpine.BSF.2.00.1403261551020.50857@wonkity.com> <533356EA.8020802@netfence.it> <53360177.60001@ksu.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 28 Mar 2014, Lawrence K. Chen, P.Eng. wrote:

> On 03/26/14 17:38, Andrea Venturoli wrote:
>
>> Should I leave more space and start the slice at 256kB?

[replying here, since I somehow missed the original response]

You can, but it's important to realize that gpart will align to CHS 
values regardless.  The only way around this at present is to use fdisk, 
which will allow creation of arbitrarily-aligned slices.

>>> When creating the partitions, use gpart's -a option, and it will add an
>>> offset so the slice is aligned:
>>>
>>> gpart add -t freebsd-ufs -a4k -s8g mfid0s1
>>
>> So you are suggesting I could leave the slice where it is, and just move the
>> partitions?

Yes.  The better solution is to use GPT partitions, though.

>> Shouldn't I use -a256k, since that's the stripe size?

That would do no harm, but if you start the first filesystem partition 
at 1M, and make all partitions multiples of 1M or 1G in size, they are 
aligned for values up to at least 1M anyway.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?alpine.BSF.2.00.1403282017280.1884>