编辑/etc/profile文件 在文件末尾添加两行代码
vi /etc/profile
 
CentOS:
    PATH=$PATH:/opt/lampp/bin
    export PATH
Ubuntu:
    export PATH=/opt/lampp/bin:$PATH
 
执行/etc/profile
source /etc/profile

  

相关文章: