LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   java not working in fedora-9 (https://www.linuxquestions.org/questions/linux-software-2/java-not-working-in-fedora-9-a-678998/)

vicky7038 10-25-2008 10:38 AM

java not working in fedora-9
 
hi friends i m using fedora-9.i have installed jdk1.5 in it ans set up path variable in /etc/profile.bt the problm is that when i tried to run my swing program in it it gives error like libXxT.so is not found bt i havnt delete any file in jdk directory since i hav installed it.
bt command javac is working and program compiles successfully.

Another problem is that i hav used apache tomcat for my servlet programs but when i start the tomcat server from bin directory of tomcat with startup.sh command then it gives error like ./catalina.sh not found.bt it is there in te bin directory of tomcat and i hav set up environment variable CATALINA_HOME and JAVA_HOME and CLASSPATH in /etc/proofile thn still it gives error.

wht can i do to solve this errors???

First let me know that i hav to start my feodora by passing kernel parameters as "noapic" otherwise it gives Bios bug:and says timer not connectd to IOAPIC

plz help me to solve these problem.

Mega Man X 10-25-2008 11:09 AM

Quote:

Originally Posted by vicky7038 (Post 3321716)
hi friends i m using fedora-9.i have installed jdk1.5 in it ans set up path variable in /etc/profile.bt the problm is that when i tried to run my swing program in it it gives error like libXxT.so is not found bt i havnt delete any file in jdk directory since i hav installed it.
bt command javac is working and program compiles successfully.

Another problem is that i hav used apache tomcat for my servlet programs but when i start the tomcat server from bin directory of tomcat with startup.sh command then it gives error like ./catalina.sh not found.bt it is there in te bin directory of tomcat and i hav set up environment variable CATALINA_HOME and JAVA_HOME and CLASSPATH in /etc/proofile thn still it gives error.

wht can i do to solve this errors???

First let me know that i hav to start my feodora by passing kernel parameters as "noapic" otherwise it gives Bios bug:and says timer not connectd to IOAPIC

plz help me to solve these problem.

What is the output of:

java -version

You might want to copy and paste error messages from now on. Saying you get some "error like x" is not really helpful.

-X

vicky7038 10-25-2008 12:09 PM

Quote:

Originally Posted by Mega Man X (Post 3321733)
What is the output of:

java -version

You might want to copy and paste error messages from now on. Saying you get some "error like x" is not really helpful.

-X

it works
and gives java vestion 1.5.0.
thts message bt gives error while running nt even at compiling time
javac works proper
bt whn using java specially for swing prog it gives error

Mega Man X 10-25-2008 05:26 PM

Quote:

Originally Posted by vicky7038 (Post 3321766)
it works
and gives java vestion 1.5.0.
thts message bt gives error while running nt even at compiling time
javac works proper
bt whn using java specially for swing prog it gives error

I know the command works, but you are still not copying and pasting the results. This is a copy and paste of my java -version command:

java version "1.6.0_10"
Java(TM) SE Runtime Environment (build 1.6.0_10-b33)
Java HotSpot(TM) Client VM (build 11.0-b15, mixed mode, sharing)


Copy and paste everything here, including error messages. If you can also post your code, would also be helpful.

I am asking this because the problem could be in one or several different places, like:

- You are using a different compiler or JRE other than Sun's Java (eg: gcj)
- There is an error with your code;
- You are using a newer compiler and trying to run with an older Java RE.

Usually, when you can compile a program fine but can't run a Swing application, it means that you are using gcj. If you had copied and pasted the results of java -version we would've known.

Again, copy and paste everything. There is no such a thing as too much information. If you just say that "it gives an error", we cannot help you.

vicky7038 10-26-2008 02:10 AM

in java -version command it gives like this:

java version "1.5.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64)
Java HotSpot(TM) Client VM (build 1.5.0-b64, mixed mode, sharing)

and when i run my swing program it gives error msg like this:
>java ftpClient
Exception in thread "main" java.lang.UnsatisfiedLinkError: /usr/java/jdk1.5.0/jre/lib/i386/xawt/libmawt.so: libXext.so.6: cannot open shared object file: No such file or directory
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1751)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1647)
at java.lang.Runtime.load0(Runtime.java:769)
at java.lang.System.load(System.java:967)
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1751)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1668)
at java.lang.Runtime.loadLibrary0(Runtime.java:822)
at java.lang.System.loadLibrary(System.java:992)
at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:50)
at java.security.AccessController.doPrivileged(Native Method)
at sun.awt.NativeLibLoader.loadLibraries(NativeLibLoader.java:38)
at sun.awt.DebugHelper.<clinit>(DebugHelper.java:29)
at java.awt.Component.<clinit>(Component.java:545)


I hav dual boot system and this program run perfectly under windows environment bt in fedora-9 it gives error.

and for tomcat it gives error like this:

[root@localhost bin]# sh startup.sh
Cannot find ./catalina.sh
This file is needed to run this program

bt the file catalina.sh is there in the bin directory of tomcat.
wht i can do now to solve this?
plz help me

axelfc 10-26-2008 03:48 AM

Quote:

Originally Posted by vicky7038 (Post 3322109)
and when i run my swing program it gives error msg like this:
>java ftpClient
Exception in thread "main" java.lang.UnsatisfiedLinkError: /usr/java/jdk1.5.0/jre/lib/i386/xawt/libmawt.so: libXext.so.6: cannot open shared object file: No such file or directory

It seems you don't have libXext installed. Install it by typing:

su -c 'yum install libXext'

and tell us if this solved your problem.

vicky7038 10-27-2008 07:24 AM

i have also tried that command and it gives message like this:

yum install libXext
Loaded plugins: refresh-packagekit
Existing lock /var/run/yum.pid: another copy is running as pid 2581.
Another app is currently holding the yum lock; waiting for it to exit...
Another app is currently holding the yum lock; waiting for it to exit...
Another app is currently holding the yum lock; waiting for it to exit...
Another app is currently holding the yum lock; waiting for it to exit...
Another app is currently holding the yum lock; waiting for it to exit...
Setting up Install Process
Parsing package install arguments
Package libXext-1.0.4-1.fc9.x86_64 already installed and latest version
Nothing to do


All times are GMT -5. The time now is 03:30 AM.