Computing.Net > Forums > Solaris > Root default login shell changed! Help!

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Root default login shell changed! Help!

Reply to Message Icon

Name: John
Date: December 9, 2001 at 23:31:34 Pacific
Comment:

Hi All,

I had changed the root default login shell from /sbin/sh to /usr/local/bin/bash in /etc/passwd file but failed to work and I had accidentally logged out from the server. When I tried to login to the server using root account, it will always prompt me for errors found. Now I can't even use sudo command to take control of the server.

Qn: How can I revert back to the default /sbin/sh login shell for the root account??

I had tried to use the below methods but it can't work(currently the server is running Solaris 8):
- "boot cdrom -s" and I was prompted with a login password instead of a hash prompt and I could not even mount the default / root directory to edit the /etc/passwd file!!!

Pls advise. Thanks. :)



Sponsored Link
Ads by Google

Response Number 1
Name: Mark M
Date: December 10, 2001 at 06:02:23 Pacific
Reply:

When you

boot -s cdrom (not the other way round)

you should be able to do mount /dev/dsk/c0t0d0s0 (or whatever your root partition is) to /a

then cd /a/etc

and edit the end part in /etc/passwd for the root account shell type. (ie: change it back to /bin/sh)

then just reboot the machine and all should be okay.


0

Response Number 2
Name: cheezer
Date: December 10, 2001 at 17:09:19 Pacific
Reply:

The reason it faile dis because /usr/local is not seen at the beginning of boot up, only the root partition with /usr.

It is a very common mistake by beginners.


0

Response Number 3
Name: John
Date: December 10, 2001 at 17:51:41 Pacific
Reply:

Hi Mark,

Thanks... I tried but I still can't go to the EEPROM I want... Is it becos it is Solaris 8???
It still prompts me for password for maintenance and after that, a login prompt will appear!!!


0

Response Number 4
Name: guichen zhang
Date: December 11, 2001 at 06:40:35 Pacific
Reply:

use:
OK boot cdrom
after the openwin startup, just open another window to do the work. "boot cdrom -s" will ask you the password.


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Solaris Forum Home


Sponsored links

Ads by Google


Results for: Root default login shell changed! Help!

Invalid default login shell for root www.computing.net/answers/solaris/invalid-default-login-shell-for-root/1078.html

root shell change in /etc/passwd www.computing.net/answers/solaris/root-shell-change-in-etcpasswd/286.html

Solaris Boot CDROM root login www.computing.net/answers/solaris/solaris-boot-cdrom-root-login/4087.html