- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Problem with /etc/password
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-20-2002 01:36 PM
тАО08-20-2002 01:36 PM
Problem with /etc/password
I am not able log into HP machine because I changed the login shell for root from /bin/sh to /bin/ksh in /etc/password file. Now I m not able to login in to the machine. I get the following message. Please help me to recover.
Local flow control on
Telnet TERMINAL-SPEED option ON
HP-UX ozzie B.11.00 U 9000/800 (ta)
login: root
Password:
Please wait...checking for disk quotas
No shell
Connection closed by foreign host.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-20-2002 01:39 PM
тАО08-20-2002 01:39 PM
Re: Problem with /etc/password
You will need to boot from your recovery media and mount / as /root and edit /root/etc/passwd.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-20-2002 02:37 PM
тАО08-20-2002 02:37 PM
Re: Problem with /etc/password
Do you have another user at UID 0?
If so, you can repair that way by logging in as an alternate admin.
If your not sure, log in as a regular user and more /etc/passwd to see if there is another user at UID 0. If so, your on your way to being in.
Note - Be very careful and mindful of multiple admin accounts as they can lead to trouble.
Good luck,
Kel
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-20-2002 03:40 PM
тАО08-20-2002 03:40 PM
Re: Problem with /etc/password
One other thing to try IF you have another HP-UX system with access to a root account
1) Login to the other system as or become root
2) ftp to the original system - as root
ftp> cd /etc
ftp> lcd /etc
ftp> rename passwd passwd.bad
ftp> bin
ftp> put passwd
Then try to login to the original system. If you get in edit the passwd.bad BACK to proper shell, rename the "temp" passwd file to passwd.tmp & the original back to passwd.
It's a good idea to keep a safe backup copy of the passwd & group files somewhere on the system & cron it to copy it out at least once a week - even more if the file changes frequently.
Rgds,
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-20-2002 04:15 PM
тАО08-20-2002 04:15 PM
Re: Problem with /etc/password
(2) boot (power on)
(3) interrupt boot cycle and boot from your normal boot device BUT say "Y" to interact with ISL
(4) then enter
hpux -is
(5) then when in single user mode
fsck
mount -a
(6) then fix /etc/passwd
then reboot
live free or die
harry
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-20-2002 05:51 PM
тАО08-20-2002 05:51 PM
Re: Problem with /etc/password
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-21-2002 08:38 AM
тАО08-21-2002 08:38 AM
Re: Problem with /etc/password
Thanks for all ur replys. I tried all the option
Mr Stephenson,
I did bootup from recovery media
but and we to the maintenance shell, but u cannot mount any thing in maitenance shell.
Hi Kelli,
Unfortuantely, I didn't have any user with UID 0.
Hi Jeff,
I tried ftp, but login would fail as soon as u type root as a user.
Hi Harry,
Your solution was right on the money. I followed exactly and got the problems fix.
Hi Sridhar,
Only the root shell was wrong, therefore the system would never come to single user mode unless and until we bring it up to single user mode. I was able to loggin as a different log
Thanks u all
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-21-2002 06:32 PM
тАО08-21-2002 06:32 PM
Re: Problem with /etc/password
Something to remember, any time you make a change to the root entry of the password file make sure to su to root and make sure it works.
That way if it doesn't, your still logged in as root and can fix the problem.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-21-2002 08:39 PM
тАО08-21-2002 08:39 PM
Re: Problem with /etc/password
hv you tried "switch user" , i mean login as another user & do an
$ su
Kapil Raj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-21-2002 08:42 PM
тАО08-21-2002 08:42 PM
Re: Problem with /etc/password
mv /bin/ksh /bin/ksh.old (backup)
ln /bin/sh /bin/ksh
once u r able to login remove the link & restore actual /bin/ksh from the back up copy
Kapil Raj