I am was unable to use the root password that i had reset by following the below steps. I was getting login denied
1. On the Grub menu type e
2. edit the Linux16 with rd.break
3. hit Ctrl+x
4. mount -o rw,remount /sysroot
5.chroot /sysroot
6. passwd
7. Enter password again
8. echo / .autorelabel
Hi Ben, in this case, do you mean that if rd.break fails to reset password you can use ro init=/bin/bash? My question is, which one is correct?
init=/bin/bash OR ro init=/bin/bash
Actually, I noticed the same thing on my RHEL 9 (developer) system, too. It asks me for a password - even when using rd.break. I forgot about it until I saw this thread 'cause I haven't been messing with the new RHEL (RH124/RH134) labs . . . until this week.
I went to try and see if workstation (or servera or serverb) would work . . . until I found that the timeout on grub has been set to 0. So I have to go change that first...
...so yup, workstation stops and asks for a root password.
Also Mr. Baker, I also got problem with grub2-mkconfig, do you also experience that /etc/default/grub, doesn't conveyed or rendered to /boot/grub2/grub.cfg and /boot/efi/EFI/redhat/grub.cfg ? I tried to change the timeout into 5 from 0 as on cloud lab, but it seems doesn't work as it intended and still stay at 0.
I'm not working in RH's cloud instances. I have the labs in my VMware Workstation. It should not, however, be any different as it should be using the same lab image (well... I'm using the one available from the Red Hat Academy Learning Portal and it is possible that the image they're using in their cloud is updated...)
Anyway, this is what I did (just to be complete):
edit /etc/default/grub and change GRUB_TIMEOUT=5
I then did both commands (because I didn't now how the VM was presented - is it BIOS or is it UEFI...?)
grub2-mkconfig -o /boot/grub2/grub.cfg
grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg
OK, so I just did this in the lab space made available by Red Hat to the Red Hat Academy, and it worked fine. So, on to reset the password....
...first, remove the console directives and values (console=tty0 console=ttyS0,115200n8)...
...add rd.break...
...aaaaand it asks for root password.
So RH's RHA's lab space is also broken.
Your step 4 is somewhat incorrect. I believe you need mount -o remount,rw /sysroot
Also, step 8 should be touch /.autorelabel, not echo,
2. edit the Linux16 with rd.break
This is also incorrect - for RHEL 8 and RHEL 9. The line now begins with linux
Please see this thread: https://learn.redhat.com/t5/Platform-Linux/Unable-to-reset-the-root-password-when-disabling-SELinux/...
Hi,
I'm facing issues with rhel7 while logging in after rd.break as my login screen display again to login and never log me in.
Also tried disabling SELINUX by rd.break enforcing=0 but still there is same , no improvement.
Can anyone suggest any other way to solve this
Red Hat
Learning Community
A collaborative learning environment, enabling open source skill development.