Hammer on SSD

Matthew Dillon dillon at backplane.com
Mon Aug 10 11:37:32 PDT 2015


Not sure but I think the installer is still using the old disk layout,
which is a bit of a pain.

What we recommend these days is pretty much just three partitions for a
laptop:

a - A UFS /boot partition, typically 1GB
b - Swap partition, depends on use case but usually not less than 1 x main
mem
d - One hammer partition for the remainder

The amount of swap you need depends on a number of factors.  We recommend
at least as much as main memory (more if the laptop can be expanded so you
aren't caught short).  Swap helps free up idle pages in main memory.

If tmpfs is going to be used a lot, then sometimes a lot more swap is a
good idea.

Otherwise though the only time you want a *LOT* of swap (as in potentially
a hundred gigabytes or more), is if you want to use swapcache to cache a
hard drive.  But if all you have is a SSD, you do not need to use swapcache.

--

TRIM - I do NOT recommend using TRIM except for initial erasure of the SSD,
and potentially to clean out the swap partition on boot.  Instead of trying
to use TRIM, just leave a couple of gigabytes of unused space on the SSD.
There are two ways to do this:  (1) Just allocate more swap space, swap can
serve double-duty in this regard if the system is set up to TRIM swap on
boot, because swap is mostly unused.  (2) Or allocate an 'e' partition of
type 'unused' with the space you want to leave unused.

The unused space works just as good as TRIM does but without the potential
to corrupt the filesystem.  Trying to use TRIM on the live filesystem
itself opens up a can of worms in terms of reliability.

My recommendation is to calculate roughly 5% of the storage for use in a
dummy partition or as a lower bound for swap.

--

Partition alignment - The DragonFly disklabel program handles all
alignment.  It will alignment all partitions to 1MB.

-Matt


On Thu, Aug 6, 2015 at 7:11 AM, Mirco <mirco at openmailbox.org> wrote:

> Dear Users,
>
> I know there is a thread on this theme in this list - but it's from 2011
> an maybe things have changed since then.
>
> I wish to use Dragonfly with Hammer on my laptop. There is a 120GB SSD.
> But I am a little confused about the disc layout.
>
> - What would you recommend regarding the disc layout?
> - How is the correct partition alignment actually done?
> - TRIM: use it? If yes, how? If no, what's the alternative?
> - Got anything else on your mind?
>
> Best Wishes,
> Mirco
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.dragonflybsd.org/pipermail/users/attachments/20150810/43cc7c39/attachment-0003.htm>


More information about the Users mailing list