LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 07-11-2001, 07:10 PM   #1
gummyworms
LQ Newbie
 
Registered: Jul 2001
Location: Wisconsin
Distribution: Redhat 7.1
Posts: 4

Rep: Reputation: 0
bash-2.04#? what happened to root@localhost


Okay, I installed a copy of Redhat 7.1 today, and after that, installed MySQL, Apache, PHP, and Samba, in that order. Now, instead of saying [root@localhost] at the shell, it says bash-2.04.
I dont know why it happened.

How do I revert to my original shell?

Thanks,
Shawn
 
Old 07-11-2001, 07:29 PM   #2
jharris
Senior Member
 
Registered: May 2001
Location: Bristol, UK
Distribution: Slackware, Fedora, RHES
Posts: 2,243

Rep: Reputation: 46
Have a look in /etc/profile for the following lines (or something close), and set them as below.
Code:
# Set a default shell prompt:
#PS1='`hostname`:`pwd`# '
if [ "$SHELL" = "/bin/pdksh" -o "$SHELL" = "/bin/ksh" ]; then
 PS1="! $ "
elif [ "$SHELL" = "/bin/zsh" ]; then
 PS1="%n@%m:%~%# "
elif [ "$SHELL" = "/bin/ash" ]; then
 PS1="$ "
else
 PS1='\u@\h:\w\$ '
fi
PS2='> '
The shell won't have changed much, just the prompt settings.

HTH

Jamie...
 
Old 07-12-2001, 11:47 AM   #3
gummyworms
LQ Newbie
 
Registered: Jul 2001
Location: Wisconsin
Distribution: Redhat 7.1
Posts: 4

Original Poster
Rep: Reputation: 0
Thanks jharris, I retraced my steps and found out what happened. I access my web server using Samba, logging in as root on my windows machine and mapping a network drive to access the linux box. Problem was, when I logged in with root on the windows machine, it would only let me stay in the /root/ directory, and I couldnt access my web server files.

I did a "usermod -d / root" to change the root's home dir to /, so I could access the full server. After that, I got the bash-2.04# thing, so I reverted the root home back to /root/ and got my original prompt back.

Is there a way to change a user's home directory, and automatically move the files associated with that user?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Root@localhost Problem petenyce Linux - Newbie 1 09-28-2005 10:55 PM
root@localhost:~# xf86config -bash: xf86config: command not found klemen Slackware 17 01-06-2005 03:56 AM
root@localhost t0ker Linux - Newbie 4 09-14-2004 07:38 AM
Terminal : user@localhost => bash-2.05a$ storm Linux - Newbie 3 03-09-2003 06:22 PM
Changing root@localhost to root@domain.com Stingreen Linux - General 14 12-17-2002 07:21 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 02:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration