Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

zpool fragmentation

14 views
Skip to first unread message

pete wright

unread,
Jan 2, 2018, 1:40:51 PM1/2/18
to
Hi there,
I was wondering how others here on the list deal with zpool
fragmentation. My general purpose laptop uses zroot, and I've noticed
over time fragmentation of my pool has grown to %42:

$ zpool list
NAME SIZE ALLOC FREE EXPANDSZ FRAG CAP DEDUP HEALTH ALTROOT
zroot 230G 87.3G 143G - 42% 37% 1.00x ONLINE -
$

I guess I have two questions:
1) is fragmentation generally bad, or just a fact of life for a system
with lots of churn?
2) if it is bad, are there any coping mechanisms people use to reduce
fragmentation?

Cheers!
-pete

--
pete wright
www.nycbug.org
@nomadlogicLA
_______________________________________________
freebsd-...@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questi...@freebsd.org"

Adam Vande More

unread,
Jan 2, 2018, 2:53:50 PM1/2/18
to
On Tue, Jan 2, 2018 at 12:40 PM, pete wright <nomad...@gmail.com> wrote:

> Hi there,
> I was wondering how others here on the list deal with zpool
> fragmentation. My general purpose laptop uses zroot, and I've noticed
> over time fragmentation of my pool has grown to %42:
>
> $ zpool list
> NAME SIZE ALLOC FREE EXPANDSZ FRAG CAP DEDUP HEALTH ALTROOT
> zroot 230G 87.3G 143G - 42% 37% 1.00x ONLINE -
> $
>
> I guess I have two questions:
> 1) is fragmentation generally bad, or just a fact of life for a system
> with lots of churn?
>

Yes but impact also depends on pool config.


> 2) if it is bad, are there any coping mechanisms people use to reduce
> fragmentation?
>

Keep lots of free space.

--
Adam

Kent Kuriyama

unread,
Jan 2, 2018, 3:17:26 PM1/2/18
to
This article explains the meaning of that column.

https://utcc.utoronto.ca/~cks/space/blog/solaris/ZFSZpoolFragmentationMeaning

On Tue, Jan 2, 2018 at 9:52 AM, Adam Vande More <amvan...@gmail.com>
wrote:
> To unsubscribe, send any mail to "freebsd-questions-
> unsub...@freebsd.org"
>



--
Kent, kent.k...@gmail.com

pete wright

unread,
Jan 2, 2018, 3:18:35 PM1/2/18
to
On Tue, Jan 2, 2018 at 12:16 PM, Kent Kuriyama <kent.k...@gmail.com> wrote:
> This article explains the meaning of that column.
>
> https://utcc.utoronto.ca/~cks/space/blog/solaris/ZFSZpoolFragmentationMeaning
>

Oh fantastic - thanks Kent, this looks like exactly what I was looking for.

-pete

--
pete wright
www.nycbug.org
@nomadlogicLA

Karl Vogel

unread,
Jan 2, 2018, 3:34:46 PM1/2/18
to
On Tue, Jan 02, 2018 at 01:52:54PM -0600, Adam Vande More wrote:
> On Tue, Jan 2, 2018 at 12:40 PM, pete wright <nomad...@gmail.com> wrote:
>
>> are there any coping mechanisms people use to reduce fragmentation?
>
> Keep lots of free space.

If you create an unmounted empty filesystem with a reservation to
prevent the zpool from filling up, it gives you behavior similar to
ufs's reserved blocks. I reserve 5-10% to make sure the system doesn't
become completely unusable:

root# zfs create -o reservation=50G -o mountpoint=none rpool/reservation

--
Karl Vogel I don't speak for the USAF or my company

Sheep learn to recognise celebrity faces from different angles
--"New Scientist", 8 Nov 2017
0 new messages