iT邦幫忙

0

How to Reset forgotten root password in RHEL/CentOS 7/8

As a Linux Administrator, You must know the importance of root User.

Without root User, you cannot do any kind of configuration in Linux such as creating a partition, Configuring a service, and so on.

That’s why root is also called as Superuser.

Just think about what will happen if you forget the root user’s password.

In this guide, I will teach you How to reset forgotten root password in RHEL/CentOS 7/8

I will teach you two methods by which you can reset the root password.

Let’s get started.

**Method #1
**

First, let’s focus on the method one.

Step #1 Reboot your RHEL/CentOS 7/8 Server
reset the forgotten root password, we have to boot the server in the single-user mode for which we have to edit the Grub menu.

Hence to do this restart the server.

As soon as you restart the server, you will get the following screen.

Here you will get 5 seconds to interrupt the normal boot process. So quickly press any key to interrupt the boot process.

Step #2 Edit the Grub Menu

Now select the highlighted menu and press e to edit the same.

Note: You can select the menu by using up and down arrow on your Keyword.

**Step #3 Make necessary changes
**

Now look for the line that contains Linux kernel executable that is vmlinuz. Highlighted in the below snapshot.

Move the cursor to the end of that line then next to quiet give a space and type rd.break. Refer to the snapshot below.

Note: You can use up, down, right, and left arrow on your Keyword to move the cursor. To go to the end of the line press CTRL+E.

After typing as instructed on the screen, press CTRL+X to proceed to the next step.

After following the above steps, we have successfully come into single-user mode and we’ve got bash prompt to type the commands.

Complete Story


圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

尚未有邦友留言

立即登入留言