Saturday, September 11, 2010

To Recover Root Password

I am trying  to cover   the password file information and root password recovery . It is not the task of DBA but sometimes the knowledge of Unix administration task help us to do the activities in effective manner .
Password file information of root :-
Operating system Sun Solaris :-  /etc/passwd and /etc/shadow
Operating system AIX :- /etc/passwd and /etc/passwd/security
Operating System Linux :- /etc/passwd and /etc/shadow
Operating System HP-UX :- /etc/passwd and /tcb/files/auth/r/root
Being a DBA we need to have good idea about unix important files .
Sun Solaris :-
boot cdrom -s
mkdir /tmp/a
mount the cd using mount /dev/<Device>    /tmp/a
vi /tmp/a/etc/shadow
AIX
boot from cdrom or tape installation/Mantienance
start limited shell
getrootfs hd1sk0
vi /etc/security/passwd
Linux
If it LILO (Linux  Loader) its a bootstrap program  then we have  the follow the below steps :-
lilo
Control -x
linux  s
passwd root
If it GRUB (Grans Unified Bootloader) then
grub
c
kernel vmlinuz-2.4.9-13 single  ro root=/dev/hda8 initrd  /initrd-2.4.9-13.img boot
passwd root
HP-UX
boot interact with ipl ? Y
isl->hpux- iS
passwd root
Out of all the  above opertaing system steps , i personally tried  Linux (LILO) and it worked

No comments:

Post a Comment