新添加用户登录pts只显示-bash-4.1#

今天在服务器Centos6.5下新添加了一个用户,然后远程登录上去,终端显示: -bash-4.1#这个是因为什么,怎么解决啊?
已邀请:

push - 打杂的!

赞同来自: Geek小A

这个可能是你创建用户的时候,然后创建家目录的时候,家目录已经存在了,然后出现这种问题,至于其他原因,还没有遇到过!
 
**解决方法一:**
从你相同系统支持的机器拷贝.bashrc 和 .bash_profile这两个文件到你登录的用户的家目录下。
 
**解决方法二:**
手动添加.bashrc和.bash_pfofile两个文件,内容如下
.bashrc# .bashrc

# Source global definitions
if ; then
. /etc/bashrc
fi

# User specific aliases and functions.bash_profile# .bash_profile

# Get the aliases and functions
if ; then
. ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/bin

export PATH

要回复问题请先登录注册