Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8256008

UL does not report anything if disk writing fails

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 11, 16
    • Fix Version/s: 16
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Introduced In Version:
      9
    • Resolved In Build:
      b27

      Description

      If there are no disk space enough to write UL, it does not report. So the user cannot know lack of logs timely.

      `LogFileStreamOutput::write()` uses `jio_fprintf()` and `fflush()` to write log. However return values of them would not be checked.
      We should check them, and should report what happened if error occurred.


      How to reproduce on Linux:

      1. Mount tmpfs with 512K

      ```
      $ mkdir /tmp/tmp
      $ mount -t tmpfs -o size=512k tmpfs /tmp/tmp
      ```

      2. Run `java` with `-Xlog`

      ```
      $ java -Xlog:all=trace:file=/tmp/tmp/all.log --version
      ```

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              ysuenaga Yasumasa Suenaga
              Reporter:
              ysuenaga Yasumasa Suenaga
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: