JAVA_HOME settings, JAVA_HOME settings

Source: Internet
Author: User

JAVA_HOME settings, JAVA_HOME settings

1. Permanent modification, effective for all users (this is not recommended for Oracle and other users)

# vi /etc/profile

Export JAVA_HOME =/usr/local/jdk1.8.0 _ 20/
Export PATH = $ JAVA_HOME/bin: $ PATH
Export CLASSPATH =.: $ JAVA_HOME/lib/dt. jar: $ JAVA_HOME/lib/tools. jar

 

[Note]: If you want to change the file to take effect immediately, run # source/etc/profile

 

2. Permanent modification, valid for a single user

$ Vi/home/myuser/. bash_profile // Add the following content at the end of the file

Export JAVA_HOME =/usr/local/jdk1.8.0 _ 20/
Export PATH = $ JAVA_HOME/bin: $ PATH
Export CLASSPATH =.: $ JAVA_HOME/lib/dt. jar: $ JAVA_HOME/lib/tools. jar

 

[Note]: If you want to change the file to take effect immediately, run # source/home/myuser/. bash_profile

 

3. Only effective for the current bash/shell

Export JAVA_HOME =/usr/local/jdk1.8.0 _ 20/
Export PATH = $ JAVA_HOME/bin: $ PATH
Export CLASSPATH =.: $ JAVA_HOME/lib/dt. jar: $ JAVA_HOME/lib/tools. jar


Java_home settings

Khan ~~ This is a classic problem.

I'm afraid many people do not know that TOMCAT has a small detail on HOME settings.

In an environment variable, the variable value cannot be followed by ";", that is, the variable value cannot be a plus sign. You can try again.

In addition, I also use TOMCAT for WEB. I hope this answer will help you.

What version of TOMCAT are you using?

Java_home settings

Khan ~~ This is a classic problem.

I'm afraid many people do not know that TOMCAT has a small detail on HOME settings.

In an environment variable, the variable value cannot be followed by ";", that is, the variable value cannot be a plus sign. You can try again.

In addition, I also use TOMCAT for WEB. I hope this answer will help you.

What version of TOMCAT are you using?

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.