Upgrade to Pro — share decks privately, control downloads, hide ads and more …

ZFS at a Glance

ZFS at a Glance

A presentation on NIU LUG. Basic concepts and features about the ZFS file system.

Zhihao Yuan

June 27, 2011
Tweet

More Decks by Zhihao Yuan

Other Decks in Technology

Transcript

  1. Concept 0: Copy-on-Write • Data integrity vs. File system consistency

    • COW: No journal*, no locking, SSD friendly. * O_FSYNC is an exception
  2. Concept 1: Pooled Storage zpool create ztank mirror ada0p1 ada1p1

    da1s1 log ada2p1 zfs create -o compression=on -o setuid=off ztank/home zfs create -o atime=off ztank/var zfs create ztank/usr zfs create ztank/usr/local
  3. Pool Maintenance • Portability zpool import -R /fakeroot ztank2 zpool

    export ztank2 • Scalability & Availability # adds/replaces the devices online zpool add ztank raidz gpt/disk3 gpt/disk4 da0s1 zpool replace ztank /dev/da1s1 gpt/disk6 • Updatability zpool upgrade # updates to the latest on-disk format online zfs upgrade # as well as the file systems
  4. Concept 2: Datasets A zpool can be used to create:

    • File system zfs set mountpoint=/usr/home ztank/home • Volume A raw/block device with ZFS Copy-on-Write semantic zfs create -V 10G ztank/linux mkfs.ext4 /dev/zvol/ztank/linux • Snapshot A read-only, light-weight copy of a file system or volume zfs snapshot ztank@now zfs rollback ztank@now
  5. Features • Performance Prefetch, ARC/L2ARC, dynamic striping • Stability &

    Safety Copy-on-Write transactions, self-healing with checksum • Space Utilization Variable length blocks, compression, dedup (ZFS v28) • Security NFSv4 ACL, zfs-cryto (Oracle® only)
  6. Resources 1. Man pages: zpool(1M), zfs(1M) 2. Oracle Solaris ZFS

    Administration Guide: http://download. oracle.com/docs/cd/E19253-01/819-5461/index.html 3. ZFS blogs: http://blogs.oracle.com/main/tags/zfs 4. FreeBSD: http://wiki.freebsd.org/ZFS