Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 02 Dec 2014 00:18:54 -0600
From:      Mark Kane <mark@kane.mn>
To:        freebsd-stable@freebsd.org
Subject:   ZFS available space difference between 10.0 and 10.1
Message-ID:  <f9944f6964424fcde819ca06d210e23a@mkproductions.org>

next in thread | raw e-mail | index | archive | help
Hi all,

I updated a machine running 10.0-STABLE from April to 10.1-RELEASE and 
am noticing a discrepancy in available space on a ZFS filesystem between 
versions.

Initially upon booting 10.1-RELEASE this filesystem was reporting 0B 
avail and was unusable, though it was operating normally in 10.0-STABLE. 
I was able to clear enough space by booting back into 10.0 and removing 
files, but attempts to truncate files in 10.1-REL did not actually 
reclaim space on the filesystem. Example from 10.1:

% zpool list
NAME         SIZE  ALLOC   FREE   FRAG  EXPANDSZ    CAP  DEDUP  HEALTH  
ALTROOT
seagate2tb  1.81T  1.76T  55.5G      -         -    97%  1.00x  ONLINE  
-
tank            -      -      -      -         -      -      -  FAULTED  
-
% zfs list
NAME         USED  AVAIL  REFER  MOUNTPOINT
seagate2tb  1.76T      0  1.76T  /seagate2tb

% ls -lh /seagate2tb/isos/FreeBSD-8.1-RELEASE-i386-disc1.iso
-rw-r--r--  1 mixx941  wheel   645M Jul 18  2010 
/seagate2tb/isos/FreeBSD-8.1-RELEASE-i386-disc1.iso
% rm /seagate2tb/isos/FreeBSD-8.1-RELEASE-i386-disc1.iso
rm: /seagate2tb/isos/FreeBSD-8.1-RELEASE-i386-disc1.iso: No space left 
on device
% echo "" > /seagate2tb/isos/FreeBSD-8.1-RELEASE-i386-disc1.iso
% ls -lh /seagate2tb/isos/FreeBSD-8.1-RELEASE-i386-disc1.iso
-rw-r--r--  1 mixx941  wheel     1B Nov 27 19:38 
/seagate2tb/isos/FreeBSD-8.1-RELEASE-i386-disc1.iso

Free pool space increased as expected:

% zpool list seagate2tb
NAME         SIZE  ALLOC   FREE   FRAG  EXPANDSZ    CAP  DEDUP  HEALTH  
ALTROOT
seagate2tb  1.81T  1.76T  56.1G      -         -    96%  1.00x  ONLINE  
-

...but not the filesystem:

% zfs list
NAME         USED  AVAIL  REFER  MOUNTPOINT
seagate2tb  1.76T      0  1.76T  /seagate2tb

----------------------------------------------------------------------------

Once enough space was cleared to restore normal operation, I did a quick 
test to compare the available space in both versions with no changes to 
the filesystem between booting the 10.0 and 10.1 kernels. 10.0-STABLE 
reports over 30GB available while 10.1 reports only 2.25GB avail:

% uname -a
FreeBSD amd645200.localhost 10.0-STABLE FreeBSD 10.0-STABLE #0: Sun Apr 
27 18:55:28 CDT 2014     
mixx941@amd645200.localhost:/usr/obj/usr/src/sys/AMD645200  amd64
% zpool list
NAME         SIZE  ALLOC   FREE   FRAG  EXPANDSZ    CAP  DEDUP  HEALTH  
ALTROOT
seagate2tb  1.81T  1.75T  60.3G     0%         -    96%  1.00x  ONLINE  
-
tank            -      -      -      -         -      -      -  FAULTED  
-
% zfs list
NAME         USED  AVAIL  REFER  MOUNTPOINT
seagate2tb  1.75T  31.3G  1.75T  /seagate2tb

-----

% uname -a
FreeBSD amd645200.localhost 10.1-RELEASE FreeBSD 10.1-RELEASE #0: Mon 
Nov 24 11:15:59 CST 2014     
mixx941@amd645200.localhost:/usr/obj/usr/src/sys/GENERIC  amd64
% zpool list
NAME         SIZE  ALLOC   FREE   FRAG  EXPANDSZ    CAP  DEDUP  HEALTH  
ALTROOT
seagate2tb  1.81T  1.75T  60.3G      -         -    96%  1.00x  ONLINE  
-
tank            -      -      -      -         -      -      -  FAULTED  
-
% zfs list
NAME         USED  AVAIL  REFER  MOUNTPOINT
seagate2tb  1.75T  2.25G  1.75T  /seagate2tb

----------------------------------------------------------------------------

Has anyone seen any similar issues in 10.1, or any ideas what could 
cause the discrepancy between versions? I'm happy to provide any further 
info/testing if needed.

Thanks in advance,

-Mark



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?f9944f6964424fcde819ca06d210e23a>