首頁  >  文章  >  運維  >  關於CentOS的/etc/profile和~/.bash_profile及.zshrc - ma_fighting

關於CentOS的/etc/profile和~/.bash_profile及.zshrc - ma_fighting

藏色散人
藏色散人轉載
2020-08-13 11:48:192149瀏覽

下面由centos使用教學專欄來介紹CentOS的/etc/profile和~/.bash_profile及.zshrc - ma_fighting,希望對需要的朋友有幫助!

關於CentOS的/etc/profile和~/.bash_profile及.zshrc - ma_fighting

互動式登陸shell

#對於互動式的登陸shell而言,CentOS規定了startup檔案的載入順序如下:

登陸過程:
1. 讀取並執行/etc/profile檔案;
2. 讀取並執行~/.bash_profile 檔;
- 若檔案不存在,則讀取並執行~/.bash_login檔案;
- 若檔案不存在,則讀取取並執行~/.profile檔;

登出程序:
1. 讀取並執行~/.bash_logout檔;
2 .讀取並執行/etc/bash.bash_logout檔;

.zshrc   source後只會在目前視窗生效

更多centos技術文章,請造訪centos入門教學專欄!

以上是關於CentOS的/etc/profile和~/.bash_profile及.zshrc - ma_fighting的詳細內容。更多資訊請關注PHP中文網其他相關文章!

陳述:
本文轉載於:cnblogs.com。如有侵權,請聯絡admin@php.cn刪除