liveBook · Manning

Node-local persistent volume

As explained in Google Anthos in Action

A local persistent volume is storage backed by a disk or filesystem on a particular Kubernetes node and therefore tied to that node's availability.

A node-local persistent volume (PV) uses a disk or filesystem on a particular node. A Pod using it is bound to that disk and node; if either becomes unavailable, the Pod becomes unavailable too. section 17.4.1

Anthos on bare metal provides three local PV storage classes:

  • LVP node mounts: one PV per disk mounted under a specified directory, with the disk’s capacity. section 17.4.1
  • LVP share: PVs backed by subdirectories of a local filesystem on each node; workloads share its capacity and I/O operations per second. section 17.4.1
  • Anthos system: preconfigured PVs for system Pods. Do not modify or delete this class, or use it for stateful applications. section 17.4.1
storage:
  lvpNodeMounts:
    path: /mnt/localpv-disk
    storageClassName: local-disks
  lvpShare:
    path: /mnt/localpv-share
    storageClassName: local-shared
    numPVUnderSharedPath: 5

The cluster storage configuration shows paths and storage-class names for node mounts and shared local volumes, plus the number of PVs under the shared path. section 17.4.1

Use local PVs when workloads can tolerate disk or node failure, or when data is replicated elsewhere and recoverable. They generally suit proofs of concept or advanced use cases rather than workloads whose persistence depends on one disk. section 17.4.1

How Google Anthos in Action covers it

How deep it goes
Defines node binding, compares three storage classes, and shows cluster configuration; does not detail recovery procedures.
Examples
Shows node-mount and shared-filesystem paths, storage-class names, and a shared-path PV count in cluster configuration.
What it assumes
Assumes familiarity with cluster configuration, mounted disks, and Pods.
What you can do after
Operate/configure it by choosing a local PV class and accounting for node or disk unavailability.
How it connects
Connects persistent volumes to Pods, storage classes, local volume provisioning, and data replication.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Google Anthos in Action. The section links point to the parts of the book it draws on.