issue with 'su ' login
Code:
[avi@localhost ~]$ cat /etc/passwd Code:
[avi@localhost ~]$ su please help! |
Hello,
Why would you do that? The /bin/bash in the passwd file is just the shell that's been assigned to root and has nothing to do with your PATH environment. Remove it from the passwd file and you'll not have the error any more. If you want to know what's in your path variable then echo it: Code:
echo $PATH Eric |
Hi,
Also check your /var/backups (if that exists), I seem to remember that Debian makes backups of passwd and shadow to that directory. Not sure if it's the same for your distro (CentOS wasn't it?). Kind regards, Eric |
Quote:
Any other way?? |
Try su with the --shell argument.
Code:
su --shell=/bin/bash If you'd like to change your path, look at .bash_profile |
Quote:
Code:
[avi@localhost ~]$ su --shell=/bin/bash |
err, try it without the equals, sorry.
Code:
su --shell /bin/bash |
Quote:
|
Hi,
Try as the user you're logged in with: Code:
sudo vi /etc/passwd Kind regards, Eric |
Quote:
Code:
[avi@localhost ~]$ sudo vi /etc/passwd |
Quote:
That's what happens when you put stuff in places where it doesn't belong. I'm sure you've learned a lesson here, first study, learn, investigate before trying out stuff. Kind regards, Eric |
Quote:
I did that by booting in single user mode and using nano to edit the /etc/passwd file. It worked fine. |
All times are GMT -5. The time now is 07:37 PM. |