Dan Williams & Tiffany Kasanicky /dev/pmem0 /dev/ndblk0.0s - - PowerPoint PPT Presentation

dan williams tiffany kasanicky dev pmem0 dev ndblk0 0s
SMART_READER_LITE
LIVE PREVIEW

Dan Williams & Tiffany Kasanicky /dev/pmem0 /dev/ndblk0.0s - - PowerPoint PPT Presentation

Linux Foundation Vault 2016 Dan Williams & Tiffany Kasanicky /dev/pmem0 /dev/ndblk0.0s Managing Persistent Memory Application IXPDIMM Applications (PMEM Aware) (Management Stack) (Traditional) NDCTL LIBNDCTL EXT4, XFS FS FS SYSFS


slide-1
SLIDE 1

Linux Foundation Vault 2016 Dan Williams & Tiffany Kasanicky

slide-2
SLIDE 2

/dev/pmem0

slide-3
SLIDE 3
slide-4
SLIDE 4

/dev/ndblk0.0s

slide-5
SLIDE 5

Managing Persistent Memory

SYSTEM ADDRESS SPACE E820 ACPI.NFIT SYSTEM MEMORY BLK REGION PERSISTENT MEMORY (PMEM) PMEM REGION PMEM REGION LIBNVDIMM BUS PMEM IOCTL EXT4, XFS SYSFS LIBNVDIMM REGION PMEM1S PMEM0 BLK1S LIBNDCTL USERSPACE NDCTL BTT(BLK) FS FS IXPDIMM (Management Stack) Application (PMEM Aware) Applications (Traditional) DAX BTT(PMEM)

slide-6
SLIDE 6

Namespaces

# ndctl list --namespaces --type=pmem { "dev":"namespace6.0", "mode":"raw", "size":33554432, "uuid":"70a6adce-722e-4ab8-b698-35eaea9750b3", "blockdev":"pmem6" }

slide-7
SLIDE 7

Namespaces

# ndctl list --namespaces --type=pmem { "dev":"namespace6.0", "mode":"raw", "size":33554432, "uuid":"70a6adce-722e-4ab8-b698-35eaea9750b3", "blockdev":"pmem6" }

slide-8
SLIDE 8

Namespaces

# ndctl list --namespaces --type=pmem { "dev":"namespace6.0", "mode":"raw", "size":33554432, "uuid":"70a6adce-722e-4ab8-b698-35eaea9750b3", "blockdev":"pmem6" }

“Namespace”: Persistent memory capacity accessed through a PMEM or BLK disk device

slide-9
SLIDE 9

Namespaces

# ndctl list --namespaces --type=blk { "dev":"namespace0.0", "mode":"sector", "uuid":"5ce6c34a-88b0-469a-86f5-ea8f462a68ca", "sector_size":4096, "blockdev":"ndblk0.0s" }

slide-10
SLIDE 10

Why BLK?

slide-11
SLIDE 11
slide-12
SLIDE 12

RAW

Namespace Modes

SECTOR MEMORY

slide-13
SLIDE 13

RAW

  • Byte-addressable
  • Limited DAX

Namespace Modes

SECTOR MEMORY

slide-14
SLIDE 14

RAW

  • Byte-addressable
  • Limited DAX

Namespace Modes

SECTOR

  • Software atomic

sector update semantics

  • Configurable sector

size.

  • Applicable to PMEM

and BLK namespaces MEMORY

slide-15
SLIDE 15

RAW

  • Byte-addressable
  • Limited DAX

Namespace Modes

SECTOR

  • Software atomic

sector update semantics

  • Configurable sector

size.

  • Applicable to PMEM

and BLK namespaces MEMORY

  • Enables full DAX

(DMA/RDMA/Direct- I/O)

  • Only applicable to

PMEM namespaces

slide-16
SLIDE 16

“Memory” Mode DAX: Direct I/O

Application DAX ‘buf’ Disk file ‘fd’ pmem0 sda

slide-17
SLIDE 17

“Memory” Mode DAX: Direct I/O

Application DAX ‘buf’ Disk file ‘fd’ Core Kernel buf struct page fd (bdev, sector) bio

slide-18
SLIDE 18

“Memory” Mode DAX: Direct I/O

Application DAX ‘buf’ Disk file ‘fd’ Core Kernel buf struct page fd (bdev, sector) Block Layer + Disk Driver sda bio bio sgl pmem0 DMA disk driver

slide-19
SLIDE 19

“Memory” Mode DAX: Direct I/O

Application DAX ‘buf’ Disk file ‘fd’ Core Kernel buf struct page fd (bdev, sector) Block Layer + Disk Driver sda bio bio sgl pmem0 DMA disk driver

X

slide-20
SLIDE 20

“Memory” Mode DAX: Considerations

  • struct page array is 64-bytes per 4K page (16GB per 1TB)

# ndctl create-namespace --reconfig=namespace9.0 --mode=memory -- map=dev --force

slide-21
SLIDE 21

ndctl/libndctl < IXPDIMM

ndctl/libndctl: low level generic primitives IXPDIMM: Coherent / comprehensive management stack

slide-22
SLIDE 22

Tiffany Kasanicky tiffany.j.kasanicky@intel.com

slide-23
SLIDE 23

Persistent Memory

23

NVDIMM User Kernel BIOS Management ACPI (NFIT) _DSM Management Tools FW File System Application Application MMU Mappings SMBIOS

Standard File API Standard Raw Device Access Standard File API Load/Store

NFIT/NVDIMM Driver Persistent Memory pmem-aware FS (DAX) Application

Block I/O

slide-24
SLIDE 24

Components

24 3

  • Basic Management
  • End-user provisioning and

management via CLI

  • Enabling
  • SFCB/Pegasus CIM provider for

remote access and 3rd party integration

  • C library for programmatic access

and abstraction

  • Monitoring
  • Daemon for health monitoring

BIOS User Kernel cli cim api NFIT NVDIMM Driver ACPI (NFIT) _DSM monitor Enterprise Tools db Syslog core libndctl SMBIOS

Pegasus/SFCB

slide-25
SLIDE 25

NVDIMM Management

25

CPU

iMC iMC

DRAM DRAM DRAM NVDIMM DRAM DRAM DRAM CH 0 CH 1 CH 2 CH 3 CH 4 CH 5 DRAM DRAM NVDIMM NVDIMM NVDIMM

Slot 1 Slot 0 Slot 1 Slot 0

NVDIMM NVDIMM

Instrumentation: FW update, SW versioning, data-at-rest security, FW settings and policies Performance: Bytes read/written, host and block read/writes Namespaces: Create/delete/inventory namespaces Sensors & Settings: Thermal, wear, spare, power, errors Discovery: DRAM + NVDIMM topology, identifying information, capabilities Memory Configuration: Volatile and persistent partitions, interleave settings

slide-26
SLIDE 26

Discovery

26

  • DRAM/NVDIMM Topology
  • SMBIOS Type 17 (memory device) data
  • NVDIMM socket, memory controller, channel population
  • Aggregated Memory Resources
  • Capabilities
  • Platform BIOS, NVDIMM, FW, SW
  • NVDIMM Information
  • Identifying - serial number, model number, device ID
  • Status – manageability, health, security
  • Provisioning – partitioning, attributes, state
slide-27
SLIDE 27

Memory Provisioning

27

  • 1. Create memory allocation goal
  • 2. Reboot
  • 3. BIOS writes NFIT
  • 4. Driver reads NFIT
  • 5. Create namespace
  • 6. Mount file system

NVDIMM NVDIMM NVDIMM User Kernel BIOS _DSM FW PM Metadata MRC NFIT 1 Management Tools NFIT/NVDIMM Driver 3 4 5 2

slide-28
SLIDE 28

Diagnostics

28

  • Quick Health Check
  • Platform Configuration Check
  • Security Check
  • FW Consistency and Settings Check
  • Persistent Memory Metadata Check
  • Address Range Scrub Results
slide-29
SLIDE 29

Packages

29

Compone nt Package Repository

cli ixpdimm-cli https://github.com/01org/IXPDIMMSW cim libixpdimm-cim https://github.com/01org/IXPDIMMSW core libixpdimm-core https://github.com/01org/IXPDIMMSW api libixpdimm-api libixpdimm-api-devel https://github.com/01org/IXPDIMMSW monitor ixpdimm-monitor https://github.com/01org/IXPDIMMSW cli framework libintelnvm-cli libintelnvm-cli-devel https://github.com/01org/intelnvmclilibrary i18n framework libintelnvm-i18n libintelnvm-i18n-devel https://github.com/01org/intelnvmi18nlibrary cim framework libintelnvm-cim libintelnvm-cim-devel https://github.com/01org/intelnvmcimlibrary

slide-30
SLIDE 30

Distribution Plan

30

  • Open source 3-clause BSD license
  • Hosted on 01.org/github – Intel maintainers
  • https://01.org/ixpdimm-sw
  • https://01.org/intel-nvm-cim-library
  • https://01.org/intel-nvm-cli-library
  • https://01.org/intel-nvm-i18n-library
  • Targeted OS Distributions:
  • RHEL/Fedora
  • SLES/OpenSuSE
slide-31
SLIDE 31

tiffany.j.kasanicky@intel.com