Virtualizor

Recover a broken VPS with rescue mode or an ISO in Virtualizor

Boot your VPS into Virtualizor rescue mode or a rescue ISO, mount the disk, fix fstab, reset passwords, repair the file system and copy data off a server that will not boot.

AdvancedVirtualizor VPS3 min read

When a VPS will not boot – after a bad kernel update, a wrong /etc/fstab entry or file system damage – rescue mode lets you start a small separate Linux system and work on your server's disk from outside. Virtualizor offers this as Rescue Mode on many setups, or you can boot a rescue ISO on KVM.

Before you start

  • Access to the Virtualizor panel and the VNC console.
  • Basic Linux command-line skills: mounting disks, editing files with nano.
  • If your data is critical and you are unsure, contact support before making changes.

Enable rescue mode

  1. Log in to Virtualizor and open your VPS.
  2. Click Rescue Mode (sometimes under Settings or a lifebuoy icon).
  3. Set a temporary root password for the rescue system.
  4. Click Enable Rescue. The VPS restarts into the rescue system.
  5. Connect over SSH to the VPS IP with user root and the rescue password, or use VNC.

Alternative: boot a rescue ISO (KVM)

If rescue mode is not offered, go to the VPS Settings, mount an ISO such as SystemRescue or a distribution's live image from the ISO list, set the Boot Order to CD-ROM first, and restart. Work in the VNC console.

Find and mount your disk

  1. List disks: lsblk -f. Your VPS disk is usually /dev/vda or /dev/sda with partitions like vda1.
  2. Mount the root partition: mount /dev/vda1 /mnt (use the partition with your OS). For LVM, run vgchange -ay first and mount the logical volume.
  3. Check: ls /mnt/etc should show your server's configuration.

Common repairs

  • File system errors: unmount first (umount /mnt), then run fsck -y /dev/vda1 for ext4 or xfs_repair /dev/vda1 for XFS.
  • Bad fstab entry: edit /mnt/etc/fstab and comment out the wrong line with #, or add nofail to optional disks.
  • Forgotten root password: chroot into the system and set a new one:
mount --bind /dev /mnt/dev && mount --bind /proc /mnt/proc && mount --bind /sys /mnt/sys && chroot /mnt passwd root
  • Firewall locked you out: disable it in the chroot, for example systemctl disable ufw or systemctl disable firewalld.
  • Broken kernel update: in the chroot, reinstall the kernel package or regenerate GRUB (update-grub or grub2-mkconfig -o /boot/grub2/grub.cfg).

Copy data off the server

If the system cannot be repaired, copy what you need before reinstalling:

rsync -avz /mnt/var/www/ user@backup-server:/backups/www/

Also copy database files (/mnt/var/lib/mysql) – ideally restore them on a server with the same MySQL or MariaDB version.

Leave rescue mode

  1. Exit any chroot and unmount: umount -R /mnt.
  2. In Virtualizor, click Disable Rescue (or unmount the ISO and set boot order back to Hard Disk).
  3. Restart the VPS and watch the boot in VNC.

Troubleshooting

  • SSH warns about a changed host key: expected in rescue mode; remove the old key with ssh-keygen -R ip.
  • Disk not visible: the rescue kernel lacks a driver; try another rescue ISO.
  • Still boots into rescue: rescue mode or the ISO boot order is still enabled.

Next steps

Was this guide helpful?

Still stuck?

Ask MdmHost AI for a quick answer, or open a ticket and our team will take a look. We are here 24/7.