Storage Host ZFS

GET /storage/host/zfs/arc

Get ZFS ARC memory statistics

Get ARC and L2ARC memory statistics and performance metrics

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/arc/config

Get ZFS ARC configuration

Get current ARC memory limit configuration, including persistence status and recommendations based on node role (mgmt: 80%, agent: 30%)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/arc/recommendations

Get ARC sizing recommendations

Get ARC memory sizing recommendations based on total RAM, workload, and node role

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/arc/set-limit

Set ZFS ARC memory limit

Set the ARC memory limit. Can specify exact bytes, percentage of RAM, or use node role presets (mgmt=80%, agent=30%). Set persistent=true to survive reboots.

Request JSON Object:
  • max_bytes (integer) – Exact byte value for zfs_arc_max

  • max_percent (integer) – Percentage of total RAM

  • min_bytes (integer) – Exact byte value for zfs_arc_min

  • min_percent (integer) – Percentage of total RAM

  • node_role (string) – “mgmt” or “agent” — uses default presets

  • persistent (boolean) – Write to /etc/modprobe.d/zfs.conf for reboot persistence

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/arc/stats

Get ZFS ARC statistics

Get detailed ARC (Adaptive Replacement Cache) statistics including hit/miss ratios, evictions, MFU/MRU breakdown, and L2ARC stats

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/cache/l2arc/add

Add L2ARC device to pool

Add an L2ARC (read cache) device to a ZFS pool. Can be a full disk or disk partition. L2ARC caches frequently read data on fast SSDs/NVMe.

Request JSON Object:
  • device_path (string) – e.g., /dev/nvme0n1p4 or /dev/sdc (required)

  • device_type (string) – “cache” (L2ARC) or “log” (SLOG) (required)

  • force (boolean)

  • pool_name (string) – (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

DELETE /storage/host/zfs/cache/l2arc/remove

Remove L2ARC device from pool

Remove an L2ARC (read cache) device from a ZFS pool

Request JSON Object:
  • device_path (string) – The device to remove (required)

  • pool_name (string) – (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/cache/slog/add

Add SLOG device to pool

Add a SLOG (ZFS Intent Log) device to a ZFS pool. Can be a full disk or disk partition. SLOG accelerates synchronous writes using fast NVMe/SSD.

Request JSON Object:
  • device_path (string) – e.g., /dev/nvme0n1p4 or /dev/sdc (required)

  • device_type (string) – “cache” (L2ARC) or “log” (SLOG) (required)

  • force (boolean)

  • pool_name (string) – (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

DELETE /storage/host/zfs/cache/slog/remove

Remove SLOG device from pool

Remove a SLOG (write log) device from a ZFS pool

Request JSON Object:
  • device_path (string) – The device to remove (required)

  • pool_name (string) – (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/cache/status

Get all pools cache status

Get L2ARC and SLOG device status across all ZFS pools

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/cache/{pool_name}/status

Get pool cache device status

Get L2ARC and SLOG device status for a specific ZFS pool, including L2ARC hit/miss stats

Parameters:
  • pool_name (string) – Pool name

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/datasets/create

Create a ZFS dataset

Create a new ZFS dataset. IMPORTANT: recordsize must be set at creation time — it cannot be changed retroactively for existing data. Use the workload preset or specify recordsize directly.

Request JSON Object:
  • atime (string) – “on” or “off”

  • compression (string) – lz4, zstd, gzip, off

  • create_parents (boolean) – Create parent datasets (-p)

  • dataset_name (string) – Full path: pool/dataset (required)

  • mount_point (string) – Custom mount point

  • properties (object) – Additional properties

  • quota (string) – e.g., “100G”

  • recordsize (string) – e.g., “8k”, “128k” - MUST be set at creation

  • reservation (string) – e.g., “50G”

  • sync (string) – “standard”, “always”, “disabled”

  • workload (string) – Preset workload: “postgres”, “mysql”, “mongodb”, “default”, etc.

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

DELETE /storage/host/zfs/datasets/destroy

Destroy a ZFS dataset

Permanently destroy a ZFS dataset. Use dry_run to preview what would be destroyed.

Request JSON Object:
  • dataset_name (string) – (required)

  • dry_run (boolean) – Just show what would be destroyed (-n)

  • force_unmount (boolean) – Force unmount (-f)

  • recursive (boolean) – Destroy children too (-r)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/datasets/get

Get ZFS dataset details

Get detailed information for a specific ZFS dataset including properties and snapshots

Query Parameters:
  • dataset_name (string) – Full dataset name (pool/dataset)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/datasets/list

List ZFS datasets

List all ZFS datasets with their properties including recordsize, compression, and usage

Query Parameters:
  • pool (string) – Filter by pool name

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/datasets/mount

Mount a ZFS dataset

Mount a ZFS dataset to its configured mount point

Request JSON Object:
  • dataset_name (string) – (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

PUT /storage/host/zfs/datasets/properties

Update ZFS dataset properties

Set one or more properties on a ZFS dataset. NOTE: recordsize changes only affect newly written data, not existing blocks.

Request JSON Object:
  • dataset_name (string) – (required)

  • properties (object) – key=value pairs (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/datasets/recordsize-presets

Get recordsize presets

Get recommended recordsize values for common workloads (Postgres: 8K, MySQL: 16K, etc.)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/datasets/unmount

Unmount a ZFS dataset

Unmount a ZFS dataset from its mount point

Request JSON Object:
  • dataset_name (string) – (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/disks

List all disks with partitions and allocation details

Returns every physical disk on the host together with its partitions.

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/pools

Get ZFS pool overview

Get ZFS pool status, health, and I/O statistics

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/pools/create

Create a ZFS pool

Create a new ZFS pool with specified VDEV topology and devices

Request JSON Object:
  • ashift (integer) – Sector size shift (9=512B, 12=4K, 13=8K)

  • devices[] (string)

  • force_create (boolean) – Force creation (-f flag)

  • mount_point (string) – Custom mount point (-m)

  • pool_name (string) – Name of the pool (required)

  • properties (object) – Pool properties (-o key=value)

  • vdev_type (string) – mirror, raidz, raidz2, raidz3, stripe, draid (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

DELETE /storage/host/zfs/pools/destroy

Destroy a ZFS pool

Permanently destroy a ZFS pool and all its data

Request JSON Object:
  • force (boolean) – Force destroy (-f)

  • pool_name (string) – (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/pools/export

Export a ZFS pool

Export a ZFS pool, making it available for import on another system

Request JSON Object:
  • force (boolean) – Force export (-f)

  • pool_name (string) – (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/pools/import

Import a ZFS pool

Import a previously exported ZFS pool

Request JSON Object:
  • force (boolean) – Force import (-f)

  • import_all (boolean) – Import all available pools

  • pool_name (string) – Specific pool name to import

  • read_only (boolean) – Import readonly (-o readonly=on)

  • search_dirs[] (string)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/pools/importable

List importable pools

List ZFS pools that are available for import (previously exported or from other systems)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/pools/list

List all ZFS pools

Get detailed information for all ZFS pools including VDEVs, datasets, and health

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

PUT /storage/host/zfs/pools/properties

Update ZFS pool properties

Set one or more properties on a ZFS pool

Request JSON Object:
  • pool_name (string) – (required)

  • properties (object) – key=value pairs (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/pools/scrub

Start/stop pool scrub

Start or stop a data integrity scrub on a ZFS pool

Request JSON Object:
  • pool_name (string) – (required)

  • stop (boolean) – Stop an active scrub (-s)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/pools/{pool_name}

Get ZFS pool details

Get detailed information for a specific ZFS pool

Parameters:
  • pool_name (string) – Pool name

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/pools/{pool_name}/iostat

Get pool I/O statistics

Get real-time I/O statistics for a specific ZFS pool

Parameters:
  • pool_name (string) – Pool name

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/snapshots/clone

Clone a ZFS snapshot

Create a new dataset from a ZFS snapshot (writable clone)

Request JSON Object:
  • clone_name (string) – New dataset name (required)

  • properties (object)

  • snapshot_full_name (string) – pool/dataset@snap (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/snapshots/create

Create a ZFS snapshot

Create a point-in-time snapshot of a ZFS dataset

Request JSON Object:
  • dataset_name (string) – pool/dataset (required)

  • recursive (boolean) – Recursive snapshot (-r)

  • snapshot_name (string) – Snapshot tag name (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

DELETE /storage/host/zfs/snapshots/destroy

Destroy a ZFS snapshot

Permanently destroy a ZFS snapshot. Use dry_run to preview what would be destroyed.

Request JSON Object:
  • dry_run (boolean) – Preview only

  • recursive (boolean) – Recursive destroy

  • snapshot_full_name (string) – pool/dataset@snap (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

GET /storage/host/zfs/snapshots/list

List ZFS snapshots

List all ZFS snapshots, optionally filtered by dataset

Query Parameters:
  • dataset (string) – Filter by dataset name (pool/dataset)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)

POST /storage/host/zfs/snapshots/rollback

Rollback to a ZFS snapshot

Roll back a ZFS dataset to a previous snapshot state. WARNING: This destroys all data created after the snapshot.

Request JSON Object:
  • destroy_more_recent (boolean) – Destroy more recent snapshots (-r)

  • destroy_more_recent_clones (boolean) – And clones (-R)

  • force (boolean) – Force unmount (-f)

  • snapshot_full_name (string) – pool/dataset@snap (required)

Status Codes:
Response JSON Object:
  • data (any)

  • error (string)

  • message (string)

  • success (boolean)