The Java path of Fedora13 is usually/usr/bin/java and is the GNU Java version, which is not suitable for many software. It is best to install Sun's Java, JRE, or JDK separately, and then specify the Java execution path in the system environment. If the rpm. the binfile is placed under/usr/java/and executed. /***. bin, and then the jdk1.6.0 _ 20 or jre-*** is automatically created in the current path.
The Java path of Fedora 13 is usually/usr/bin/java, and it is the GNU Java version, which is not suitable for many software.
It is best to install Sun's Java, JRE, or JDK separately, and then specify the Java execution path in the system environment.
If the rpm. the binfile is placed under/usr/java/and executed. /***. bin. Then, a folder such as JDK 1.6.0 _ 20 or jre-*** is automatically created in the current path. This is the installation path of Java.
Then set the system environment variables. The best way is to modify ". bash_profile file, which can be used to automatically set the Java path and restrict user permissions when a user logs on. In some Linux versions, the. bashrc file is modified, but it is invalid in Fedora.
Add the following lines to the end of the ". bash_profile" file:
JAVA_HOME =/usr/java/jdk1.6.0 _ 20
Export JAVA_HOME
PATH = $ JAVA_HOME/bin: $ PATH
Export PATH
CLASSPATH =.: $ JAVA_HOME/lib/dt. jar: $ JAVA_HOME/lib/tools. jar
Export CLASSPATH
Then source ~ /. Bash_profile or log on again.
To declare the Java path for all users, add the preceding command line to the/etc/profile file, and then log on to source/etc/profile or log on again.
If you only want to use it temporarily, you only need to execute the following command in shell:
Export JAVA_HOME =/usr/java/jdk1.6.0 _ 20
Export PATH = $ JAVA_HOME/bin: $ PATH
Export CLASSPATH =.: $ JAVA_HOME/lib/dt. jar: $ JAVA_HOME/lib/tools. jar
In some Fedora versions, the Java path of Firefox also needs to be specified separately by adding a link to the Java Dynamic Link Library in the Firefox plug-in library directory. If the Firefox plug-in library path is: "/usr/lib/firefox-2.0.0.14/plugins/", create a link under it to point to the Java libjavaplugin_oji.so file, the command is:
Ln-s/usr/java/jdk1.6.0 _ 20/jre/plugin/i386/ns7/libjavaplugin_oji.so./libjavaplugin_oji.so
This setting is complete.