Skip to content

How to Reset Root Password on Fedora Linux

  • by

To reset the root password on a Fedora Linux system, you can follow these steps:

  1. Boot the system in single-user mode:

To boot the system in single-user mode, you will need to interrupt the boot process and enter the bootloader command line. Depending on your system, this may be done in different ways, such as pressing a key during the boot process or using the system firmware settings.

Once you are at the bootloader command line, enter the following command:

linux single

This will boot the system in single-user mode, which allows you to access the system with root privileges without a password.

  1. Mount the root file system as read-write:
mount -o remount,rw /

This command mounts the root file system in read-write mode, which is required to change the root password.

  1. Change the root password:
passwd

This command will prompt you to enter a new root password. Enter the new password and confirm it when prompted.

  1. Reboot the system:
reboot

This will reboot the system and load the normal boot process.

Keep in mind that these steps assume that you have physical access to the system and are able to boot into the bootloader command line. If you are unable to do so, you may need to use other methods to reset the root password, such as using a live CD or booting from a USB drive.

It’s also a good idea to make a backup of your system before resetting the root password, in case something goes wrong.

Visited 1 times, 1 visit(s) today

Leave a Reply

Your email address will not be published. Required fields are marked *