Red Hat Directory Server 9 Exception in thread main No fonts found

• Updated January 21, 2019


If you have just installed Red Hat Directory Server 9 on RHEL 6 with only the @Base package group, the java-1.6.0-openjdk package, and the redhat-ds package, and you are trying to open the Red Hat Identity Management Console through a forwarded SSH X session by running redhat-idm-console -a http://localhost:9830, you may encounter a Java stack trace.

The Java stack trace encountered will look similar to the following:

Exception in thread "main" java.lang.Error: Probable fatal error:No fonts found.
    at sun.font.FontManager.getDefaultPhysicalFont(FontManager.java:1087)
    at sun.font.FontManager.initialiseDeferredFont(FontManager.java:959)
    at sun.font.FontManager.findOtherDeferredFont(FontManager.java:898)
    at sun.font.FontManager.findDeferredFont(FontManager.java:915)
    at sun.font.FontManager.findFont2D(FontManager.java:1912)
    <truncated>
    at sun.font.FontManager.findFont2D(FontManager.java:1873)
    at sun.font.FontManager.getDefaultPhysicalFont(FontManager.java:1070)
    at sun.font.FontManager.initialiseDeferredFont(FontManager.java:966)
    at sun.font.CompositeFont.doDeferredInitialisation(CompositeFont.java:254)
    at sun.font.CompositeFont.getSlotFont(CompositeFont.java:334)
    at sun.font.CompositeStrike.getStrikeForSlot(CompositeStrike.java:77)
    at sun.font.CompositeStrike.getFontMetrics(CompositeStrike.java:93)
    at sun.font.FontDesignMetrics.initMatrixAndMetrics(FontDesignMetrics.java:358)
    at sun.font.FontDesignMetrics.<init>(FontDesignMetrics.java:349)
    at sun.font.FontDesignMetrics.getMetrics(FontDesignMetrics.java:301)
    at sun.swing.SwingUtilities2.getFontMetrics(SwingUtilities2.java:947)
    at javax.swing.JComponent.getFontMetrics(JComponent.java:1600)
    at javax.swing.plaf.basic.BasicLabelUI.getPreferredSize(BasicLabelUI.java:228)
    at javax.swing.JComponent.getPreferredSize(JComponent.java:1635)
    at javax.swing.plaf.basic.BasicListUI.updateLayoutState(BasicListUI.java:1362)
    at javax.swing.plaf.basic.BasicListUI.maybeUpdateLayoutState(BasicListUI.java:1310)
    at javax.swing.plaf.basic.BasicListUI$Handler.valueChanged(BasicListUI.java:2619)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:184)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:164)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:211)
    at javax.swing.DefaultListSelectionModel.changeSelection(DefaultListSelectionModel.java:405)
    at javax.swing.DefaultListSelectionModel.changeSelection(DefaultListSelectionModel.java:415)
    at javax.swing.DefaultListSelectionModel.setSelectionInterval(DefaultListSelectionModel.java:459)
    at javax.swing.JList.setSelectedIndex(JList.java:2196)
    at javax.swing.plaf.basic.BasicComboPopup.setListSelection(BasicComboPopup.java:1144)
    at javax.swing.plaf.basic.BasicComboPopup.access$300(BasicComboPopup.java:63)
    at javax.swing.plaf.basic.BasicComboPopup$Handler.itemStateChanged(BasicComboPopup.java:982)
    at javax.swing.JComboBox.fireItemStateChanged(JComboBox.java:1222)
    at javax.swing.JComboBox.selectedItemChanged(JComboBox.java:1279)
    at javax.swing.JComboBox.contentsChanged(JComboBox.java:1326)
    at javax.swing.AbstractListModel.fireContentsChanged(AbstractListModel.java:117)
    at javax.swing.plaf.metal.MetalFileChooserUI$FilterComboBoxModel.propertyChange(MetalFileChooserUI.java:1099)
    at java.beans.PropertyChangeSupport.fire(PropertyChangeSupport.java:298)
    at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:291)
    at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:229)
    at java.awt.Component.firePropertyChange(Component.java:8269)
    at javax.swing.JFileChooser.setFileFilter(JFileChooser.java:1432)
    at javax.swing.JFileChooser.addChoosableFileFilter(JFileChooser.java:1127)
    at javax.swing.JFileChooser.updateUI(JFileChooser.java:1785)
    at javax.swing.JFileChooser.setup(JFileChooser.java:374)
    at javax.swing.JFileChooser.<init>(JFileChooser.java:347)
    at javax.swing.JFileChooser.<init>(JFileChooser.java:300)
    at com.netscape.management.client.console.Console.common_init(Unknown Source)
    at com.netscape.management.client.console.Console.<init>(Unknown Source)
    at com.netscape.management.client.console.Console.main(Unknown Source)

To fix this, install yum package liberation-sans-fonts, or an equivalent font package, and reconnect to the Red Hat Identity Management Console through the forwarded SSH X session.

If you found this post useful, you can help support this site and get something for yourself by signing up for any of the services listed below through the provided links.

The following links are part of affiliate programs, and I will receive a referral payment from any of the services you sign-up for.

  • Get Faster Shipping: Perhaps you're about to order some stuff on Amazon but want to get more value out of the money you would normally pay for shipping. Sign-up for a free, 30-day trial of Amazon Prime to get free two-day shipping, access to thousands of movies and TV shows, and more.
  • Start Investing Now: Are you looking to start investing some of your disposable saved income? Get started by opening an account with Webull, where upon sign-up and opening a brokerage account with an initial deposit of at least $100 you will receive 1 stock valued (subject to change based on normal market movement) between $8 and $1600.

Thanks for reading and take care.