Fedora Account System
Red Hat Associate
Red Hat Customer
Description of problem: Fails to run lobo GUI install jar with error: java.lang.NoClassDefFoundError: Could not initialize class sun.awt.X11.XToolkit. The problem is inside the JRE, not in lobo, as the stack trace below shows. Version-Release number of selected component (if applicable): OpenJDK 64-Bit Server VM (build 25.151-b12, mixed mode) How reproducible: Run the lobo installer Steps to Reproduce: 1. Download https://github.com/oswetto/LoboEvolution/releases/download/0.99.2/install-lobo-0.99.2.jar 2. sudo java -jar install-lobo-0.99.2.jar 3. Actual results: bill @ dell-precision-m6300 ~/Downloads $ sudo java -jar install-lobo-0.99.2.jar [sudo] password for bill: No protocol specified Exception in thread "main" java.lang.NoClassDefFoundError: Could not initialize class sun.awt.X11.XToolkit at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at java.awt.Toolkit$2.run(Toolkit.java:860) at java.awt.Toolkit$2.run(Toolkit.java:855) at java.security.AccessController.doPrivileged(Native Method) at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:854) at sun.swing.SwingUtilities2.getSystemMnemonicKeyMask(SwingUtilities2.java:2020) at javax.swing.plaf.basic.BasicLookAndFeel.initComponentDefaults(BasicLookAndFeel.java:1158) at javax.swing.plaf.metal.MetalLookAndFeel.initComponentDefaults(MetalLookAndFeel.java:431) at javax.swing.plaf.basic.BasicLookAndFeel.getDefaults(BasicLookAndFeel.java:148) at javax.swing.plaf.metal.MetalLookAndFeel.getDefaults(MetalLookAndFeel.java:1577) at javax.swing.UIManager.setLookAndFeel(UIManager.java:539) at javax.swing.UIManager.setLookAndFeel(UIManager.java:579) at javax.swing.UIManager.initializeDefaultLAF(UIManager.java:1349) at javax.swing.UIManager.initialize(UIManager.java:1459) at javax.swing.UIManager.maybeInitialize(UIManager.java:1426) at javax.swing.UIManager.getUI(UIManager.java:1006) at javax.swing.JOptionPane.updateUI(JOptionPane.java:1882) at javax.swing.JOptionPane.<init>(JOptionPane.java:1845) at javax.swing.JOptionPane.showOptionDialog(JOptionPane.java:857) at javax.swing.JOptionPane.showMessageDialog(JOptionPane.java:666) at javax.swing.JOptionPane.showMessageDialog(JOptionPane.java:637) at com.izforge.izpack.installer.GUIInstaller.showFatalError(Unknown Source) at com.izforge.izpack.installer.GUIInstaller.<init>(Unknown Source) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:423) at java.lang.Class.newInstance(Class.java:442) at com.izforge.izpack.installer.Installer.main(Unknown Source) Expected results: Install window appears with no errors or stack traces Additional info:
Hmm, this seems strange. The XToolkit class is there: $ rpm -qf /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.151-1.b12.fc27.x86_64/jre/lib/rt.jar java-1.8.0-openjdk-headless-1.8.0.151-1.b12.fc27.x86_64 $ jar tf /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.151-1.b12.fc27.x86_64/jre/lib/rt.jar | grep XToolkit sun/awt/X11/XToolkit$5.class sun/awt/X11/XToolkit$XEventListener.class sun/awt/X11/XToolkitThreadBlockedHandler.class sun/awt/X11/XToolkit$2.class sun/awt/X11/XToolkit$1.class sun/awt/X11/XToolkit$4.class sun/awt/X11/XToolkit$3.class sun/awt/UNIXToolkit.class sun/awt/X11/XToolkit.class Can you run simple swing apps like this? https://docs.oracle.com/javase/tutorial/uiswing/examples/start/HelloWorldSwingProject/src/start/HelloWorldSwing.java
Couldn't replicate this. Do you have java-1.8.0-openjdk installed, and not just java-1.8.0-openjdk-headless?
This message is a reminder that Fedora 27 is nearing its end of life. On 2018-Nov-30 Fedora will stop maintaining and issuing updates for Fedora 27. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '27'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 27 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
Fedora 27 changed to end-of-life (EOL) status on 2018-11-30. Fedora 27 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed.