Skip to content
This repository was archived by the owner on Feb 26, 2020. It is now read-only.

Make taskqueues mimic loopback device's -20 nice value #99

Closed
wants to merge 1 commit into from

Conversation

ryao
Copy link
Contributor

@ryao ryao commented Apr 19, 2012

A comparison of swap on zvols with swap on the loopback device revealed
that the loopback device sets the nice value to -20. An audit of the
code does not reveal any downside to doing that, so we can do it too.

A comparison of swap on zvols with swap on the loopback device revealed
that the loopback device sets the nice value to -20.  An audit of the
code does not reveal any downside to doing that, so we can do it too.
@ryao
Copy link
Contributor Author

ryao commented Apr 23, 2012

My earlier tests with dd if=/dev/zero of=/test bs=4096 count=1048576 showed 220MB/sec sequential write performance on a 6-disk raidz2 vdev. Now I am seeing 286MB/sec. I believe that this patch caused it, although I have not had time to formally test my server with and without this patch to be certain.

@behlendorf
Copy link
Contributor

Interesting, I'm surprised there's such a large effect. If true this is certainly some low hanging fruit worth investigating. However, rather than applying this policy to all taskq threads it would would be better to use the existing provided Solaris interface. The taskq_create() function takes a priority which is roughly translated in to a niceness value. I would try and target only a subset of the threads by passing a priority of MAX_RT_PRIO.

@behlendorf
Copy link
Contributor

I did some quick testing of this change on a larger 3 groups of 8+2raidz configuration and didn't see any performance improvement. While this was just a quick test we're going to need to run some more careful targeted tests before merging this to determine if this improves things or not.

@ryao ryao closed this Jun 29, 2012
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants