Wednesday, November 20, 2024
HomeSolarisSolaris system administrationZFS: List or View Filesystems

ZFS: List or View Filesystems

The distinction between ZFS pools and filesystems is worth repeating. A ZFS filesystem cannot exist outside of a ZFS pool. Creating a ZFS pool also creates a ZFS filesystem of the same name. Understanding the second part can help avoid confusion. This tech-recipe describes the simple step to list the ZFS filesystems configured on the system.


Running the zfs list command will show all ZFS filesystems on the system:

# zfs list
NAME USED AVAIL REFER MOUNTPOINT
shiny 75.5K 19.2G 24.5K /shiny
techrx 7.17M 19.2G 25.5K /techrx
techrx/home 102K 19.2G 28.5K /export/home
techrx/home/davak 24.5K 4.98M 24.5K /export/home/davak
techrx/home/qmchenry 24.5K 19.2G 24.5K /export/home/qmchenry
techrx/logs 6.96M 19.2G 6.91M /techrx/logs
techrx/logs/httpd 24.5K 19.2G 24.5K /techrx/logs/httpd
techrx/logs/mail 24.5K 19.2G 24.5K /techrx/logs/mail

The display shows a system configured with two pools: shiny (a mirror, although that cannot be seen from this view) and techrx. The only way to know these are pools is that they are top-level names — techrx is a pool (and its associated filesystem) and techrx/home is a descendent filesystem under techrx.

Also of interest in this output, the filessytem techrx/home is mounted in the Solaris filesystem (the one you cd around in) under /export/home. Descendents of techrx/home are, likewise, under /export/home (like /export/home/qmchenry). It can be seen from the output that the filesystem techrx/home/davak has a 5M quota while other techrx/home filesystems show the same available disk space as techrx and techrx/home.

Quinn McHenry
Quinn McHenry
Quinn was one of the original co-founders of Tech-Recipes. He is currently crafting iOS applications as a senior developer at Small Planet Digital in Brooklyn, New York.
RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

LATEST REVIEWS

Recent Comments

error: Content is protected !!