-   Linux - Newbie (
-   -   login prompt confusion (

arun natarajan 08-04-2015 11:00 PM

login prompt confusion

Current shell environment is BASH. How shd i switch between these two login prompts and what is meaning for the both when we use each. pls assist.


[root@localhost ~]#

casualfred 08-05-2015 01:01 AM

You can actually customize the prompt for your BASH shell however you wish.

For the login shell (when you first boot up your computer, if it boots to a shell):
it will first read and execute commands from /etc/profile, ~/.bash_profile, ~/.bash_login, and ~/.profile

For an interactive shell that is not a login shell:
it will read and execute commands from ~/.bashrc

So, to change the prompts for your BASH shell, just edit the "PS1=..." entry in one of those files (if they exist).

This is a useful guide:

All times are GMT -5. The time now is 04:59 AM.