So what is the correct procedure to break into a system in the RHCSA testing environment so you can change the root password? I think have one more chance to take the test and I don't want to be caught with this again.
Hi, @Tracy_Baker suggests this
https://learn.redhat.com/t5/Platform-Linux/Reset-forgotten-root-password-in-RHEL9/m-p/34115#M1884
It applies to messed /etc/fstab too.
I'd like to add that instead of its 5th point ( touch /.autorelabel ), I rather use /usr/sbin/load_policy -i and then /usr/sbin/restorecon -vvRF /etc ( or whatever dir you made changes into ), it is way faster ; then, remount / readonly and then pull the plug
PATH is unset, so you have to call commands using absolute path
my 2 c
Hi, @Tracy_Baker suggests this
https://learn.redhat.com/t5/Platform-Linux/Reset-forgotten-root-password-in-RHEL9/m-p/34115#M1884
It applies to messed /etc/fstab too.
I'd like to add that instead of its 5th point ( touch /.autorelabel ), I rather use /usr/sbin/load_policy -i and then /usr/sbin/restorecon -vvRF /etc ( or whatever dir you made changes into ), it is way faster ; then, remount / readonly and then pull the plug
PATH is unset, so you have to call commands using absolute path
my 2 c
(sorry my mistake)
Thank you for the link and for the extra information.
I installed 9.0 onto my laptop and have tested the solution in the link. It looks like adding rw in front of init=/bin/bash on the kernel line will work too as opposed to doing the mount -o rw,remount / at the bash-5.1# prompt.
Do you know if there is anything listing the other differences specific to 9.0? I can’t find anything online that specifically says, “here’s a list of things that work in other RHEL releases, but do not work in 9.0”. Or something like that.
Hi @jeffdoug1, in RHEL v9.1 and 9.2 and 9.3 versions, you can apply "rd.break" to any line in the grub menu. But for v9.0 only, you must select the second line with the word "rescue" to be able to apply "rd.break", however if you accidentally select the first line (without the word "rescue"), you must apply the solution @Tracy_Baker described, @TheIF above mentioned that solution in the link.
I have experienced all 4 RHEL versions from 9.0 to 9.3 by downloading qcow2 and also iso.
Red Hat
Learning Community
A collaborative learning environment, enabling open source skill development.