Go to main content
Oracle® ZFS Storage Appliance Administration Guide, Release OS8.7.0

Exit Print View

Updated: July 2017
 
 

Destroying a Snapshot (CLI)

Use the following procedure to destroy a snapshot.

Before You Begin

  • To complete this procedure, you must have Super-User privileges or one of the following role authorizations within the Projects and shares scope:

    • destroySnap - Allows users to only destroy snapshots.

    • destroy - Grants privileges to remove projects and shares, including snapshots.

  • To add authorizations to a role, see Editing Authorizations for a Role (CLI).

  1. Go to shares and select the project, or select the project and then a share.
    hostname:> shares select myproject
    hostname:shares myproject> select demo_share
  2. Enter snapshots.
    hostname:shares myproject/demo_share> snapshots
  3. Enter list to view the list of snapshots for the project or share.
    hostname:shares myproject/demo_share snapshots> list
    demo_snap1
    demo_snap2
  4. Use the destroy command to delete an individual snapshot using one of two methods:
    • Select the snapshot you want to delete, then type destroy.

      hostname:shares myproject/demo_share snapshots> select demo_snap1
      hostname:shares myproject/demo_share@demo_snap1> destroy
    • Type destroy followed by the snapshot name.

      hostname:shares myproject/demo_share snapshots> destroy demo_snap1
  5. Type Y to confirm your action.
    This will destroy all data in "demo_snap1"! Are you sure? (Y/N) Y

Related Topics