1833538 Members
2974 Online
110061 Solutions
New Discussion

root password problem

 
Karen Jenkins
New Member

root password problem

we've inherited a HPUX 11 machine for which we dont know the root password. Ive tried booting it into single user mode, (following the instructions posted on this forum) however, the system hangs when it reaches single user mode. Ive since discovered that we need patch PHCO_226644 to rectify this problem. However, this patch requires root access or a user with root privs (we only have oracle user access - & this user doesnt have enough privs).

Can anyone help me out of this chicken & egg situ?

regds

karen
17 REPLIES 17
Preet Dhillon
Advisor

Re: root password problem

Hi Karen,

This should work on 10.20, I'm not sure about 11.00 but here goes :

- power cycle the machine to reboot it
- interrupt the boot when prompted
- Select bo pri from the menu
- enter Y when prompted with Interact with ISL
- enter hpux -is to boot from secondary loader
- you should now be logged in as root and
should have a prompt on screen. You can now
use the passwd command to reset the root
password
Hope this helps :-)

Best Regards,
Preet
Nothing succeeds like excess
eran maor
Honored Contributor

Re: root password problem

Hi Keren

the system shuold not hung at single user mode
over there you can cahnge the password or you can restore the /etc/passdw file

here is some more ans :

http://forums.itrc.hp.com/cm/QuestionAnswer/1,1150,0x368a663ce855d511abcd0090277a778c,00.html

love computers
boley janowski
Trusted Contributor

Re: root password problem

Karen,

Wow you've got a hard one, did you by chance get any backups of the system, how is the system being backed up? Have you tried to remsh to it from all your other severs/workstations (if you have any, that might be setup in the .rhosts?)

I ask about the method of backup, if its a cron to do a make_recovery, you can let cron make a new recovery tape for you and boot from it, if you have a backup server that server has to login, so you can probably remsh over to it. did you try to look at the passwd file and see if you can login as another user that may have restricted sam privlidges? out side of that im low on ideas. let us know what you have.

Good luck
Karen Jenkins
New Member

Re: root password problem

Hi guys

thanks for the answers but ive already tried booting it, going to the ISL prompt and booting to single user mode - it hangs - the patch to fix this is the one I mentioned in the original message (basically it is a bug) - I cant apply this patch cause I haven't got a user with root privs

I also cant restore the password file because we have just inherited the machine and havent got a backup of the o/s as yet (just the db).

regds

karen
Christopher Caldwell
Honored Contributor

Re: root password problem

It the system Trusted or non-Trusted. If it's trusted, then
grep sys /etc/group and post.
Karen Jenkins
New Member

Re: root password problem


Boley,

thanks for those ideas, they would have been very useful had we had a backup!! The only backup we've got is of the Oracle Fincancials system on there (of which there are 3 and very large) which is why I really want to try to avoid reinstallation.

The machine doesnt reference any of the other system through rhosts and we haven't got a user with restricted sam privs!!

You can see what a sticky situation im in !!
thanks for your help anyway

regds

karen
Ovidiu D. Raita
Valued Contributor

Re: root password problem

I would boot from the support CD and try a system recovery. One of the menus lets you run a shell. Then you can load the commands you would need for recovey ( mount, ls ,etc ), mount the root file system on a temp dir, wipe out the root passwd the then reboot. If the system does not boot if single user mode it might not boot on level 3 either. Give it a try at least.

Regards,
Ovidiu
Simple solutions to complex problems
Peggy Fong
Respected Contributor

Re: root password problem

Karen,

Since it hangs at single-mode (do you know what the patch fixes? lvm?) I was thinking you could try booting to maintenance mode which is similar to single-user mode but with no LVM activated. If this works, you could change the root passwd and then reboot the system.

To do this is similar to boot to single user from the ISL prompt but the command is:
hpux -lm
(that's an ell not a number 1).

I believe passwd is in /bin and should be available with root mounted and the passwd file should be available as well.

Just another thought for a sticky situation.

Peggy
Byron Myers
Trusted Contributor

Re: root password problem

If you can see the encrypted password for root in /etc/passwd (the system isn't trusted), then run crack on it. Crack is available all over the WEB (even for HP-UX).
If you can focus your eyes far and straight enough ahead of yourself, you can see the back of your head.
Wieslaw Krajewski
Honored Contributor

Re: root password problem

Hi Karen,

You haven't explained precisely what do you mean by system hangs at the single user run level. I can assume one of three possibilities:

1. you can see root prompt,
2. you are asked for Login|Password
3. system hangs before reaching the state mentioned in 1. and 2.

In the first case (non-trusted mode) it is enough to run
passwd root
In the third case we need some more info relating to a point system hangs.
The second case is the case of trusted system (C2 level) and single user run level is password protected.
The a brief procedure is as follows:
1. Boot from the Install Core OS cdrom, do not interrupt
2. From the menu select: Run Recovery shell.
3. After some time you'll reach Main Menu and you should select from this menu the last item:
Instructions on chrooting to lvm
4. Read carefully info what to do next, it says go to shell and run chroot_lvmdisk
5. So do this, select exit to shell and run chroot_lvmdisk.
This is interactive script and be prepared to answer the question what is the hardware address of your normal boot disk. Read carefully displayed info.
6. Next
cd /ROOT
chroot /ROOT /sbin/sh
7. After the above two commands you'll be in your root file system, but with no LVM. Therefore run
vgchange -a y vg00
mount -a
and you can ignore warnings you'll see.
8. After the step 7, you will be able to use vi editor.
So go into /tcb/files/auth/r directory (as I remember well?) and edit root file to delete password.
9. exit from chroot and boot from the Main Menu.

Hope this helps.

Rgds.
6
Permanent training makes master
J. Barrow
New Member

Re: root password problem

To Christopher Caldwell:

I am having a similar problem to Karen, but I do not have a hang problem. I am able to enter single user mode and even change the root password, but I get "Account locked in the commerical security database" when I try to login as root. I think the system is "Trusted". Here is the result of my grep sys /etc/groups ...

sys::3:root,uucp,user1,user2

Can you tell me how to unlock the root account in the commercial security database?

I couldn't find "ulckpwdf" on my system (HP UX 11.00) which seemed to be something that might work.

Thanks for any info. --John
Tim D Fulford
Honored Contributor

Re: root password problem

It sounds like you are in deep doggy do do...

You might try taking an ignite-UX image & re-installing from there? During the Ignite-UX install you set the user password. Ignite should be better that an installatioin from OS disks & app disks.

just a thought

Tim
-
Tim D Fulford
Honored Contributor

Re: root password problem

if you are on a trusted system it is fairly well locked down. try boting into single user mode & moving /tcb to /tcb.old, then edit /etc/passwd file to get rid of * for root passwd.

Tim

-
Frank Slootweg
Honored Contributor

Re: root password problem

> thanks for the answers but ive already tried booting it, going to the ISL prompt and
> booting to single user mode - it hangs -

As others have mentioned, please describe what exactly "it hangs" means, i.e. please post all previous messages/commands upto the hang and more fully describe the hang, i.e. disk activity, display indicators, etc..

> the patch to fix this is the one I mentioned in the original message (basically it is a
> bug) - I cant apply this patch cause I haven't got a user with root privs

Please repost the correct patch number. The original number had 6 digits, should be 5. While not impossible, I think it is unlikely that a commands (CO) bug causes a single-user boot failure.

Richard Price_1
Advisor

Re: root password problem

This is very late in the day. I had a locked out root account on an Itanium 11.23 trusted system. To fix it I booted into single user

Interrupt boot

HPUX> boot -is

Once at the root prompt...

# bcheckrc

Go into the character-cell sam

# sam

Go through the menus, highlight the root user and from the Actions menu, re-activate the account.

Change the root password to something that you know.

# passwd


Reboot normally and the root account is unlocked.
Sanjay_6
Honored Contributor

Re: root password problem

Hi Karen,

If you have an ignite image of this, boot through that and go to the recovery shell. fsck and mount the required filesystems. you should be able to edit the passwd file and remove the root password.

The suggested docs below may not address your concerns directly, but the doc can be used as a guide.

//Quote//

Here is a list of other documents in the ITRC you might need to help with this recovery.
How do I boot my system from Support Media on 10.X ? (OZBEKBRC00000581)
How do I boot my system from Support Media on 11.00 ? (OZBEKBRC00000582)
How do I boot my system in single user mode or other mode ? (OZBEKBRC00000607)

//EndQuote//

Hope this helps.

Regds
Bruno Ganino
Honored Contributor

Re: root password problem

Karen,
I had a system very old and resolved these problems :
1) With user secondary, used command "su" obtaining permissions for edit file "/etc/passwd" or... without user secondary, used rebooting single user mode.
2)Edit (with "vi") and Duplicate line relative to user root in "/etc/passwd". Every line contain name:passwordcrypt:numuserid:(other)
3) Insert "#" to begin line duplicate (# = ignore)
4) On other duplicate line, Cancel password, change line by name:passwordcrypt:numuserid:(other) to name::numuserid:(other)
5) Save and exit
ATTENTION !!!
I do not know the new systems of HP and therefore I do not know if what I have written he is corrected! Before making this, it must make sure that it is not dangerous.
Torino (Turin) +2H