Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 26 Sep 2015 13:52:18 +1000
From:      Peter Jeremy <peter@rulingia.com>
To:        Pekka =?iso-8859-1?Q?J=E4rvinen?= <pekka.jarvinen@gmail.com>
Cc:        freebsd-fs@freebsd.org
Subject:   Re: Missing free space from new raidz2 zpool
Message-ID:  <20150926035218.GF3478@server.rulingia.com>
In-Reply-To: <CABvnMcj9JTgVCXcWhy4KEb8gPq5gSQgQ1ba10mQ_LpVkrxZpjg@mail.gmail.com>
References:  <CABvnMcj9JTgVCXcWhy4KEb8gPq5gSQgQ1ba10mQ_LpVkrxZpjg@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--vmttodhTwj0NAgWp
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On 2015-Sep-24 19:36:50 +0300, Pekka J=E4rvinen <pekka.jarvinen@gmail.com> =
wrote:
>I bought 6 new 8 TB drives and created new raidz2 pool with these drives.
>
>My question is why zfs list and df is only showing 14.5T free? Shouldn't it
>be more close to 30T? Or is that old zfs metadata somehow lurking around
>and zfs is reading that? Bug?

Your pool seems to be sized correctly but the filesystem can't see all
the space.  If you're concerned about old metadata, destroy your new
pool and then dd zeroes over the first and last few MB of each drive -
which is where ZFS stores its metadata:

for i in /dev/ada{0,1,2,3,4,5};do
  dd if=3D/dev/zero of=3D$i bs=3D64k count=3D32
  dd if=3D/dev/zero of=3D$i bs=3D64k oseek=3D122094000
done

># zpool iostat storage2
>               capacity     operations    bandwidth
>pool        alloc   free   read  write   read  write
>----------  -----  -----  -----  -----  -----  -----
>storage2     900K  43.5T      0      1      0  7.84K

The 43.5T looks correct.  "zpool list" would be a better command.

># zdb storage2
>
>Cached configuration:
=2E..
>                asize: 48009350479872
=2E..
>MOS Configuration:
=2E..
>                asize: 48009350479872

That's also correct.

As an experiment, I simulated your configuration:
# cd /tmp
# mkdir zfs
# cd zfs
# for i in 0 1 2 3 4 5;do truncate -s 7814026584k d$i;done
# zpool create storage2 raidz2 /tmp/zfs/d?
# zpool list storage2
NAME       SIZE  ALLOC   FREE  EXPANDSZ   FRAG    CAP  DEDUP  HEALTH  ALTRO=
OT
storage2  43.5T   165K  43.5T         -     0%     0%  1.00x  ONLINE  -
# zfs list storage2
NAME       USED  AVAIL  REFER  MOUNTPOINT
storage2  88.9K  28.1T  32.0K  /storage2
# zfs get all storage2
NAME      PROPERTY              VALUE                  SOURCE
storage2  type                  filesystem             -
storage2  creation              Sat Sep 26 13:31 2015  -
storage2  used                  88.9K                  -
storage2  available             28.1T                  -
storage2  referenced            32.0K                  -
storage2  compressratio         1.00x                  -
storage2  mounted               yes                    -
=2E..

--=20
Peter Jeremy

--vmttodhTwj0NAgWp
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQJ8BAEBCgBmBQJWBhZyXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXRFRUIyOTg2QzMwNjcxRTc0RTY1QzIyN0Ux
NkE1OTdBMEU0QTIwQjM0AAoJEBall6Dkogs0C9cP/2/PRbu44/LpFScWnvWEvQe/
MHsuJqdw4vnQkZj/F+Jf+XYFh+CMVOpi6/2PLdMr40aC/Iw6EkKR6+EQDVHR4qGt
al9YC7ctCRcyHfwE5hbQvjibQFpI7nWDaT9j9ZsyiIMtMdprV9LyyT/qjkHNo4AM
f/iNJ0A9VZXgPxfIX309dO4z62SfVvr8p+M3FKHB/KjFQXeebfQr87bjhDyObs/5
jsmbjiTWJaWqIMpkf+vfL/YmHRy89Z1Ya5TJKcioRkiUgZ0dcRW0lUtaU1Yy+HiU
p4id/hwrFmmlbCGwmWNipg5F5+3iRI1A0mZlF0pecQJnPSw2PX31s/FTNWUfweLL
KgA+/abqA+24w30jhPkHN8uBzAAFbmtK+Z1jFPoA+i6BDPzQJSSgqGmhgdIoqCB6
txMg9aIzgmyl9i7q7g6S1dT+3Yo+n7XlIn9bw/jf62bZ/buWdRtxduVy4/tVD2/C
6/QaRou37oENBPLaTewcagfCnifLLkBnpw+SJfJd3IVyjN4huH0FLyPY2xnVB+w9
zWPu2Y+e/aqr9n1Tis3qmBoGa/t4JLXuZyCg2A+rpuzOyyoJCcPGZUVgrsaQqL5X
+J+IuXoQ+U0DFWeiKDmmT2hbgtfGLlAntqoQ43NJ7dyriD+gr2O8lAbQahU3sOBj
+pSn2KZJ74cusZplPw7N
=x5vu
-----END PGP SIGNATURE-----

--vmttodhTwj0NAgWp--



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