ZFS: managing filesystems

It’s been quite a while since I’ve cleared one of internal disks in my Netra t105 to bring it under ZFS control. As a result, I now have a 33Gb zfs-pool to experiment with. Today I had some spare time, so I decided to share with you the very basics of managing ZFS filesystems.

By default, when you create a zfs-pool, all of its disk space is represented as a single filesystem with the same name. This filesystem also gets a mountpoint with the same name and is automatically mounted off /. So, after doing a zpool create (here is my example) you can immediately start working with your newly made filesystem.

At the moment I’ve got only 1 additional filesystem created, I use it for Oracle 10g. So here’s how it looks:

According to ZFS concepts, all the newly made filesystems may use all the available disk space of the zfs-pool they belong to. So, when I create another filesystem in my stock pool, this filesystem has more than 30Gb available to it:

As you have probably guessed, quota is the parameter name, while set is a keyword to alter parameters values. There is quite a number of ZFS filesystem parameters, and most of them you can modify, but there are also some which are read-only. Here's an example of such a parameter, and you can see what happens if you try modifying them:

You can find the full list of ZFS filesystem parameters on the man page for zfs, as for me – I’ll show you only 1 more parameter today, and a very useful one in my opinion: a mount point. As all the rest things about ZFS, this parameter is very easy to change, and you even have the filesystem automatically remounted for you: