/etc/profile

其实看名字就能了解大概了, profile 是某个用户唯一的用来设置环境变量的地方, 因为用户可以有多个 shell 比如 bash, sh, zsh 之类的, 但像环境变量这种其实只需要在统一的一个地方初始化就可以了, 而这就是 profile.

/etc/profile
这个文件是每个用户登录时都会运行的环境变量设置

原文地址:https://www.cnblogs.com/sysnap/p/7985873.html