Page 1 of 1

Back to basics

PostPosted: Tue Sep 04, 2018 9:19 pm
by tim.rohrer
Since I installed OpenZFS, I have been trying to track down some gremlins.


Code: Select all
spl.kext_version: 1.7.2-1
zfs.kext_version: 1.7.2-1

I noted the high level of ram usage (I have quad core MacPro w/ 16GB ram running 10.13.6), and research led me to adding the following line in /etc/zfs/zsysctl.conf:

Code: Select all

This seemed to reduce the number of situations where the system slowed significantly, but when I did the first zfs send pool/dataset | zfs recv newpool, the send seemed to complete (because I watched the blinky lights on the enclosures) but the server froze during the process to the point where I had to do a hard reboot afterwards.

As I'm looking closer at some things, I note the number of kernel_task threads has remained at a level I think is quite high. I managed to get a screen cap, which I've posted below.

It seems like 16G should be enough ram for this small server.

But, it is the thread count I'm really surprised about. I've searched online, but haven't found a good reference for what should be considered a reasonable number of threads.

Can someone provide some comparisons for me? Or tell me right now if this is a clear indication of the poor performance?

Re: Back to basics

PostPosted: Tue Sep 04, 2018 10:21 pm
by Sharko
For what it is worth, my El Capitan Mac Pro 5,1 (six cores) has 914 kernel task threads with Firefox and a dozen tabs, terminal, Disk Utility, and Activity Monitor. So 1265 threads in an OS version two releases newer doesn't seem completely off the charts.

Re: Back to basics

PostPosted: Wed Sep 05, 2018 8:43 am
by tim.rohrer
How about memory usage by kernel_task?

Do you have zfs_arc_max set in zsysctl.conf? Other tweaks?

I set my max to 4GB because I have 16GB total, and try to run a VM on that server. Beyond that, the server doesn't do a heck of a lot.

Since the memory consumed by ZFS had been so high, I sometimes found I could not get the VM started without reducing its own memory requirement.

But, is 4GB too low for ARC? And, do I have t set the arc_meta limit too?

Re: Back to basics

PostPosted: Wed Sep 05, 2018 4:10 pm
by lundman
I have myself wondered about the thread counts in ZFS, since those numbers are all default from illumos - nobody has sat down and confirmed those defaults are still good for osx. Don't even know if it is something that needs to be looked at :)

Re: Back to basics

PostPosted: Wed Sep 05, 2018 8:56 pm
by Sharko
Well, now I have a root shell doing a lengthy delete with 'rm -Rf' and my kernel thread count is up to 1266, using 14.84 GB of memory out of 32 GB. I do have a limit set on zfs memory usage at 8GB, which I believe Brendan has said will use about 150% of the stated limit due to overhead, or about 12 GB.