→ hijkxyzuw: profile 裡好像不能用變數代換,像 PATH=$PATH:/sbin 09/05 13:36
→ storyofwind: 請問一下那要怎麼修改呢,我現在都是用上述的方式 09/05 15:19
→ storyofwind: 加在profile最後面 09/05 15:20
推 Bencrie: 各家做法可能不太一樣吧。/etc/profile 可以放 PATH 09/05 16:29
→ Bencrie: (debian) 不過 sudo / su 的 PATH 是在另外的地方改 09/05 16:30
→ storyofwind: 所以跟OS也有關係嗎?我是centOS 09/05 17:08
→ kenduest: 寫 xxx.sh 丟 /etc/profile.d/ 看看? 09/05 19:08
→ kenduest: 不過可能要確認使用者自己的 .bash_profile 與 .bashrc 09/05 19:08
→ kenduest: 是否有自己 reset PATH 用自己專屬設定 09/05 19:08
推 chang505: 其他使用者登入不見得會載入/etc/profile 09/05 23:44
→ storyofwind: 感謝各位解答,請教樓上那要透過什麼設定才能載入 09/06 00:14
→ storyofwind: profile檔呢?因為我的理解是登入就會載入 09/06 00:14
推 Bencrie: 看他 ~/.profile 怎麼寫的 09/06 00:17