Gentoo Archives: gentoo-user

From: Rich Freeman <rich0@g.o>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Seagate ST8000NM0065 PMR or SMR plus NAS SAS SATA question
Date: Fri, 22 May 2020 18:23:36
In Reply to: Re: [gentoo-user] Seagate ST8000NM0065 PMR or SMR plus NAS SAS SATA question by antlists
On Fri, May 22, 2020 at 2:08 PM antlists <antlists@××××××××××××.uk> wrote:
> > So what you could do is allocate one zone of CMR to every four or five > zones of SMR and just reshingle each SMR as the CMR filled up. The > important point is that zones can switch from CMR cache to SMR filling > up, to full SMR zones decaying as they are re-written.
I get how this will provide more flexibility. However, there is a big problem here. Unless you are using TRIM you have no idea what space is in use vs free. Once a block has been written to once, it needs to be forever treated as occupied. So this cache really is only useful when the drive is brand new. Once it has all been written once you're limited to dedicated CMR regions for cache, because all the SMR areas are shingled. If you are using TRIM then this does give you more flex space, but only if enough overlapping space is unused, and you do need to reshingle to write to that unused space. Depending on the degree of overlap you still have only a fraction of disk available for your cache.
> Which is why I'd break it down to maybe 2GB zones. If as the zone fills > it streams, but is then re-organised and re-written properly when time > permits, you've not got too large chunks of metadata. > ... > The problem with drives at the moment is they run out of CMR cache, so > they have to rewrite all those blocks WHILE THE USER IS STILL WRITING. > The point of my idea is that they can repurpose disk as SMR or CMR as > required, so they don't run out of cache at the wrong time ...
You still have a limited cache, and if it fills up you hit the performance wall. The question just comes whether it is more efficient to have flex-space that can be PMR or SMR, or having dedicated space that is PMR-only. I think that depends greatly on whether you can assume the use of TRIM and how much free space the drive will have in general. Since PMR is less dense you have to give up a lot of SMR space for any PMR use of that space. A big problem with drive-managed SMR is that it basically has to assume the OS is dumb, which means most writes are in-place with no trims, assuming the drive even supports trim. -- Rich


Subject Author
Re: [gentoo-user] Seagate ST8000NM0065 PMR or SMR plus NAS SAS SATA question antlists <antlists@××××××××××××.uk>