In this article, we will learn how to recover the password of the root user account on the Debian 8 operating system.
- you should have a Cloud VPS, Pure Performance VPS or a dedicated server installed with Debian 8
- you should have access to the Snel.com client area to open the KVM console
Recovery of root password
1. Log into the KVM console
In order to change the root password you will need to log into the KVM console, depending on which server type you are using the methods may differ.
If you are using Cloud VPS please refer to this article
If you are using a dedicated server with iDRAC please refer to this article
If you are using a Supermicro servers please refer to this article
For VPS users navigate to under the VPS service details page, from there you can click Console, this will open the KVM console on a new browser.
2. Reboot the machine
While you have your KVM console open, reboot the server to get the GRUB menu.
Dedicated server users will have to open Server Power Control
right after that click reboot to restart your server.
VPS users: Open the service details page of the VPS and click on the reboot button
Note: After rebooting your server quickly go to the KVM console as GRUB menu waits only a few seconds before booting OS.
3. Modify boot parameters
After rebooting the VM quickly switch to KVM console and keep pressing the ESC.
You will need to do this very quickly to get the GRUB menu.
Note: If you missed the grub screen, go ahead and reboot your server again.
In GRUB menu, press E to edit the GRUB parameters
In GRUB edit mode, find the line which starts with linux /boot/ , next you will need to navigate to the end which should show ro quiet , add a space and type the following:
it should look like this:
linux /boot/vmlinuz-3.16.0-6-amd64 root=UUID=08e369b4-8967-471b-b80c-3b09618af121 ro quiet init=/bin/bash
Once done, press CTRL + X or F10 to boot in single-user mode.
4. Reset password
Next you will need to change the acces right from read-only to read-write, to do so type the following command:
mount -o remount, rw /
Now we can change the root password, run the following command to change your password:
to change your password.
After that you can reboot the server with the following command:
In this tutorial we have shown how to recover the root password for Debian 8.