[This topic is migrated from our old forums. The original author name has been removed]
I am getting a Java error when I try to connect to a DB in DbVis 9.1.8:
"java.lang.NoClassDefFoundError: org/jdom2/xpath/jaxen/JaxenCompiled"
How should I trouble shoot this error?
OS - Fedora 20 i386
DbVis worked in the past. This started before I upgraded to 9.1.8 from 9.0.9.
Things I have tried:
Upgrade to 9.1.8.
Remove DbVis and reinstall it using Fedora 20's rpm manager. I ran 'rpm -e dbvis-9.1.8-1.i386'. And then let the manager install a newly downloaded dbvis_linux_9_1_8.rpm.
Removing the /usr/share/java/jaxen.jar from the system Java. DbVis has the jaxen.jar in /opt/DbVisualizer/lib/jaxen.jar. I still get the same error. I have put jaxen.jar back.
I am not a natural at Java, but I can handle poking around with some direction. I had issues with Eclipse (specicaly JEE) that I have fixed; I may have inadvertently messed something up during that process.
I think all the pertinent system details are at the bottom of the error message, but I will provide more details if needed.
The error may have affected the application state. Please to vendor.
Long Message:
org/jdom2/xpath/jaxen/JaxenCompiled
Details:
Type: java.lang.NoClassDefFoundError
Stack Trace:
java.lang.NoClassDefFoundError: org/jdom2/xpath/jaxen/JaxenCompiled
at org.jdom2.xpath.jaxen.JaxenXPathFactory.compile(JaxenXPathFactory.java:82)
at org.jdom2.xpath.XPathFactory.compile(XPathFactory.java:297)
at com.onseven.dbvis.m.C.P.ā(Z:1651)
at com.onseven.dbvis.m.C.P.Ă(Z:1978)
at com.onseven.dbvis.m.C.P.ā(Z:1821)
at com.onseven.dbvis.m.C.P.ā(Z:1540)
at com.onseven.dbvis.m.C.P.Ă(Z:3389)
at com.onseven.dbvis._.A.Ă(Z:3131)
at com.onseven.dbvis.sql.L.Ĥ(Z:1494)
at com.onseven.dbvis.m.G.N.Ă(Z:3188)
at com.onseven.dbvis.m.G.N.ā(Z:3032)
at com.onseven.dbvis.m.H.A.Ą(Z:3145)
at com.onseven.dbvis.m.H.A.Ć(Z:3421)
at com.onseven.dbvis.m.B.J.ā(Z:2058)
at com.onseven.dbvis.m.F.C.ā(Z:3189)
at com.onseven.dbvis.m.A.F.ā(Z:1039)
at com.onseven.dbvis.m.A.F.Ą(Z:2324)
at com.onseven.dbvis.k.B.G.Ĉ(Z:2419)
at com.onseven.dbvis.k.A.F.Ă(Z:1022)
at com.onseven.dbvis.k.A.F.ā(Z:3212)
at com.onseven.dbvis.k.A.F.ā(Z:1186)
at com.onseven.dbvis.m.A.I.ā(Z:1973)
at com.onseven.dbvis.m.A.I.ā(Z:1629)
at com.onseven.dbvis.m.A.I.ā(Z:1064)
at com.onseven.dbvis.m.A.I$34.mousePressed(Z:2695)
at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:280)
at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:279)
at java.awt.Component.processMouseEvent(Component.java:6502)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3320)
at java.awt.Component.processEvent(Component.java:6270)
at java.awt.Container.processEvent(Container.java:2229)
at java.awt.Component.dispatchEventImpl(Component.java:4861)
at java.awt.Container.dispatchEventImpl(Container.java:2287)
at java.awt.Component.dispatchEvent(Component.java:4687)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4832)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4489)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4422)
at java.awt.Container.dispatchEventImpl(Container.java:2273)
at java.awt.Window.dispatchEventImpl(Window.java:2719)
at java.awt.Component.dispatchEvent(Component.java:4687)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:735)
at java.awt.EventQueue.access$200(EventQueue.java:103)
at java.awt.EventQueue$3.run(EventQueue.java:694)
at java.awt.EventQueue$3.run(EventQueue.java:692)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
at java.awt.EventQueue$4.run(EventQueue.java:708)
at java.awt.EventQueue$4.run(EventQueue.java:706)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:705)
at com.onseven.dbvis.N.A._.dispatchEvent(Z:2787)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
System Information:
Product: DbVisualizer Pro 9.1.8
Build: #2138 (2014/04/16 22:47)
Java VM: Java HotSpot(TM) Server VM
Java Version: 1.7.0_45
Java Vendor: Oracle Corporation
OS Name: Linux
OS Arch: i386
OS Version: 3.14.3-200.fc20.i686"
Additional system details:
Fedora 20
Edited by: eniad on May 16, 2014 5:57 PM
Hi,
Thanks for the detailed post.
Based on the trace it may be a conflicting jdom.jar (or similarly named) file in the system CLASSPATH, or that the /opt/DbVisualizer/lib/jdom.jar file is not available.
Please check this and let me know the progress.
Regards
Roger
a
anonymous
said
over 10 years ago
[This reply is migrated from our old forums. The original author name has been removed]
Re: Java error on DB connection (jaxen.jar)
Roger,
Thanks for the reply and help.
The problem persists.
This time around I tried:
# Moving jdom.jar out of the system CLASSPATH (/usr/share/java/)
# Moving both jdom.jar and jaxen.jar. out of the system CLASSPATH
# Moving them out of /opt/DbVisualizer/lib/ (after restoring the CLASSPATH copies)
Is this the proper (or at least reasonable) way to omit the .jar files from the paths?
The .jar files are loaded as needed, correct? There isn't some cache sitting somewhere that I need to clear, right?
There are minor differences in the error trace that seem to be related to how I got to the message ('Connect' button vs. right click menu 'Connect', etc). I will post it if requested.
I tried to investigate versions. Provided that I found the correct metadata, this is what i found.
* jdom.jar in the system CLASSPATH (/usr/share/java/) is ver. "1.1.2-snap".
* jdom.jar in /opt/DbVisualizer/lib/ is ver. "2.0.4".
* jaxen.jar in the system CLASSPATH (/usr/share/java/) is ver. "1.1.6".
* jaxen.jar in /opt/DbVisualizer/lib/ is ver. "1.1.4".
Should there be a jdom2.jar somewhere?
I fear I might not have the knowledge needed to track this down, but I hate to let a puzzle go unsolved.
Again, thanks for the help.
Daine
Roger Bjärevall
said
over 10 years ago
[This reply is migrated from our old forums.]
Re: Java error on DB connection (jaxen.jar)
Hi,
If you omit the jaxen.jar and jdom.jar from the system CLASSPATH and also make sure these files are not in /usr/share/java/ then you should be able to run DbVisualizer. Note that the original files provided with DbVisualizer in the lib directory must be present including jdom.jar and jaxen.jar.
Does it work with this setup?
Regards
Roger
a
anonymous
said
over 10 years ago
[This reply is migrated from our old forums. The original author name has been removed]
Re: Java error on DB connection (jaxen.jar)
Roger,
I have busy so I have not been working on this much of late. However, I am giving it another shot this afternoon.
The error is still occuring.
Questions first:
Is there a way to check which .jar files are being used? Are there other troubleshooting tool or techniques I should be using?
Actions tried:
I get no result from 'echo $CLASSPATH'. I have not changed the default settings, so I guess the default CLASSPATH is /usr/share/java/.
After removing the jaxen.jar and jdom.jar files from /user/share/java/. Running the following:
* find / -iname "*jaxen*jar"
* find / -iname "*jdom*jar"
show these .jar files are only in /opt/DbVisualizer/lib/ (with the exception of tomcat webapps directories, the back-ups I made in /home/user/, and Eclipse plug-ins).
I compared /usr/share/java/ and /opt/DbVisualizer/lib/ using
* diff -srq /opt/DbVisualizer/lib/ /usr/share/java/ | grep -i files
and found the following similarly named, but different files:
* Files /opt/DbVisualizer/lib/commons-lang.jar and /usr/share/java/commons-lang.jar differ
* Files /opt/DbVisualizer/lib/dom4j.jar and /usr/share/java/dom4j.jar differ
* Files /opt/DbVisualizer/lib/jsch.jar and /usr/share/java/jsch.jar differ
* Files /opt/DbVisualizer/lib/log4j.jar and /usr/share/java/log4j.jar differ
Removing these files from /usr/share/java/ one by one (or even all together) did not change the error behavior.
Additional behavior that may or may not help diagnosis:
After the error occurs and the error dialog is cleared, the 'reconnect' and 'disconnect' buttons are available as if it is connected. Clicking either leads to disconnecting hanging. The dialog says 'waiting for connection(s) to disconnect.." and the status bar scrolls back and forth. 'Force Disconnect' kills the dialog, but the Connection Message remains 'Disconnecting. Wait...' This is likely related to the initial error, and I suspect it will be fine once the initial problem is corrected.
I have been manipulating the databases from the command line, which works, but I really like the DbVis interface and features.
Once again, thanks for your help.
Daine
Edited by: eniad on Jun 11, 2014 9:48 PM
Roger Bjärevall
said
over 10 years ago
[This reply is migrated from our old forums.]
Re: Java error on DB connection (jaxen.jar)
Daine,
Sorry for the trouble you have.
A simple option is to enable verbose mode of Java. It will then list all classes being loaded and from which jar files or directories.
Open a terminal and navigate to the DbVisualizer 9.1.9 installation. Locate the dbvisgui.sh script and open it in a text editor. Modify the following:
$JAVA_EXEC -Xmx512M ...
and insert -verbose:
$JAVA_EXEC -verbose -Xmx512M ...
Save and run dbvisgui.sh
There will be a lot of output in the terminal. Try locate the actual classes that are reported being problematic and check what files these are loaded from. Does it give any clue what it happening?
Regards
Roger
a
anonymous
said
about 10 years ago
[This reply is migrated from our old forums. The original author name has been removed]
Re: Java error on DB connection (jaxen.jar)
Roger,
I have figured out the offending .jar files. The verbose output gave me the actual classes being called, as you suggested.
It turns out it was classes from another application in the /usr/java/jdk1.7.0_45/jre/lib/ext/ directory. I moved the .jar files, and viola! DbVisualizer now works.
I have been busy and this was not a high priority. Now that I have it fixed, though, checking something in the DB will be more plesant and quicker.
Thanks for all your help.
Daine
Roger Bjärevall
said
about 10 years ago
[This reply is migrated from our old forums.]
Re: Java error on DB connection (jaxen.jar)
Daine,
Thanks for the update and great to hear you managed to get it working properly.
Regards
Roger
anonymous
"java.lang.NoClassDefFoundError: org/jdom2/xpath/jaxen/JaxenCompiled"
How should I trouble shoot this error?
OS - Fedora 20 i386
DbVis worked in the past. This started before I upgraded to 9.1.8 from 9.0.9.
Things I have tried:
I think all the pertinent system details are at the bottom of the error message, but I will provide more details if needed.
Error message:
"An internal error occurred in:
java.lang.NoClassDefFoundError: org/jdom2/xpath/jaxen/JaxenCompiled
The error may have affected the application state. Please to vendor.
Long Message:
org/jdom2/xpath/jaxen/JaxenCompiled
Details:
Type: java.lang.NoClassDefFoundError
Stack Trace:
java.lang.NoClassDefFoundError: org/jdom2/xpath/jaxen/JaxenCompiled
at org.jdom2.xpath.jaxen.JaxenXPathFactory.compile(JaxenXPathFactory.java:82)
at org.jdom2.xpath.XPathFactory.compile(XPathFactory.java:297)
at com.onseven.dbvis.m.C.P.ā(Z:1651)
at com.onseven.dbvis.m.C.P.Ă(Z:1978)
at com.onseven.dbvis.m.C.P.ā(Z:1821)
at com.onseven.dbvis.m.C.P.ā(Z:1540)
at com.onseven.dbvis.m.C.P.Ă(Z:3389)
at com.onseven.dbvis._.A.Ă(Z:3131)
at com.onseven.dbvis.sql.L.Ĥ(Z:1494)
at com.onseven.dbvis.m.G.N.Ă(Z:3188)
at com.onseven.dbvis.m.G.N.ā(Z:3032)
at com.onseven.dbvis.m.H.A.Ą(Z:3145)
at com.onseven.dbvis.m.H.A.Ć(Z:3421)
at com.onseven.dbvis.m.B.J.ā(Z:2058)
at com.onseven.dbvis.m.F.C.ā(Z:3189)
at com.onseven.dbvis.m.A.F.ā(Z:1039)
at com.onseven.dbvis.m.A.F.Ą(Z:2324)
at com.onseven.dbvis.k.B.G.Ĉ(Z:2419)
at com.onseven.dbvis.k.A.F.Ă(Z:1022)
at com.onseven.dbvis.k.A.F.ā(Z:3212)
at com.onseven.dbvis.k.A.F.ā(Z:1186)
at com.onseven.dbvis.m.A.I.ā(Z:1973)
at com.onseven.dbvis.m.A.I.ā(Z:1629)
at com.onseven.dbvis.m.A.I.ā(Z:1064)
at com.onseven.dbvis.m.A.I$34.mousePressed(Z:2695)
at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:280)
at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:279)
at java.awt.Component.processMouseEvent(Component.java:6502)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3320)
at java.awt.Component.processEvent(Component.java:6270)
at java.awt.Container.processEvent(Container.java:2229)
at java.awt.Component.dispatchEventImpl(Component.java:4861)
at java.awt.Container.dispatchEventImpl(Container.java:2287)
at java.awt.Component.dispatchEvent(Component.java:4687)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4832)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4489)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4422)
at java.awt.Container.dispatchEventImpl(Container.java:2273)
at java.awt.Window.dispatchEventImpl(Window.java:2719)
at java.awt.Component.dispatchEvent(Component.java:4687)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:735)
at java.awt.EventQueue.access$200(EventQueue.java:103)
at java.awt.EventQueue$3.run(EventQueue.java:694)
at java.awt.EventQueue$3.run(EventQueue.java:692)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
at java.awt.EventQueue$4.run(EventQueue.java:708)
at java.awt.EventQueue$4.run(EventQueue.java:706)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:705)
at com.onseven.dbvis.N.A._.dispatchEvent(Z:2787)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
System Information:
Product: DbVisualizer Pro 9.1.8
Build: #2138 (2014/04/16 22:47)
Java VM: Java HotSpot(TM) Server VM
Java Version: 1.7.0_45
Java Vendor: Oracle Corporation
OS Name: Linux
OS Arch: i386
OS Version: 3.14.3-200.fc20.i686"
Additional system details:
Fedora 20 Edited by: eniad on May 16, 2014 5:57 PM