Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-14074

(7.2.z) OutOfMemoryError: Direct buffer memory when repeating reload

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • 7.2.4.CR1, 7.2.4.GA
    • 7.1.0.GA, 7.2.0.GA.CR1
    • Undertow
    • None
    • Hide
      • Configure -XX:MaxDirectMemorySize=16M for server to hit error earlier . E.g. add into JAVA_OPTS of standalone.conf
      • run server
      • Run this reproducer
        loop.sh
        #!/bin/bash
        for i in {1..100}
        do
          echo $i
          ${jboss.home}/bin/jboss-cli.sh -c ":reload"
          if [ $? == 1 ]
          then
              break
          fi
        done
        
      Show
      Configure -XX:MaxDirectMemorySize=16M for server to hit error earlier . E.g. add into JAVA_OPTS of standalone.conf run server Run this reproducer loop.sh #!/bin/bash for i in {1..100} do echo $i ${jboss.home}/bin/jboss-cli.sh -c ":reload" if [ $? == 1 ] then break fi done

      Approximately on 40th reload server starts to emit OutOfMemoryError: Direct buffer memory

      19:07:12,655 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-6) MSC000001: Failed to start service org.wildfly.undertow.listener.default: org.jboss.msc.service.StartException in service org.wildfly.undertow.listener.default: Failed to start service
      	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1978)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      	at java.lang.Thread.run(Thread.java:748)
      Caused by: java.lang.OutOfMemoryError: Direct buffer memory
      	at java.nio.Bits.reserveMemory(Bits.java:693)
      	at java.nio.DirectByteBuffer.<init>(DirectByteBuffer.java:123)
      	at java.nio.ByteBuffer.allocateDirect(ByteBuffer.java:311)
      	at org.xnio.BufferAllocator$2.allocate(BufferAllocator.java:57)
      	at org.xnio.BufferAllocator$2.allocate(BufferAllocator.java:55)
      	at org.xnio.ByteBufferSlicePool.allocate(ByteBufferSlicePool.java:147)
      	at io.undertow.server.XnioByteBufferPool.<init>(XnioByteBufferPool.java:40)
      	at io.undertow.server.protocol.http.HttpOpenListener.<init>(HttpOpenListener.java:72)
      	at org.wildfly.extension.undertow.HttpListenerService.createOpenListener(HttpListenerService.java:85)
      	at org.wildfly.extension.undertow.ListenerService.start(ListenerService.java:160)
      	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:2032)
      	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1955)
      	... 3 more
      

              rhn-support-iweiss Ingo Weiss
              mchoma@redhat.com Martin Choma
              Votes:
              0 Vote for this issue
              Watchers:
              17 Start watching this issue

                Created:
                Updated:
                Resolved: