直接在-bash-4.1$后面加上export PS1="[\u@\h \w]"即可,如下:

[root@localhost usr]# su oracle
-bash-4.1$ export PS1="[\u@\h \w]"

Copyright © 2024 zkx4213
Powered by .NET 9.0 on Kubernetes