Operating System - HP-UX
1833777 Members
2094 Online
110063 Solutions
New Discussion

Disabled the only superuser account ROOT

 
SOLVED
Go to solution
Millicent Howze-Simmons
Frequent Advisor

Disabled the only superuser account ROOT

I manage to disable my root account on a HP-UX 11.11 that was converted to be trusted. The problem is root is the only account as the superuser. Do I need to re-install the operating system ? Or is there another way I can restore the root's password.
6 REPLIES 6
DCE
Honored Contributor

Re: Disabled the only superuser account ROOT




you should be able to directly log on from the system console.

If that does not work - you should be able to boot into single user mode and log on.

Failing that, boot off of the install recovery cd, and go into recovery mode - which will allow you to recover root
John Guster
Trusted Contributor

Re: Disabled the only superuser account ROOT

if you have session as root login, you can /usr/lbin/modprpw -k root to enable the root account followed by changing the password of root; if you don't have any session logged on as root, reboot the system, interrupt the autoboot to boot to the single user mode, then do enable root account. Cheers.
Robert-Jan Goossens
Honored Contributor

Re: Disabled the only superuser account ROOT

Hi,

Do you have access to the console? Login and enable the root user.

# /usr/lbin/modprpw -k root

Robert-Jan
A. Clay Stephenson
Acclaimed Contributor
Solution

Re: Disabled the only superuser account ROOT

First, simply try to login as root on the console; that will generally succeed. If that approach fails then do this:

Power off the server. You may literally have to pull the power cord(s). Next, power on the box and watch the console for the Press to interrupt normal boot. Press . At the firmware monitor, enter "BOOT PRI". Then when prompted "Interact with ISL/IPL?", enter "Y" and when the ISL/IPL prompt appears, enter "hpux -is". This will bring the box up in single user mode with root logged in on the console. You can then use the utilities in /sbin to fix your problem. Note only / will be mounted at this point so if you need to use utilities like modprpw which are located in /usr/lbin then you will first need to mount /usr which, in turn, will probably require an fsck before mounting.
If it ain't broke, I can fix that.
Walt Watson
Advisor

Re: Disabled the only superuser account ROOT

After booting to single user mode as described, you may need to do the following if passwd root does not let you change the PW.

Steps:

1. uncorrupt dev as needed, e.g.:

fsck -F vxfs /dev/vg00/rlvol{# corrupted}


2. Mount
/var
/usr
/tmp

3. unlock root

/usr/lbin/getprpw -m lockout, culogin root

provide HP with code to make sure its OK:
0001000 culog = 17

4. unlock PW change:

/usr/lbin/modprpw -k root

5. edit password out of file:

vi /tcb/files/auth/r/root

on line with u_pwd, remove encrypted PW up to the colon; line becomes
u_pwd=:/

6. reset PW:
passwd root

Millicent Howze-Simmons
Frequent Advisor

Re: Disabled the only superuser account ROOT

A. Clay. I had to do just that. I had to literaaly pwerdown and reboot. Your guidance was on target. I was ablt to reset the the password.

Everyone else.. your info was valuable too because of my novice experience I was able to cleect some good troubleshooting notes.

THANKS! :)