Resetting Linux Root Password with TransIP / VPS on Ubuntu

Option 1 – Using bootloader

Use this guide: . In my case this did not work.

Option 2 – Using SystemRescueCD

It might be that your VPS has a Linux Recovery Mode (not rescue mode) using a SystemRescueCD. If so, use this guide:

In my case the /dev/vda5 was not mountable, because it was password encrypted. That was why I had to use these commands:

In summary it went like:

$ fdisk -l
$ mkdir /mnt/system
$ mount /dev/vda5 /mnt/system
# /dev/vda5 is the main Linux partition
mount: unknown filesystem type 'crypto_LUKS'
# I received an error that this partition is encrpted, so the I used:
$ cryptsetup open /dev/vda5 newRoot
$ modprobe dm-mod
$ vgchange -ay
$ lvscan
# hopefully the root is displayed now. Mount this one
mount /dev/xx/yy /mnt/system
chroot /mnt/system
# Enter your new root password

Then I was able to reset my password, by entering passwd.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top