Live data from Hacker News

Samsung's 970 EVO SSDs Reviewed – 500GB and 1TB

anandtech.com

61–68 of 68 posts

Re: Samsung's 970 EVO SSDs Reviewed – 500GB and 1TB

#61
post #38

Earlier quoted context omitted.

Power-loss capacitors are needed because without them, flush commands issued by the OS return bogus values. Write confirmations are meaningless if the data isn't actually written to disk.

Doesn't software like databases that care about this already assume the OS flush return values are bogus? And it still doesn't solve the problem of the host buffers disappearing. What's the scenario, the host experiences a power-loss, but was somehow anticipating it and managed to stop writing to the SSD?

> Doesn't software like databases that care about this already assume the OS flush return values are bogus?

Unsure of this (I would assume "it depends" and "probably not" because how else could it possibly know that anything is written to durable storage ever ever) but the idea is that if it didn't have to assume that life would be a lot easier.

> What's the scenario, the host experiences a power-loss, but was somehow anticipating it and managed to stop writing to the SSD?

If I understood your question correctly, databases and similar stuff write data in a way to try to solve exactly this problem, with write-ahead logs and such where you first write quickly and inexpensively to the log and then write to the database.

Re: Samsung's 970 EVO SSDs Reviewed – 500GB and 1TB

#62
post #41

Earlier quoted context omitted.

Given your work with PLP, which family of SSDs would you recommend most?

I personally use the Samsung PRO SSDs myself these days. I don't go with the latest models because the older NAND technology tends to be more reliable. Also you want a company with many product cycles so that the firmware has time to mature. Just too many edge cases in SSD firmware to catch them in one go.

Well, speaking of firmware, the current state of Samsung's SSD firmware is incredibly poor.

I jumped ship from SATAs to M.2 a month ago with a new computer and to quickly sum up the situation with Samsung 960 Pro from own experience and hundred page long threads on official product forum:

- last published firmware on website is 2 (don't know the long number now, writing from phone)

- a version 3 was released, system freezing started occurring in some cases and some people even ended up with bricked drives (in relation to eDrive IIRC)

- bricked drives could be reportedly used again after PSID revert, but Samsung consistently refuses to release the tool (other manufacturers do and the tool is also useful for recovering drive with lost OPAL password)

- firmware 4 reportedly exists, which can be obtained through Magician (Samsung's tool for SSD) and should solve problems from version 3. Conflicting reports on performance.

The craziest stuff is that:

- Magician will now tell you there is a new firmware for your drive, but it won't tell you with which version is it going to "enrich" your shiny new drive. Will I get 3? Or 4? Especially when only 2 is posted on the Samsung's page!

- firmware changelogs are kept secred, just install this for no reason

- no downgrades are possible

Worse than X25-M password bug. You have to be scavenging official forums for information that should be posted with the firmware and be cursing at/begging moderators to reveal some more. Ah and reportedly there is some mysterious incompatibility with major BIOS vendors in regard to eDrive. No, they won't tell what the bug is, nor on what boards.

Also, custom OPAL PBAs (image flashed to special unlocked area on disk for booting with disk locked down) don't boot in current desktop boards. Might be non-Samsung issue, maybe the one mentioned above.

How does this stuff work together at all?

Re: Samsung's 970 EVO SSDs Reviewed – 500GB and 1TB

#63
post #55

Earlier quoted context omitted.

Your terminology is slightly off, so I'm not entirely sure what you mean. M.2 is a form-factor, which can be NVMe (PCIe-based) or SATA-based. Yeah, a bit confusing but M.2 supports two different protocols. If you mean RAID0 SATA drives (in the M.2 form factor), well the processor's south-bridge has a lower limit compared to the direct-to-CPU connections most NVMe drives get. SATA is great for bulk storage: either che…

I am aware of the distinctions, I thought it would be obvious from the context. I meant to compare a 2x m.2 NVMe RAID0 with dedicated NVMe add-in cards, e.g. a kingston dcp1000. The latter can outperform the former per unit but seem more expensive even when you adjust for the higher stats.

Took me a bit to understand what you are saying. The 3700 mb read is what I am intrested in exactly.

I really think we are going to have some foundamental change in chip design to make 5K video and 8K (For commercial video it will be 15-20 years until 8K will be common in personal use.

Re: Samsung's 970 EVO SSDs Reviewed – 500GB and 1TB

#64
post #22
post #15

Earlier quoted context omitted.

I think the bigger issues are bandwidth and power consumption. If software is doing heavy IO, it doesn’t really want to have to contend with the HMB for PCIe and memory bandwidth. Also, a DRAM chip is a DRAM chip. I’d rather pay a couple dollars for a local DRAM chip in the NVMe device than a couple dollars for extra host RAM that will be permanently reserved for the HMB.

The heavy IO case is addressed by write-back characteristic of block devices. In the end, the cache is in host RAM regardless of the underlying device type.

I think you may be misunderstanding the issue. A flash controller that tries to look like a block device needs to manage a mapping between logical and physical blocks along with various other pieces of metadata. The on-flash representation needs to be structured in a flash-friendly way, which often means that it’s not efficient to find the metadata needed to process an IO request unless that metadata is cached in memory.

On an HMB device, the metadata will be cached in host memory, which will likely adversely affect performance and power efficiency.

Re: Samsung's 970 EVO SSDs Reviewed – 500GB and 1TB

#65
post #38

Earlier quoted context omitted.

Power-loss capacitors are needed because without them, flush commands issued by the OS return bogus values. Write confirmations are meaningless if the data isn't actually written to disk.

Doesn't software like databases that care about this already assume the OS flush return values are bogus? And it still doesn't solve the problem of the host buffers disappearing. What's the scenario, the host experiences a power-loss, but was somehow anticipating it and managed to stop writing to the SSD?

>Doesn't software like databases that care about this already assume the OS flush return values are bogus?

The best a database can do is prevent corruption. It cannot magically prevent data loss of writes that have never reached the platter or NAND.

>And it still doesn't solve the problem of the host buffers disappearing. What's the scenario, the host experiences a power-loss, but was somehow anticipating it and managed to stop writing to the SSD?

You solve the problem of host buffers disappearing by using fsync. The scenario is that fsync works correctly on powerloss.

Imagine you build an app consisting of 3 microservices. They are called Human, CPU and Disk.

The human sends a request via a website to the CPU. The CPU wants to save the host buffer in a database and sends a fsync request to the Disk. The Disk sends an "OK" response immediately but actually saves the data in the background. The CPU sends an "OK" response to the human. Everything is fine. Suddenly powerloss happens and the disk cannot save the data in time. The database is smart, it knows how to reconstruct some of the data until the point where the transaction log has been cut off. Beyond that though the data is gone and the "OK" sent to the Human is no longer valid.

Now imagine the same scenario with correct fsync. The CPU waits for the Disk and during a powerloss not only is the disk dead but the CPU is dead too and it therefore cannot send an "OK" response to the Human.

What if you don't use fsync? What if you pipe your data to /dev/null? Well, here is the tough news: Nobody can help you. If you don't write data to disk then it's gone.

Re: Samsung's 970 EVO SSDs Reviewed – 500GB and 1TB

#66
post #29

Earlier quoted context omitted.

A common minimum voltage requirement for the nominal +5V supply is 4.5 V. Let's assume a voltage below that won't damage the drive, but it won't operate. The diode is going to drop 0.6V, leaving you with only 4.4 V max for the drive. Then the capacitor is going to immediately start dropping in voltage as soon as you start pulling the stored energy out of it. So, in practice, to do a quality job of this it will probab…

This makes sense! OTOH low-drop diodes do exist [1], and the drive likely needs just a (small) fraction of a second to flush the caches; it's SSD, not need to wait for the disk to rotate to the right position or move heads. I suppose the power loss signal from the controller still propagates, even if the computer's PSU plug is just yanked out of socket. [1]: https://electronics.stackexchange.com/a/282471/9909

The caches on some SSD's can be multiple gigabytes.

They also frequently cache data which can be difficult (slow) to write, for example a single modified 4kb page which is part of a large unmodified area. Completing that write would involve reading the original data, erasing the entire erase-block, and rewriting the new data.

SSD's with built in power loss prevention typically reserve an area on the SSD which is pre-erased ready to dump the contents of the cache into. Then on powerup, they reload the cache and properly flush the data to the actual place it's supposed to be.

Re: Samsung's 970 EVO SSDs Reviewed – 500GB and 1TB

#67
post #48
post #42

Earlier quoted context omitted.

Desktop power supplies already have that, they can keep the power on for 50-100 ms or so, and they do notify the OS about the imminent power loss. I'm not sure what OSes do with that.

How do they notify?

ATX power supplies have a PWR_OK pin, which goes low when power is lost.

Most motherboards don't report that to the OS though, instead they simply reset all the hardware.

To be fair, it's probably preferable to reset stuff than to operate when the power supply isn't healthy, since that will lead to a lot of weird undefined behaviour.

Re: Samsung's 970 EVO SSDs Reviewed – 500GB and 1TB

#68
post #39
post #33

Earlier quoted context omitted.

So what happens when you have "power-loss capacitors"? Since these things are limited the drive races to empty its buffers onto the SSD and then shuts down. It does not ask the host "are you done writing", so now instead you lose whatever the host had in its buffers. The host is gone anyway when the drive loses power. No. Data loss protection needs to be built into the software itself, fixing that on the SSD level do…

The buffers maintained by the OS and drive are totally different, the entire point of having huge buffers in the device is so that it can agglomerate and reorder otherwise totally unrelated writes into flash banks it is presently convenient to write to. When the OS flushes stuff to the device, it is done such that metadata writes reach the disk in an order that ensures a recoverable filesystem image on power failure.…

SD cards are the same. Many cards you can unplug from the host, only to find something that successfully fsync()'ed actually wasn't persisted to the underlying storage.
Post reply on HN