Date: Sat, 16 Feb 2013 22:23:28 +1100 From: Peter Jeremy <peter@rulingia.com> To: freebsd-fs@freebsd.org Subject: Calculating ZFS pool sizes at different ashift values Message-ID: <20130216112328.GA416@server.rulingia.com>
next in thread | raw e-mail | index | archive | help
--OgqxwSJOaUobr8KG Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I am trying to work out the impact of converting my ZFS pools from ashift=3D9 to ashift=3D12. In theory, that's just a matter of getting a list of the sizes of each object, rounding each size up to 4KiB and summing the total but I'm having problems with the "each object" bit. "zdb -dd" reports each object and the 'dsize' column gives the on-disk size. But it lists the objects in each filesystem snapshot so the same object can appear multiple times in the output. And object numbers are only unique within a filesystem, though they don't appear to correlate with znode numbers for files. Further, the following appears to show that the same object can have different sizes in different snapshots: Dataset zroot/var/obj@r242865a [ZPL], ID 8205, cr_txg 10094330, 820M, 75640= objects Object lvl iblk dblk dsize lsize %full type 54536 2 16K 128K 55.5K 256K 100.00 ZFS plain file Dataset zroot/var/obj@r237444 [ZPL], ID 30, cr_txg 7939066, 573M, 64913 obj= ects 54536 1 16K 10.0K 2.50K 10.0K 100.00 ZFS plain file Does this represent a total of 55.5K on disk (the 2.5K in the second snapshot is part of the 55.5K in the first snapshot) or 58K on disk (the two objects are distinct despite having the same number)? Can anyone explain how to identify unique objects and their sizes within a zpool? --=20 Peter Jeremy --OgqxwSJOaUobr8KG Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlEfbC8ACgkQ/opHv/APuIdZhwCgwYfWzfJaLu3OfrMWP2S9TAp2 qOIAn24+DmzgNpMRWtol9JAmknMHFqW6 =mvvs -----END PGP SIGNATURE----- --OgqxwSJOaUobr8KG--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130216112328.GA416>