LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 04-06-2009, 01:19 PM   #1
jjonas
Member
 
Registered: Jul 2005
Location: Finland
Distribution: Arch Linux
Posts: 80

Rep: Reputation: 15
Java problem with MagicAssistant


Hello,

I downloaded MagicAssistant to manage my Magic: The Gathering card collection.
http://linux.softpedia.com/get/Utili...nt-41546.shtml

Unpacking the zip file seemed to reveal a ready to run program, so i typed ./magicassistant. I got the following message, but don't know what the problem is and how I might fix it. Any suggestions? (I'm naturally happy to provide any additional information if needed.)

Exception in thread "main" Exception while printStackTrace(): java.lang.NoClassDefFoundError: java/lang/System
at java.lang.VMThrowable.fillInStackTrace(Ljava/lang/Throwable;)Ljava/lang/VMThrowable;(Native Method)
at java.lang.Throwable.fillInStackTrace()Ljava/lang/Throwable;(Throwable.java:498)
at java.lang.Throwable.<init>(Ljava/lang/String;)V(Throwable.java:159)
at java.lang.Error.<init>(Ljava/lang/String;)V(Error.java:81)
at java.lang.LinkageError.<init>(Ljava/lang/String;)V(LinkageError.java:72)
at java.lang.NoClassDefFoundError.<init>(Ljava/lang/String;)V(NoClassDefFoundError.java:74)
at java.lang.Throwable.printStackTrace()V(Throwable.java:352)
Original exception was: java.lang.UnsatisfiedLinkError: getClassLoader
at java.lang.VMThrowable.fillInStackTrace(Ljava/lang/Throwable;)Ljava/lang/VMThrowable;(Native Method)
at java.lang.Throwable.fillInStackTrace()Ljava/lang/Throwable;(Throwable.java:498)
at java.lang.Throwable.<init>(Ljava/lang/String;)V(Throwable.java:159)
at java.lang.Error.<init>(Ljava/lang/String;)V(Error.java:81)
at java.lang.LinkageError.<init>(Ljava/lang/String;)V(LinkageError.java:72)
at java.lang.UnsatisfiedLinkError.<init>(Ljava/lang/String;)V(UnsatisfiedLinkError.java:72)
at gnu.classpath.VMStackWalker.getClassLoader(Ljava/lang/Class;)Ljava/lang/ClassLoader;(Native Method)
at gnu.classpath.VMStackWalker.getCallingClassLoader()Ljava/lang/ClassLoader;(VMStackWalker.java:105)
at java.lang.System.loadLibrary(Ljava/lang/String;)V(System.java:663)
at gnu.java.nio.FileChannelImpl.<clinit>()V(FileChannelImpl.java:87)
at java.io.FileDescriptor.<clinit>()V(FileDescriptor.java:64)
at java.lang.VMSystem.makeStandardInputStream()Ljava/io/InputStream;(VMSystem.java:186)
at java.lang.System.<clinit>()V(System.java:85)
at java.io.File.checkRead()V(File.java:1482)
at java.io.File.isDirectory()Z(File.java:673)
at java.lang.VMClassLoader.getResources(Ljava/lang/String;)Ljava/util/Enumeration;(VMClassLoader.java:190)
at java.lang.VMClassLoader.getResource(Ljava/lang/String;)Ljava/net/URL;(VMClassLoader.java:170)
at java.lang.VMClassLoader.getBootPackages()[Ljava/lang/String;(VMClassLoader.java:252)
at java.lang.VMClassLoader.<clinit>()V(VMClassLoader.java:89)
at java.lang.ClassLoader$StaticData.<clinit>()V(ClassLoader.java:154)
at java.lang.ClassLoader.getSystemClassLoader()Ljava/lang/ClassLoader;(ClassLoader.java:799)
 
Old 04-07-2009, 03:02 AM   #2
rylan76
Senior Member
 
Registered: Apr 2004
Location: Potchefstroom, South Africa
Distribution: Fedora 17 - 3.3.4-5.fc17.x86_64
Posts: 1,552

Rep: Reputation: 103Reputation: 103
Hmm I once had a similar problem with Java with a java application I wrote myself.

After a long travail, it turned out that I was running the "wrong" java...! It also gave the same types of exceptions you list here.

Anyway, it was on FC6, and it turned out there were TWO

java

executables on the system. One was in /usr/local/bin (if I remember right) and the other was an actual, official SUN Microsystems 1.5.0_09 Java Runtime in my home directory.

The one I had in /usr/local/bin was some opensource implementation I got from somewhere, that turned out to not be compatible with newer .JARs compiled with the 1.5.0_09 Java SDK. The problem was my path - according to the path I was using, the Java runtime that popped up first was the one in /usr/local/bin - while the .JAR I had was a 1.5.0_09 compiled jar.

I. e. I was running the wrong executable.

To solve this I changed into the folder where the .JAR was I wanted to run, and then did

Code:
/home/rylan/jre1.5.0_09/bin/java ./myjar.jar
to ENSURE that the "correct" Java runtime executable was used.

Since you seem to be running a bash script to get your application started, open the script and check how the "java" executable is found. Ensure that this is running a correctly installed, current Java VM.
 
Old 04-07-2009, 07:38 AM   #3
jjonas
Member
 
Registered: Jul 2005
Location: Finland
Distribution: Arch Linux
Posts: 80

Original Poster
Rep: Reputation: 15
Thumbs up

Hi,

based on your reply I managed to solve my problem by merely updating to the newest version of Java. Thanks!
 
Old 04-08-2009, 01:52 AM   #4
rylan76
Senior Member
 
Registered: Apr 2004
Location: Potchefstroom, South Africa
Distribution: Fedora 17 - 3.3.4-5.fc17.x86_64
Posts: 1,552

Rep: Reputation: 103Reputation: 103
No problem! Glad you got it fixed.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Java Problem keyboard1973 Linux - Newbie 5 07-09-2008 03:13 AM
and yet another java problem why_linux Linux - Software 3 01-27-2007 10:54 AM
java problem? MilkyBar_Kid Slackware 12 07-22-2004 05:31 PM
my java problem rb3ng Programming 12 03-12-2004 01:04 PM
Java problem CragStar Programming 11 03-11-2004 10:02 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:35 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration