Hadoop Common
  1. Hadoop Common
  2. HADOOP-3654

Log4J logging of stack trace may deadlock JRockit in TestFileSystem


    • Type: Bug Bug
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Later
    • Affects Version/s: 0.19.0
    • Fix Version/s: None
    • Component/s: conf
    • Labels:
    • Environment:


      This is being added as a bugrep so that other people can find it, and the workaround

      1. On my machine TestFileSystem will hang, even overnight -even though the build was set with a timeout.
      2. halting the build left a JVM running; it was not being killed.
      3. Under the IDE, the main thread appears hung in the native library call to get a stack trace, somewhere inside Log4J
      4. the IDE could not halt the build, and could not be shut down cleanly either

      The fix for this problem was to edit conf/log4j.properties and switch to a log4J log pattern that did not print the line of the code

      log4j.appender.console.layout.ConversionPattern=%-4r %-5p %c %x - %m%n

      Given that working out a stack trace can be an expensive call, and that it can apparently hang some JVMs, perhaps it should not be the default.

      1. hadoop-3654.patch
        0.8 kB
        Steve Loughran


        Gavin made changes -
        Reporter Steve Loughran [ steve_l ] Steve Loughran [ stevel@apache.org ]
        Steve Loughran made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Later [ 7 ]
        Owen O'Malley made changes -
        Status Patch Available [ 10002 ] Open [ 1 ]
        Steve Loughran made changes -
        Status Open [ 1 ] Patch Available [ 10002 ]
        Steve Loughran made changes -
        Field Original Value New Value
        Attachment hadoop-3654.patch [ 12385398 ]
        Steve Loughran created issue -


          • Assignee:
            Steve Loughran
          • Votes:
            0 Vote for this issue
            1 Start watching this issue


            • Created: