Linux system environment variables

Set global environment variables

/etc/profile

Initialized for login user shell only, any Bourne shell compatible can be used

/etc/bash.bashrc

Initialized only for interactive shells, bash supports

/etc/environment

Global environment variables, whether logged in or not, can be used, but the content can only be: key=value format, cannot be exported, cannot use variables, but pay attention to the startup sequence, maybe your program is executed before this, still cannot Get the variable set here

 

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=327069095&siteId=291194637