Fedora installation and configuration Java

Source: Internet
Author: User
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

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.