0

I have "inherited" a virtual server at German hoster STRATO with Rocky Linux 8, but no root password. I wanted to change this as usual, so in grub I entered

rd.break enforcing=0

Enter rd.break enforcing=0 into grub and Ctrl+X should start Rocky Linux in emergency mode.

Unfortunately it doesn't start with it, just hangs. Is there a known problem with the KVM or is STRATO blocking something?

STRATO also has a "rescue system" that starts a Debian where I can mount the disks - but I don't know how to change the password from there. A chroot into the shell of root is possible, but a password changed there should be useless for Rocky with SELinux.

Any ideas?

Best regards

Albi

1 Answer 1

0

I've seen this question asked a few times in different places and I too have just been struggling with this. Now I can't guarantee this is the solution for all instances where this occurs, but this is what was happening for me. Thus recording it here in the hope that it helps other people, as well as a reminder to me! (also I'm aware I'm about 8 months late with your question so you're probably way past this!).

First off, I checked the Red Hat docs - Rocky is (as I understand it) meant to be bug for bug compatible, so working from this assumption the way into single user mode for Rocky 9 should be the same as RHEL 9.

There seem to be plenty of tutorials and such out there that document rd.break as the way to do this, so working on the assumption we're on the right track here - here's one such example: https://www.linuxtechi.com/boot-rhel-9-into-rescue-mode/

Now given this, it seems something else is going on. I'm not familiar with STRATO, but I am running on KVM with a SPICE display set up.

The issue on my system was that the console= line was set to ttyS0 only, and I was using the physical console. As a result I thought the VM was hanging but it actually wasn't - the VM was doing what it had been configured to do, which was use ttyS0 as the primary (and only) terminal.

I appended rd.break console=tty0 to the linux line, and suddenly I was in my single user environment, and proceeded to perform all the usual steps.

Hope this helps someone out there!

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.