Sie sind auf Seite 1von 7

1

Recovering Root Password

Root Password can be recovered in a


specialized troubleshooting mode (i.e. init 1)

init 1 level provides a shell (i.e. sh) without logging in.

2
Recovering Root Password

Procedure
Procedure
Restart
Restartthe
thesystem
system
In
In the splashscreen
the splash screenSelect
Select RedHat
RedHatEnterprise
Enterprise Linux
Linux
Press
Press e
Select
SelectKernel
Kernel/vmlinuz-2.6.9-5.EL
/vmlinuz-2.6.9-5.ELro
roroot=LABEL=/rhgb
root=LABEL=/rhgbquiet
quiet
Press
Press e to edit
to edit
Edit
EditKernel
Kernel/vmlinuz-2.6.9-5.EL
/vmlinuz-2.6.9-5.ELro
roroot=LABEL=/rhgb
root=LABEL=/rhgbquiet
quiet11
Press
Press Enter
Enter
Press
Press b totoboot
bootwith
withthe
the selected
selectedrun
run level
level
directly
directlyyou
youwill
willget
getshell
shellprompt
prompttotoassign
assignthe
theroot
rootpassword
password
sh-3.00#passwd
sh-3.00#passwdroot
root

3
Assigning Grub Password

Assigning
AssigningGrub
GrubPassword
Password
[root@comp1~]#
[root@comp1~]# grub-md5-crypt >>/boot/grub/grub.conf
grub-md5-crypt >> /boot/grub/grub.conf
[root@comp1~]#
[root@comp1~]#vi
vi/boot/grub/grub.conf
/boot/grub/grub.conf

Add
Add line
linein
in/boot/grub/grub.conf
/boot/grub/grub.conf
hidden
hiddenmenu
menu
password
password --md5
--md5 <password>
<password>
title Red Hat ------
title Red Hat ------

4
Recovering Grub Password

Recovering
RecoveringGrub
GrubPassword
Password
Boot the System in Rescue Mode
Boot the System in Rescue Mode
#
# chroot
chroot /mnt/sysimage
/mnt/sysimage
#
# vi /boot/grub/grub.conf
vi /boot/grub/grub.conf

Remove
Removeline
linefrom
from/boot/grub/grub.conf
/boot/grub/grub.conf
hidden menu
hidden menu
password
password ----md5
md5 <password>
<password>
title Red Hat ------
title Red Hat ------

5
Other Configurations

To
Toconfigure
configureprinter
printer
[root@comp1~]# system-config-printer
[root@comp1~]# system-config-printer

To
Toconfigure
configuremodem
modem
[root@comp1~]# system-config-network-druid
[root@comp1~]# system-config-network-druid

6
Other Configurations

To
Toview
viewthe
theprocess
process
[root@comp1~]# ps -aux
[root@comp1~]# ps -aux

To
Tokill
killaaspecific
specific process
process
[root@comp1~]# kill -9 <process
[root@comp1~]# kill -9 <process id>id>

To
Toview
viewCPU
CPU usage
usageby
byall
allprocess
process
[root@comp1~]#
[root@comp1~]#top
top

Das könnte Ihnen auch gefallen