Skip to content
Nick edited this page Sep 15, 2021 · 43 revisions

Overview

  • Address space is divided into zones, and zones need to be written sequentially with a write pointer that keeps track of the position for the next write. Data in a zone cannot be overwritten (zone must first be erased using zone reset)
  • SSDs implement zoned namespaces to reduce write amplification, reduce its onboard DRAM needs and improve QoS, with NVMe Zoned NameSpace (ZNS) protocol it is added to the NVMe interface standard. Shingled Magnetic Recording (SMR) can also implement zoned storage and uses the SCSI Zoned Block Commands (ZBC) and Zoned ATA Commands (ZAC) interfaces.
  • Zoned storage device added to Linux with 4.10.0 and supports (disk driver, file system, device mapper drivers), based on Zoned Block Device (ZBD) abstraction.
  • Ways of using zoned storage for applications:
    1. If the user has no need for OS or fs to manage the zoned storage, can directly issue zone management commands using a passthrough interface (with libzbz library).
    2. Can rely on Kernel ZBD support to handle device, it then provides regular POSIX system calls. (still keeps zoned access constraints application must handle, sequential and erase before rewrite).
    3. User more advanced Kernel ZBD compliant file system which hides all the constraints from the application (manages them itself), or by using a device mapper driver that will expose the device as a regular block device.

Small notes on Storage protocols:

  • SCSI (Small Computer System Interface) is the standards for data transfer between computer and peripherals, however it was designed for older devices such as HDDs therefore isn't optimal for flash based devices as it assumes those are HDDs (will follow certain access patterns). Therefore it is a legacy protocol. It is broader than ATA, as it can handle many storage devices (CD, DVD, Tape, etc.)
  • ATA (Advanced Technology Attachment) is the standards for connection storage devices to the computer, and was designed for HDDs.
  • SATA (Serial ATA) is the bus interface for connecting host bus adapters to storage devices. This is the connection interface and ATA is the protocol.
  • NVMe (Non-Volatile Memory Express) is the specification for accessing non-volatile memories (typically attached on PCIe). Eliminates the SCSI bottleneck of only having one command queue as it has up to 64K queues that can each hold 64K requests simultaneously.

SMR

  • SMR is used in HDDs to areal density. With it there are no gaps between the tracks on HDD tracks (as opposed to conventional magnetic recording, CMR which needs gaps to account for track miss registrations). Tracks are than written in an overlapping manner (think of it like roof shingles), data is written sequentially then overlapped with another track to shingle it, resulting in more data that can be placed on each magnetic surface.

Resources

  1. Zoned Storage Documentation. https://zonedstorage.io/

Clone this wiki locally