High CPU in selector polls on EAP 7
Environment
- JBoss Enterprise Application Platform (EAP) 7.x
Issue
- On EAP 7, we note high CPU in default I/O threads performing selector polls:
"default I/O-24" #142 prio=5 os_prio=0 tid=0x0000000005e7a800 nid=0x1ce7d runnable [0x00007fff4b934000]
java.lang.Thread.State: RUNNABLE
at sun.nio.ch.EPollArrayWrapper.epollWait(Native Method)
at sun.nio.ch.EPollArrayWrapper.poll(EPollArrayWrapper.java:269)
at sun.nio.ch.EPollSelectorImpl.doSelect(EPollSelectorImpl.java:93)
at sun.nio.ch.SelectorImpl.lockAndDoSelect(SelectorImpl.java:86)
- locked <0x00000000899d7720> (a sun.nio.ch.Util$3)
- locked <0x00000000899d7730> (a java.util.Collections$UnmodifiableSet)
- locked <0x00000000899d76d8> (a sun.nio.ch.EPollSelectorImpl)
at sun.nio.ch.SelectorImpl.select(SelectorImpl.java:97)
at org.xnio.nio.WorkerThread.run(WorkerThread.java:551)
Resolution
- Update to 7.2 Update 5+ and set the
xnio.nio.alt-queued-serversystem property to true. This property This content is not included.now defaults to true on 7.3 Update 3+. - Identify and address any other causes of task thread stalls and exhaustion
Root Cause
- This content is not included.XNIO-335
- This content is not included.JBEAP-17711
- Growing CPU in these I/O threads can also been seen as a symptom or side effect of persistent request task thread exhaustion as the continually inbound connections/requests pile up here on the I/O threads with no task threads ever available again for them to delegate and clear their tasks to.
Components
Category
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.