# zfs.resource.snapshot.clone

Clone a ZFS snapshot to create a new dataset.

Args: data: Clone parameters containing: - snapshot: Source snapshot path to clone (e.g., ‘pool/dataset@snapshot’). - dataset: Destination dataset path for the clone (e.g., ‘pool/clone’). - properties: Optional ZFS properties to set on the cloned dataset.

Returns: None on success.

Raises: ValidationError: If snapshot not found, destination already exists, or source is not a snapshot.

Examples: # Clone a snapshot to a new dataset clone({“snapshot”: “tank/data@backup”, “dataset”: “tank/data_clone”})

> # Clone with properties clone({ “snapshot”: “tank/data@backup”, “dataset”: “tank/data_clone”, “properties”: {“compression”: “lz4”, “quota”: “10G”} })

Type: object

##

Type: array
No Additional Items

#### Tuple Validation

##### Parameter 1: data

#### data

Type: object

Clone parameters for cloning ZFS snapshots.

No Additional Properties

##

#### Snapshot

Type: string

Source snapshot path to clone (e.g., 'pool/dataset@snapshot').

Must be at least `1` characters long

##

#### Dataset

Type: string

Destination dataset path for the clone (e.g., 'pool/clone').

Must be at least `1` characters long

##

#### Properties

Type: object Default: {}

ZFS properties to set on the cloned dataset.

##

Each additional property must conform to the following schema

## Any of

Type: string
Type: integer

##

#### Result

Type: null

Required roles: SNAPSHOT_WRITE