Linux - SoftwareThis 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
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Am having abit of a problem executin a client sided of a Cafe software:
when i run the server side of the software using ./Cafepilot_Server.jar, it executes perfectly.
now when i try to do the same for the client side i get the following error:
Code:
invalid file (bad magic number): Exec format error
So i figured out i could use java -jar Cafepilot_client.jar, but that annoingly throws up the following errors:
Code:
Exception in thread "main" java.lang.NoClassDefFoundError: sun.misc.BASE64Decoder
at com.dijitanix.cafepilot.cafepilotclient.gb.b(gb.java)
at com.dijitanix.cafepilot.cafepilotclient.Main.main(Main.java)
I also try java cafepilot_Client.jar and i get even more errors:
Code:
Exception in thread "main" java.lang.NoClassDefFoundError: CafePilot_Client.jar
at gnu.java.lang.MainThread.run(libgcj.so.8rh)
Caused by: java.lang.ClassNotFoundException: CafePilot_Client.jar not found in gnu.gcj.runtime.SystemClassLoader{urls=[file:./], parent=gnu.gcj.runtime.ExtensionClassLoader{urls=[], parent=null}}
at java.net.URLClassLoader.findClass(libgcj.so.8rh)
at gnu.gcj.runtime.SystemClassLoader.findClass(libgcj.so.8rh)
at java.lang.ClassLoader.loadClass(libgcj.so.8rh)
at java.lang.ClassLoader.loadClass(libgcj.so.8rh)
at gnu.java.lang.MainThread.run(libgcj.so.8rh)
If you want to install the sun jdk on Fedora without too many issues, you should use jpackage.org to install the java-compat package, then install the jdk. There are some conflicts between Fedora and jpackage, though, so you need to be careful if you use if for other java packages too. Having the compat package makes running alternatives a lot more straightforward. It essentially creates all the links that a pre-installed environment like gcj already has.
You can also install galternatives, which is an alternatives GUI. Again more straightforward, you just need to check the proper items.
As for the path, that could mean various things. First of all, you need to make sure that you are in the right directory before you execute java -jar. It is also possible that the jar file needs to be appended to your classpath in /etc/profile or your .bash_profile, something like this:
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
Advertisement
Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Click Here to receive a complimentary subscription courtesy of LQ.