Improve the error message when -javaagent option fails as java.instrument is not present

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Duplicate
    • Priority: P4
    • 11
    • Affects Version/s: 9
    • Component/s: hotspot
    • svc

      $ jdk/bin/jlink --output image --module-path jdk/jmods --add-modules java.base

      $ image/bin/java -javaagent:agent.jar Hi
      Error occurred during initialization of VM
      Could not find agent library instrument on the library path, with error: dlopen(libinstrument.dylib, 1): image not found

      -javaagent is only supported when java.instrument module is present. The error message could be improved.

            Assignee:
            Gary Adams (Inactive)
            Reporter:
            Mandy Chung (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: