atom feed18 messages in org.freebsd.freebsd-fsZFS and disk usage
FromSent OnAttachments
Mark SchoutenApr 13, 2012 5:20 am 
Volodymyr KostyrkoApr 13, 2012 6:10 am 
Mark SchoutenApr 13, 2012 6:28 am 
Peter MaloneyApr 13, 2012 6:32 am 
Johannes TotzApr 13, 2012 8:26 am 
Tom EvansApr 13, 2012 8:44 am 
Freddie CashApr 13, 2012 8:45 am 
Freddie CashApr 13, 2012 8:49 am 
Volodymyr KostyrkoApr 13, 2012 9:32 am 
Ronald KlopApr 15, 2012 4:14 am 
Mark SchoutenApr 16, 2012 1:35 am 
Volodymyr KostyrkoApr 16, 2012 11:32 pm 
Mark SchoutenApr 17, 2012 1:37 am 
Volodymyr KostyrkoApr 17, 2012 2:54 am 
Mark SchoutenApr 17, 2012 3:02 am 
Volodymyr KostyrkoApr 17, 2012 3:10 am 
Mark SchoutenApr 17, 2012 3:22 am 
Mark SchoutenMay 3, 2012 2:28 am 
Subject:ZFS and disk usage
From:Mark Schouten (ma@tuxis.nl)
Date:Apr 13, 2012 5:20:43 am
List:org.freebsd.freebsd-fs

Hi,

I'm having some issues with a FreeBSD box using ZFS to serve iscsi to other
boxes.

[root@storage ~]# zpool list NAME SIZE USED AVAIL CAP HEALTH ALTROOT storage 1.77T 431G 1.34T 23% ONLINE -

As you can see, the zpool is at only 23% of it's capacity. However, if you get a
list of filesystems with "zfs list", you see that there is only 138GB free space
left. [root@storage ~]# zfs list NAME USED AVAIL REFER MOUNTPOINT storage 1.60T 138G 431G /storage storage/ZFS_FS_1 20G 158G 16K - storage/ZFS_FS_2 20G 158G 16K - storage/ZFS_FS_3 100G 238G 16K - storage/ZFS_FS_4 20G 158G 16K - storage/ZFS_FS_5 1G 139G 16K - storage/ZFS_FS_6 400G 538G 16K - storage/ZFS_FS_7 20G 158G 16K - storage/ZFS_FS_8 400G 538G 16K - storage/ZFS_FS_9 20G 158G 16K - storage/ZFS_FS_10 20G 158G 16K - storage/ZFS_FS_11 20G 158G 16K - storage/ZFS_FS_12 150G 288G 16K - storage/ZFS_FS_13 20G 158G 16K -

These are fiesystems that are created with the following command. zfs create -V ${size}GB ${ZFS_ROOT}/${diskname}

Now, it seems that zpool only counts the data that is actually written on the
disk, and that zfs counts both the sum of the individual filesystems *and* the
data actually written on disk. If I was to create a new filesystem of 138GB, the
filesystem would be full, eventhough that that's not the case.

This seems weird, but I'm not sure if it's me doing something wrong, or if its a
bug. Please enlighten me, thanks.

Some more info: [root@storage ~]# uname -a FreeBSD storage.storage 8.2-RELEASE FreeBSD 8.2-RELEASE #0: Thu Feb 17 02:41:51
UTC 2011 ro@mason.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC amd64

[root@storage ~]# zpool get all storage NAME PROPERTY VALUE SOURCE storage size 1.77T - storage used 431G - storage available 1.34T - storage capacity 23% - storage altroot - default storage health ONLINE - storage guid 10905194744545589060 default storage version 15 default storage bootfs - default storage delegation on default storage autoreplace off default storage cachefile - default storage failmode wait default storage listsnapshots off default

[root@storage ~]# zfs get all storage NAME PROPERTY VALUE SOURCE storage type filesystem - storage creation Tue May 10 11:59 2011 - storage used 1.60T - storage available 138G - storage referenced 431G - storage compressratio 1.00x - storage mounted yes - storage quota none default storage reservation none default storage recordsize 128K default storage mountpoint /storage default storage sharenfs off default storage checksum on default storage compression off default storage atime on default storage devices on default storage exec on default storage setuid on default storage readonly off default storage jailed off default storage snapdir hidden default storage aclmode groupmask default storage aclinherit restricted default storage canmount on default storage shareiscsi off default storage xattr off temporary storage copies 1 default storage version 4 - storage utf8only off - storage normalization none - storage casesensitivity sensitive - storage vscan off default storage nbmand off default storage sharesmb off default storage refquota none default storage refreservation none default storage primarycache all default storage secondarycache all default storage usedbysnapshots 0 - storage usedbydataset 431G - storage usedbychildren 1.18T - storage usedbyrefreservation 0 -