Setting environment variables under Linux

Source: Internet
Author: User

SETENV (Set environment variable)

function Description: query or display environment variables.

syntax:setenv [variable name] [variable value]

Supplemental Instructions:setenv The instructions for querying or setting environment variables in Tsch.

For bash shells
About the environment variable command description:
1.echo displays an environment variable value echo $PATH
2.export setting a new environment variable export hello= "HELLO" (can be without quotation marks)
3.ENV Show All environment variables
4.set show locally defined shell variables
5.unset Clear environment variable unset HELLO
6.readonly set read-only environment variable readonly HELLO

Common environment variables
PATH: Determines to which directories the shell will look for commands or programs
Home: Current User home Directory
Mail: Refers to the current user's message store directory.
Shell: Refers to what kind of shell is used by the current user.
Histsize: Refers to the number of records in which history commands are saved
LOGNAME: Refers to the login name of the current user.
HOSTNAME: Refers to the name of the host, and many applications are usually obtained from this environment variable if they want to use the host name.
Lang/languge: is a language-related environment variable that users of multiple languages can modify.

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.