Reset forgotten root password on CentOS

1. Boot the system and when you see the following message "Press any key to enter the menu",press any key. (You will see the list of available kernel versions.)

2. Press e in order to edit commands before booting.

3. Highlight the list item with vmlinuz in it by using the arrow keys and press e.

4. Now type single or init 1 at the end of the line.

5. Then press enter and b to boot the system with the new argument. (The system will boot into single user mode and you will see bash prompt)

Now it's time to change the password:
6. Type passwd

### Shell Commands ###
passwd
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully

 

7. 

  • 15 Korisnici koji smatraju članak korisnim
Je li Vam ovaj odgovor pomogao?

Vezani članci

How to Reset Mysql passowrd

  Step # 1 : Stop mysql service # /etc/init.d/mysql stop Output: Stopping MySQL database...

How to Change SSH Port in Centos

Login into your Server Via Putty or any SSH client.type in following...

Linux Firewall Fail2Ban

How To Protect SSH with fail2ban on CentOS 6  Step One—Install Fail2Ban Because...

Adding and viewing IP addresses on CentOS servers

To add newly assigned IP addresses from SSH, follow this procedure: (Please follow the steps...

How to change hostname on CentOS Linux

Hostname Change There are 4 steps in a hostname change, luckily all the steps are easy....