Problem in Terminal
Hi,
Within my Red hat, when I login the server using "oracle" login, and then go to the Terminal, I get the prompt like bash-3.2$ in that. Why? |
What's the problem?
If you don't like the prompt, you can change PS1 variable. http://www.thegeekstuff.com/2008/09/...ngelina-jolie/ |
Thanks. I want to see why the prompt does change by itself. And why is the problem only for "oracle" user, while for "root" user, no such problem?
|
That's because the shell prompt is configured for each user separately. Don't look at this as a problem, but rather a useful feature. See also: ~/.profile, ~/.bashrc.
|
Sorry, I am now using "oracle" login and I don't see 2 files below
bash-3.2$ ls ~/.profile ls: /u01/app/oracle/.profile: No such file or directory bash-3.2$ ls ~/.bashrc ls: /u01/app/oracle/.bashrc: No such file or directory |
Quote:
In answer to the original question, "bash-3.2$" is the default prompt when PS1 is not set. The link that kooru gave has comprehensive information but does not include setting the window title for terminal emulators. Many of them use xterm's control sequences, assumed below. In a PS1 value like \[\033]0;\u@\h:\w\007\]\u@\h:\w\$ ...
|
Thanks a lot. How to set PS1? Why is the problem only for "oracle" login while it is fine for root login?
|
Dear all,
Any help to this? |
See post #4; its NOT a problem.
The PS1 prompt (the one you see most of; there are 4 ) can be set individually for each user. If you want it to be different for the oracle user, here's a couple of links to start with http://www.cyberciti.biz/tips/howto-...up-prompt.html http://www.thegeekstuff.com/2008/09/...ngelina-jolie/ |
Thanks. After I've done this
bash-3.2$ PS1="\$" I see the prompt has been changed to $ $ but after I've restarted the server, the prompt is still this bash-3.2$ |
Read the links above; they show how to set it permanently.
|
Hi,
I edited this file bash-3.2$ cd ~ bash-3.2$ vi .bash_profile to put this PS1="\$" inside it. But after I've restarted the server, I still see this bash-3.2$ as the prompt. |
Quote:
|
Quote:
Code:
case $- in Code:
export PS1='\[\033]0;\u@\h:\w\007\]\u@\h:\w\$ ' Code:
source ~/.bashrc |
Catkin,
It is fine now. Do you think it is due to files accidentally deleted or any other reasons for this problem? |
Quote:
Judging from questions seen at LQ and elsewhere on the Internet about oracle login shell customisation (like this one) and shell integration generally (including shell scripting), Oracle themselves do not provide much. I get the distinct impression that they have done the minimum necessary with the shell to get their specialised software products working. The oracle user's shell configuration seems to be basic rather than convenient, the shell scripts are simple rather than well styled and error trapped. Maybe Oracle favour KISS to avoid the maintenance burden of maintaining a lot of sophisticated software for use in a variety of environments. The most likely explanation for the experience you have had is that the files were not created when the oracle user was set up. |
All times are GMT -5. The time now is 08:15 PM. |