During Linux system operation, the terminal interface prompts -bash-2.05b$ after booting, which causes the terminal to be unable to display in color. How should I deal with this problem? The following small series will introduce you to the Linux terminal prompt -bash-2.05b$ solution, I hope to help you.
display interface surface Linux terminal when the first time now:
onejet20080605 (root) ~ $ "normal display"
terminal displays the next boot :
-bash-2.05b$ "The display is not normal"
And the color display of the terminal is gone.
Solution:
First, confirm your root directory (if you are using the root user to log in) have the following two files:
1, /root/.bashrc
2, /root/.bash_profile
Note that these two files are hidden files.
Second, if not, create these two files and add the following to these two files:
/root/.bashrcContent:
# .bashrc
# User specific aliases and functions
# Source global definitions
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi
/root/.bash_profileContent:
# .bash_profile
# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
# User specific environment and startup programs
export BASH_ENV=$HOME/.bashrc
III, by the above two Look at the script, also related to the /etc/bashrc file, if not, it is also created, its contents are as follows:
/etc/bashrc content:
# /etc/bashrc
# System wide functions and aliases
# Environment stuff goes in /etc/profile
# Uncomment if you liked the old colourfull prompt
# PS1=&lsquo ;\\[\\033[1;33m\\]\\u\\[\\033[1;37m\\]@\\[\\033[1;32m\\]\\h\\[\\033[1;31m\\]\\w\\[ \\033[1;36m\\]\\$ \\[\\033[0m\\]’
PS1=‘\\[\\033[0;34m\\]\\h (\\[\\033[0; 31m\\]\\u\\[\\033[0;34m\\]) \\[\\033[0;32m\\]\\w $ \\[\\033[0m\\]’
VIM=“/Usr/share/vim”
alias ls=‘ls --color=tty -F -b -T 0’
After the above three steps will generally succeed, you only have to Open a terminal To see the effects. Of course, this is related to /etc/hosts, /etc/passwd, etc., but generally which of the above files are not or have gone wrong.
The above is a solution for the emergence of -bash-2.05b$ on Linux terminals. This problem may be related to the loss of /root/.bashrc, /root/.bash_profile and /etc/bashrc files. Recreate it.
I chatted with friends before, knowing that I can use PXE to install virtual machin
In many cases, Linux is used as a server to allow computers on the Internet to acce
In Linux, two tools, tmux and vim, can be used to develop projects. Many people pre
In Linux system apachectl is a command related to the Apache HTTP server program. The first half of
Linux method for synthesizing multiple file contents
How to use Ubuntu command management authority
What can I do if I can't access mysql under Linux?
Ubuntu vi using the arrow keys error how to solve?
What should I do if the Linux crontab has a BAD FILE MODE error?
How to install JITwatch in Linux system?
What should I do if the Ubuntu login screen resolution is too high?
Linux system call fork() function method
Linux system lsof command use instance summary
How can win10 find applications quickly? Application quick find method
Linux remote login tool: Putty simple tutorial
Win10 how to retrieve multiple right-click menu items lost after selecting multiple files
Forced shutdown of Windows 7 will start black screen
How to turn off location service
Windows 8 Add or Remove Device Tips
What if Win10 cannot run the green batch file?
Windows 10 preview version how to set up multi-screen display?