java - Could not initialize class sun.awt.X11FontManager using openjdk 8 on alpine linux -
i'm getting stack trace when using openjdk 8 docker image: openjdk:8-jre-alpine
java.lang.noclassdeffounderror: not initialize class sun.awt.x11fontmanager @ java.lang.class.forname0(native method) [rt.jar:1.8.0_131] @ java.lang.class.forname(class.java:348) [rt.jar:1.8.0_131] @ sun.font.fontmanagerfactory$1.run(fontmanagerfactory.java:82) [rt.jar:1.8.0_131] @ java.security.accesscontroller.doprivileged(native method) [rt.jar:1.8.0_131] @ sun.font.fontmanagerfactory.getinstance(fontmanagerfactory.java:74) [rt.jar:1.8.0_131] @ java.awt.font.getfont2d(font.java:491) [rt.jar:1.8.0_131] @ java.awt.font.getfontname(font.java:1279) [rt.jar:1.8.0_131] @ java.awt.font.getfontname(font.java:1261) [rt.jar:1.8.0_131]
it works fine using oracle version
following directions install dejavu fonts here: https://hub.docker.com/r/neduekwunife/openjdk8-jre-alpine-with-fontconfig/
added following line dockerfile:
run apk add --update ttf-dejavu && rm -rf /var/cache/apk/*
which gives me following error:
java.lang.unsatisfiedlinkerror: /usr/lib/jvm/java-1.8-openjdk/jre/lib/amd64/libfontmanager.so: error relocating /usr/lib/jvm/java-1.8-openjdk/jre/lib/amd64/libfontmanager.so: awtfontdefaultchar: symbol not found
i able work reverting older version of openjdk container. here statement in dockerfile:
from openjdk:8u121-jre-alpine
which replaced this:
from openjdk:8-jre-alpine
which equivalent update 131.
there bug documented here: https://bugs.alpinelinux.org/issues/7372
Comments
Post a Comment