If I add -javaagent:/usr/local/newrelic.jar jsvc fails to start the jvm, errors out with: /usr/local/openjdk8/jre/lib/amd64/libinstrument.so: Undefined symbol "JLI_ManifestIterate" If I LD_PRELOAD /usr/local/openjdk8/lib/amd64/jli/libjli.so then it works. openjdk 1.8.0_92, freebsd 10.2, amd64, newrelic agent 3.29.0
Could you set JAVA_HOME is set to /usr/local/openjdk8, jsvc defines a set of locations for libjli.so in locations.h but all candidate ones relevant to FreeBSD are relative to $JAVA_HOME.
Alex, is this still an issue with JAVA_HOME set?
Same thing happens to me with a JMX agent. jsvc -javaagent:/usr/local/etc/jmx/JMXAgent.jar ... Fails with: /usr/local/openjdk8/jre/lib/amd64/libinstrument.so: Undefined symbol "JLI_ManifestIterate" Strangely, it worked fine with openjdk8 8.112.16 (and previous versions), but fails now after upgrading to 8.112.16_2. Setting JAVA_HOME doesn't help.
Hi, I was just hit by this as well... It doesn't happen right away though, it happened after running 20 minutes. Did you find a soultion? Palle
It looks like libinstrument.so requires libjli.so but isn't linked with it.
In particular, I'd suggest looking at the build logic in work/openjdk/jdk/make/lib/ServiceabilityLibraries.gmk It has some BSD logic in there for libinstrument, but it looks like it isn't being picked up properly.
A commit references this bug: Author: glewis Date: Tue Mar 6 04:41:09 UTC 2018 New revision: 463688 URL: https://svnweb.freebsd.org/changeset/ports/463688 Log: . Link libinstrument.so with iconv and jli as intended. PR: 210297 Changes: head/java/openjdk8/Makefile head/java/openjdk8/files/patch-jdk-make-lib-ServiceabilityLibraries.gmk
I've committed a change which links libinstrument.so with libjli.so as intended. Let me know if that fixes the problem for you.
Please reopen if you have problems.