When Linux modifies profile file, all commands are not __linux.

Source: Internet
Author: User

A. Linux modification profile file changed the wrong way, restore the method in the change, the problem, in addition to the CD other than the basic command can not be used,
Even VI can not use, the Internet check the next, with export path=/usr/bin:/usr/sbin:/bin:/sbin:/usr/x11r6/bin, and then you can use the command, Speed with VI to change the profile back, return to normal. shell commands are basically defined in/usr/bin,/usr/sbin,/bin,/sbin,/usr/x11r6/bin. so as long as the orders are taken back, they can be used, and they are a remedy.
Two. Ways to configure the Java environment

1. Modify the/etc/profile file (System effective)


(1) #root > Vi/etc/profile


(2) Use the VI Editor to add the following statement to the profile file:


java_home=/opt/jdk1.5
Path=$java_home/bin:$path
Classpath=.$java_home/lib/dt.jar:java_home/lib/tools.jar

Export Java_home,path,classpath


(3) Re-login


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.