Fedora installation and configuration Java1.yum installation java Runtime Environment yuminstalljava2. test whether jre (javaruntimeenvironment for java running) is installed successfully. Enter the command: java3.yum search jdk (JavaDevelopmentKit for java Development. (Skip this step.) yumsearchjdk4.yum install jdkyum
Fedora installation and configuration Java
1. install java Runtime Environment in yum
Yum install java
2. Test whether jre (java runtime environment for java running) is installed successfully. Enter the following command:
Java
3. yum search jdk (Java Development Kit for java Development) version. (Skip this step)
Yum search jdk
4. Install jdk in yum
Yum install java * jdk * devel * (pattern matching) or:
Yum install java-1.6.0-openjdk-devel.i686
5. Run the following command to test whether jdk is successfully installed:
Javac
------- End ----------
You do not need to set environment variables for java installed in this way.
To view the java installation directory, run the whereis command:
Whereis java
To view the directory of the java executable file, run the which command:
Which java
In fact, you can directly download java from the sun website and install it manually, but you need to modify the environment variables.
Add a java. sh file under the/etc/profile. d/folder or modify the/etc/profile file. Both methods add the java classpath and path to the file,
Enter the command: source/etc/profile to make the configuration take effect.
For more information about Fedora, see Fedora topics page http://www.linuxidc.com/topicnews.aspx? Tid = 5