# Brand new SSD

## reddragon

got my fist ssd, is 'erase block size' still relevent, or do i just need to work in mb when partitioning?

any other advice that can improve ssd performance is welcome.

----------

## frostschutz

 *reddragon wrote:*   

> or do i just need to work in mb when partitioning?

 

MiB-alignment is completely fine.

----------

## Marlo

 *Quote:*   

> =any other advice that can improve ssd performance is welcome.

 

https://wiki.gentoo.org/wiki/SSD

----------

## frostschutz

That wiki article needs an overhaul. As it says in the wiki, " This article is a stub. "

- You don't have to run fstrim twice a day (weekly or even monthly is quite enough).

- Erase Block Size won't matter, no need to even discuss it.

- You don't need a "fstrimDaemon" which solves a problem that doesn't exist, that's what cron is there for (and in extension /etc/cron.{hourly,daily,weekly,monthly}).

- Too much tmpfs and it breaks stuff. You don't have to worry about write cycles.

----------

## szatox

One (a bit risky - check the manual first) tip on fstrim:

SSDs can erase no-longer-used-blocks internally if you permanently limit their size with hdparm -N. This eliminates the need for fstrim, as cells will be remapped between cells, and remapping is very quick.

Size of that reserved area depends on average stress this disk is going to face. Under very heavy load you may want to reserve (or "hide") as much as 20% of it's total capacity. With a typical PC idling most of the time, you will be totally fine reserving far less space. How much data will you replace in a single burst?

Note: This operation will wipe all data from SSD. Either do that before formatting, or don't do that at all.

----------

## frostschutz

All SSDs have "hidden capacity", no real need to add more. Adding more also does not help the way trim/discard helps reduce write amplification.

(Whether there is any point in reducing write amplification in the first place is another matter... most systems are idle most of the time, and not writing anything in the first place avoids write amplification better than anything... zero amplified is still zero).

And fstrim gives you the same "hidden capacity" would give you, only much more of it and it remains usable in a tight spot. Filesystems don't like being full...

If you decide to not trim anything at all, it should be because you care more about not losing data than longevity/performance of SSD. It's a personal choice depending on your priorities.

I wrote a bit about it here http://unix.stackexchange.com/a/218083/30851 and here http://unix.stackexchange.com/a/80868/30851

----------

## reddragon

not sure if it makes a difference but, the drive is a NVMe.

----------

