How to create a simple ZFS pool (mirror and RAIDZ) on Solairs 10
This is a simple how-to on creating a ZFS pool. If you do not know what ZFS is, click here.
I will use '' to specify command line type and $ as prompt.
Creating a new pool with a file system:
$'zpool create <pool name> <mirror or raidz> <disks at least 2>
Example:
$'zpool create store raidz c0t0d0 c0t1d0 c0t2d0
Now we check it:
$'zpool list'
Example:
$'zpool list'
NAME SIZE USED AVAIL CAP HEALTH ALROOT
store 80G 23.0k 80G 0% ONLINE -
Creating a new file system/container:
$'zfs create <pool name>/<new container>
Example:
$'zfs create store/homes'
We check it again with 'zfs list'
Now you can use 'cd /<pool name>' to utilize your new ZFS pool.
Seting a quota is as easy as $'zfs set quota=<size> <pool or pool/sub-pool>
Example:
$'zfs set quota=1g store/homes' This sets a 1GB quota on the homes container.
If you want to learn more, here is a great flash movie I used as a reference.
Posted at 11:18PM May 04, 2007 by Andrew Neumann in Sun | Comments[0]