Code Yarns ‍👨‍💻
Tech BlogPersonal Blog

sun.misc.BASE64Encoder ClassNotFoundException

📅 2019-Aug-03 ⬩ ✍️ Ashwin Nanjappa ⬩ 🏷️ java ⬩ 📚 Archive

Problem

Running a JNLP application file using javaws would terminate with this error:

Caused by: java.lang.ClassNotFoundException: sun.misc.BASE64Encoder

Solution

Turns out that my Ubuntu was using OpenJDK 11 and Oracle had removed the sun.misc.BASE64Encoder class in Java 9.

Once I installed OpenJDK 8 (Java 8) and made it the default Java, I was able to run the JNLP application without any errors.


© 2022 Ashwin Nanjappa • All writing under CC BY-SA license • 🐘 @codeyarns@hachyderm.io📧