Freeze on Linux using proprietary Nvidia drivers

Hello,

I cannot get Icy to run on any Linux (Ubuntu 18.04, Ubuntu 20.04) machine that uses the proprietary Nvidia drivers. On starting Icy, the window shows, but freezes completely. The only option left is to kill the process. I tried running the software from the terminal via java -jar icy.jar, but there was no interesting output. I tried running Icy on Ubuntu 20.04 machines that have an Intel graphics device and it worked flawlessly.

The freeze happens after the UI opens and before those introduction popups and the updater status appear.

I could partially work around the issue by taking an Icy instance from a working computer and copying it to a computer where the issue occurs. There the freeze did not happen - only on exiting the application. The introduction popups still appear (for some reason I cannot permanently disable them even after selecting the “Disable” checkbox), but the updater did not appear. So I hypothesize that it could have something to do with the updater. Yet, I cannot explain the freeze on closing Icy (that also sometimes happen on the Intel graphics machines).

Thank you!

Hi Ruman,

Did you tried to update your java version ? I remember that i once experienced the problem using a specific OpenJDK version, then updating it or changing to Oracle Java fixed the problem.
What is weird is that you can somehow fix the issue by copying an Icy from a working instance, honestly that shouldn’t change much the result but it looks like it does for some reason (server registering ?).

Best,

– Stephane

1 Like

Thank you for this suggestion!
I tried it with OpenJDK 11 (default was OpenJDK 8) and it worked immediately.

I have already tried developing Java applications on Linux and experienced some hangs with Java 8 where Swing locked at some internal function. I do not know how those notifications and the updater popup are implemented - but maybe something similar happens. When I tried it with Java 8 I really could see that the freeze occurred when the notifications were supposed to appear.

With Java 11 exiting the application works. If I switched back to Java 8, it loaded fine as mentioned before, but it froze again on exiting. I checked why it locked up and it locked at readLock() in AbstractDocument (seems to be related to https://bugs.openjdk.java.net/browse/JDK-8187267). I also deadlocks in the same function if I run a fresh copy of Icy. The freeze seems to be caused by Icy’s Look & Feel (Pushing-pixels substance):

readLock:1381, AbstractDocument (javax.swing.text) <--- Freezes here
getPreferredSize:908, BasicTextUI (javax.swing.plaf.basic)
getPreferredSize:1662, JComponent (javax.swing)
getPreferredSize:1333, JEditorPane (javax.swing)
preferredLayoutSize:719, BorderLayout (java.awt)
preferredSize:1799, Container (java.awt)
getPreferredSize:1783, Container (java.awt)
getPreferredSize:1664, JComponent (javax.swing)
layoutContainer:791, ScrollPaneLayout (javax.swing)
layoutContainer:470, SubstanceScrollPaneUI$AdjustedLayout (org.pushingpixels.substance.internal.ui)
layout:1513, Container (java.awt)
doLayout:1502, Container (java.awt)
validateTree:1698, Container (java.awt)
validateTree:1707, Container (java.awt)
validateTree:1707, Container (java.awt)
validate:1633, Container (java.awt)
ensureCurrentLayout:1660, SubstanceTabbedPaneUI (org.pushingpixels.substance.internal.ui)
run:1634, SubstanceTabbedPaneUI$TabRepaintCallback$1 (org.pushingpixels.substance.internal.ui)
dispatch$$$capture:311, InvocationEvent (java.awt.event)
dispatch:-1, InvocationEvent (java.awt.event)
dispatchEventImpl:758, EventQueue (java.awt)
access$500:97, EventQueue (java.awt)
run:709, EventQueue$3 (java.awt)
run:703, EventQueue$3 (java.awt)
doPrivileged:-1, AccessController (java.security)
doIntersectionPrivilege:74, ProtectionDomain$JavaSecurityAccessImpl (java.security)
dispatchEvent:728, EventQueue (java.awt)
dispatchEvent:705, AtkWrapper$6 (org.GNOME.Accessibility)
pumpOneEventForFilters:205, EventDispatchThread (java.awt)
pumpEventsForFilter:116, EventDispatchThread (java.awt)
pumpEventsForHierarchy:105, EventDispatchThread (java.awt)
pumpEvents:101, EventDispatchThread (java.awt)
pumpEvents:93, EventDispatchThread (java.awt)
run:82, EventDispatchThread (java.awt)
2 Likes

Thanks for the detailed reply. I guess this in indeed a bug with some version of OpenJDK8. Substance LAF use resources to read some properties and for some reasons it may end to a deadlock from time to time with JDK8.
Anyway what matter is that it seems they fixed the bug with newer Java thankfully :slight_smile: