Operating System - HP-UX
1833279 Members
3174 Online
110051 Solutions
New Discussion

Re: help: about root account locked

 
SOLVED
Go to solution
常有慈悲心
Regular Advisor

help: about root account locked

i use trusted system ,on b2000,
root was locked today ,
i use this way to unlock but fail:
1.boot to single user mode,
2.mount -a
3./usr/lbin/modprpw -k root
4.vi /tcb/files/auth/r/root
and change
:u_pwd=:


5.reboot
now i can't get into single user mode

because wrong passwd,
how should i do?

thanks everyone

13 REPLIES 13
Joseph Loo
Honored Contributor

Re: help: about root account locked

hi,

i do not think u need to boot to single user mode to unlock root.

# /usr/lbin/modprpw -k root
would have done that.

boot to single user mode, if you have totally forgotten your root password.

regards.
what you do not see does not mean you should not believe
Sritharan
Valued Contributor

Re: help: about root account locked

Hi,


All you have to do is reboot the machine and go into single user mod and change the password. That's all


Thanks & Regards
SRi
Known is a drop...unknown is an ocean -> quote from a movie
Dani Seely
Valued Contributor

Re: help: about root account locked

Try to reactivate account via SAM (or use /usr/lbin/modprpw -k root)

Also check for -t lockfiles under /tcb
# find /tcb -name \*-t
If lockfiles are found rename or delete the file(s) and see if this resolves your problem.
Together We Stand!
Dani Seely
Valued Contributor

Re: help: about root account locked

You could also perform the following to uncovert your trusted system, change the password, then convert your system back to a trusted system:
1) Boot to single user mode
2) # mount -a
3) # /usr/lbin/tsconvert -r (this will revert your system to a non-trusted system)
4) # vi /etc/passwd (remove root's encrypted password)
5) # passwd (set a new password for root)
6) # /usr/lbin/tsconvert (return to trusted system).
Together We Stand!
Dani Seely
Valued Contributor

Re: help: about root account locked

You could also try the following, if nothing else works, this should:
1) Boot to single-user mode or reboot the system
2) Interrupt the boot process when you see the prompt, "Press any key to stop in 10 seconds"
3) Boot from the boot device and answer 'Y' to interact from IPL or type: 'bo pri ISL'
4) You will be at an 'ISL>' prompt and you will need to type: 'hpux -is'
5) The system will be booted into single-user mode and you will be logged in as "root".
6) Change the root password using the 'passwd' command and reboot.

Good luck!
Together We Stand!
Shaikh Imran
Honored Contributor
Solution

Re: help: about root account locked

Hi,
Are you prompted for password when you try to get into single user mode ?
If yes then only you have the option of booting from the supportCD and run rescue system and mount the / and /usr filesystem on temporary directories and revert back the changes you have made.


Regs
I'll sleep when i am dead.
常有慈悲心
Regular Advisor

Re: help: about root account locked

hi
i run rescue system ,
now i in shell
but i can't find anythind in /usr/lbin

,
and use bdf,
only / in mounted
what should i do next?

regds
Joseph Loo
Honored Contributor

Re: help: about root account locked

at single user mode, only / and /stand are mounted, try this to mount /usr

# /sbin/mount /dev/vg00/lvol7 /usr
# /usr/sbin/passwd
change your password

and then either restart the server or use init 3, but i go for a normal restart.

regards.
what you do not see does not mean you should not believe
Joseph Loo
Honored Contributor

Re: help: about root account locked

at single user mode, only / and /stand are mounted, try this to mount /usr

# /sbin/mount /dev/vg00/lvol7 /usr
# /usr/sbin/passwd
change your password

and then either restart the server or use init 3, but i go for a normal restart.

regards.
what you do not see does not mean you should not believe
Bharat Katkar
Honored Contributor

Re: help: about root account locked

Hi,
Go to /etc/fstab, look which lvol is for what filesystem. Then mount the filesystem /usr and /var.

#mount /dev/vg00/lvolx /usr
#mount /dev/vg00/lvolx /var
#passwd
New Password:
Confirm Password:

This should work,.
All the best.



You need to know a lot to actually know how little you know
常有慈悲心
Regular Advisor

Re: help: about root account locked

in secure system
i can't mount /dev/vg00/lvol7 /usr
Joseph Loo
Honored Contributor

Re: help: about root account locked

sorry, that is only an example.

check /etc/fstab:

# /sbin/cat /etc/fstab
look for which logical volume is /usr mounted to:
# /sbin/mount /usr
and do the necessary changes.

regards.
what you do not see does not mean you should not believe
Bharat Katkar
Honored Contributor

Re: help: about root account locked

Hi there,
1. Boot to the single user mode using "hpux -is" at ISL prompt.
2. You will the hash prompt directly.
3. cat /etc/fstab, look for line containing /usr and see which logical volume it is using.
4. Let us consider it as /dev/lvol6 (whatever you have)
5. mount /dev/lvol6 /usr
6./usr/lbin/modprpw -k root
7.reboot

See if that works.

All the best.

You need to know a lot to actually know how little you know