[英]Ubuntu 14.04 terminal corrupt
In my Ubuntu terminal, somehow my terminal system name has been mounted to the root directory. 在我的Ubuntu终端中,以某种方式将我的终端系统名称挂载到根目录中。 Anyway, my terminal is displaying this: 无论如何,我的终端正在显示以下内容:
admin.Ubuntu:/$
Instead of 代替
admin.Ubuntu:~$
Now i cannot even see my home files and directories. 现在,我什至看不到我的主文件和目录。 How can i fix this? 我怎样才能解决这个问题?
You can verify what is defined setting for your shell prompt. 您可以验证为shell提示定义的设置。 What is the output of following command? following命令的输出是什么?
pwd
echo $PS1
echo $PS2
echo $PS3
Then cross check that the path between current path and your shell prompt. 然后交叉检查当前路径和您的Shell提示符之间的路径。
EDIT 编辑
Based on the updated question, it seems pwd
is at root folder /
, and $PS1
is set to ${debian_chroot:+($debian_chroot)}\\u@\\h:\\w\\$
根据更新后的问题,似乎pwd
位于根文件夹/
,并且$PS1
设置为${debian_chroot:+($debian_chroot)}\\u@\\h:\\w\\$
pwd
, explains why your prompt is different. 因此, pwd
的值说明了您的提示为何不同。 PS1
do? 还阅读了PS1
定义是什么? https://askubuntu.com/questions/372849/what-does-debian-chrootdebian-chroot-do-in-my-terminal-prompt/372862#372862 https://askubuntu.com/questions/372849/what-does-debian-chrootdebian-chroot-do-in-my-terminal-prompt/372862#372862 You may also want to check if your ~/.bash_profile
, ~/.profile
, ~/.bashrc
are correct. 您可能还需要检查~/.bash_profile
, ~/.profile
, ~/.bashrc
是否正确。 To do so read for the order in which these files are read by bash
( see man bash
for FILES
section ). 为此,请阅读bash
读取这些文件的顺序(请参阅man bash
的FILES
部分)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.