I'm preparing to set up a new 1TB SSD (Samsung 850pro) for use in an
OpenBSD laptop. Like every other SSD I've seen, this SSD uses a 4K
byte block size.
I'm planning to use softraid crypto for this disk, and mount all the
main filesystems with softdep and noatime.
I understand that fdisk and disklabel partition boundaries should
be multiples of 4K bytes (= 8 512-byte sectors), e.g., starting the
'a' disklabel partition at offset=64 512-byte sectors is much better
than starting it at offset=63.
* Should I set the FFS fragment size (newfs -f) to 4096 or larger?
* What about the FFS sector size (newfs -S): should this be left at
its default, or set to 4096?
* Are there other fdisk and/or newfs parameters which should be set
differently than I'd set them for a mechanical hard disk of similar
* What are the tradeoffs between FFS (newfs -O 1) and FFS2 (newfs -O 2)?
Since this is OpenBSD, perhaps I should rephrase this question as
"what Fine Manual should I have read to learn about these tradeoffs?"
* Does or should using softraid crypto change the answers to any of
the above questions?
-- "Jonathan Thornburg [remove -color to reply]" <[hidden email]>
Dept of Astronomy & IUCSS, Indiana University, Bloomington, Indiana, USA
"There was of course no way of knowing whether you were being watched
at any given moment. How often, or on what system, the Thought Police
plugged in on any individual wire was guesswork. It was even conceivable
that they watched everybody all the time." -- George Orwell, "1984"
Don't think it is needed to set manyally, should be handled automatically.
> * What about the FFS sector size (newfs -S): should this be left at
> its default, or set to 4096?
Default will be 4096 on a 4k disk.
> * Are there other fdisk and/or newfs parameters which should be set
> differently than I'd set them for a mechanical hard disk of similar
> * What are the tradeoffs between FFS (newfs -O 1) and FFS2 (newfs -O 2)?
> Since this is OpenBSD, perhaps I should rephrase this question as
> "what Fine Manual should I have read to learn about these tradeoffs?"
If you have large partitions Lets say > 100G), go for -O2. Saves quite
some time. If you plan to store many large files and few small files,
go for a larger blocksize (and possibly fragment size).
> * Does or should using softraid crypto change the answers to any of
> the above questions?
On 03/09/17 15:20, Christian Weisgerber wrote:
> On 2017-03-09, Jonathan Thornburg <[hidden email]> wrote:
>> Subject: FFS parameters for SSD filesystem?
> You are overthinking this. The defaults are fine.
What he said.
An SSD is a SATA storage device.
It's the 2010s.
JUST USE IT.
Knob twisting for file systems went out with the 1990s.
It will either give you trouble in the first weeks or last until long
after you are laughing at how small a 1TB of storage is, how big a 2.5"
disk is, and how slow the SATA interface is.
FFS2 is nice for big storage areas, but NOTHING to do with SSD or non-SSD.
(ok, update the firmware for your SSD. that's something that should
have stopped after the 1990s, too, but surprise: the computer industry
sells crap and you line up to buy it. I've had that exact disk give me
trouble that seems to have settled down by dd'ing zeros over entire
partitions before using them. Your milage may vary.)