How to Repair a System That Won't Boot Using the Ubuntu 22.04 Rescue ISO
Overview
If your VPS is stuck on the boot screen, experiencing a kernel panic, or failing to reach the login prompt, you can use the Ubuntu 22.04 rescue ISO to diagnose and repair the issue. This guide walks you through booting into the rescue environment, identifying your partitions, and running filesystem repair tools.
Prerequisites
- Access to the DartNode control panel for your VPS
- The Ubuntu 22.04 Server rescue ISO (available in the DartNode ISO library)
Step 1: Mount the Rescue ISO and Boot
- Log into the DartNode control panel and navigate to your VPS.
- Go to Settings → ISO Images (or the equivalent ISO mount option for your VPS).
- Select Ubuntu 22.04 Server from the available ISOs and mount it.
- Reboot the VPS. It will boot from the ISO instead of the local disk.
- When the installer loads, choose Help or press the key combination to open an interactive shell. You should see a prompt like:
Installer shell session activated.
root@ubuntu-server:/#Note: This is an ephemeral environment. Changes to the rescue environment itself will not survive a reboot. Your VPS disk is accessible but not mounted by default.
Step 2: Identify Your Partitions
Run lsblk to list all disks and partitions:
lsblkA typical DartNode VPS partition layout looks like this:
| Device | Size | Purpose |
|---|---|---|
/dev/sda1 | ~99.9G | Root filesystem (your OS and data) |
/dev/sda14 | 4M | BIOS boot partition |
/dev/sda15 | 106M | EFI system partition |
Your root partition is almost always /dev/sda1. The loop and sr devices are part of the rescue ISO itself — you can ignore them.
Step 3: Confirm the Filesystem Type
Run blkid on your root partition to verify the filesystem type:
blkid /dev/sda1You should see output similar to:
/dev/sda1: LABEL="cloudimg-rootfs" UUID="..." BLOCK_SIZE="4096" TYPE="ext4" PARTUUID="..."Most DartNode images use ext4. Take note of the TYPE value — you'll need it in the next step.
Step 4: Run Filesystem Repair
Make sure the partition is not mounted before proceeding. If lsblk shows no mountpoint next to /dev/sda1, you're good to go.
For ext4 Filesystems (Most Common)
e2fsck -yf /dev/sda1-y— Automatically answer "yes" to all repair prompts.-f— Force a full check even if the filesystem appears clean.
The tool will scan the filesystem and report any repairs it makes, such as fixing orphaned inodes, clearing invalid blocks, or reconnecting lost files. Depending on the disk size and severity of corruption, this can take anywhere from a few seconds to several minutes.
For XFS Filesystems
xfs_repair /dev/sda1Important: Never run
xfs_repairon a mounted filesystem. Unlikee2fsck,xfs_repairdoes not have a-yflag — it runs non-interactively by default.
Step 5: Verify the Repair
After the repair completes, mount the partition and confirm your filesystem is intact:
mount /dev/sda1 /mnt
ls /mntYou should see a standard Linux root directory structure (bin, etc, home, usr, var, etc.). If the directory listing looks normal, the filesystem repair was successful.
Check for Additional Issues
While the filesystem is mounted, check for common boot-hang causes:
# Check if the disk was full (a full root partition can prevent boot)
df -h /mnt
# Review the last system logs before the failure
cat /mnt/var/log/syslog | tail -200If the disk was at or near 100% capacity, clear space from safe locations:
# Clear old logs
rm -f /mnt/var/log/*.gz
journalctl --root=/mnt --vacuum-size=50M
# Clear package cache
rm -rf /mnt/var/cache/apt/archives/*.deb
# Clear temporary files
rm -rf /mnt/tmp/*Step 6: Unmount, Remove the ISO, and Reboot
Once repairs are complete:
umount /mnt- Return to the DartNode control panel.
- Go to Settings → ISO Images and unmount the rescue ISO.
- Reboot the VPS.
Your VPS should now boot normally from the repaired local disk.
Advanced: Reinstalling GRUB
If the filesystem repair succeeds but the VPS still won't boot, the GRUB bootloader may be damaged. To reinstall it from the rescue environment:
# Mount the root filesystem
mount /dev/sda1 /mnt
# Mount required virtual filesystems
mount --bind /dev /mnt/dev
mount --bind /proc /mnt/proc
mount --bind /sys /mnt/sys
# If your VPS uses UEFI (sda15 exists)
mount /dev/sda15 /mnt/boot/efi
# Enter the installed system
chroot /mnt
# Reinstall and update GRUB
grub-install /dev/sda
update-grub
# Exit and clean up
exit
umount /mnt/boot/efi # if mounted
umount /mnt/dev
umount /mnt/proc
umount /mnt/sys
umount /mntThen unmount the ISO from the control panel and reboot.
Advanced: Reverting a Bad Kernel Update
If the VPS stopped booting after a system update, a broken kernel may be the cause. You can roll back to a previous kernel from the rescue environment:
mount /dev/sda1 /mnt
mount --bind /dev /mnt/dev
mount --bind /proc /mnt/proc
mount --bind /sys /mnt/sys
chroot /mnt
# List installed kernels
dpkg --list | grep linux-image
# Remove the problematic kernel (replace version as needed)
apt remove linux-image-X.X.X-XX-generic
# Regenerate GRUB configuration
update-grub
exit
umount /mnt/dev /mnt/proc /mnt/sys
umount /mntTroubleshooting
| Symptom | Possible Cause | Solution |
|---|---|---|
e2fsck reports severe corruption or fails | Disk hardware failure or image corruption | Contact DartNode support; the underlying storage may need attention |
Filesystem mounts but /mnt is empty | Wrong partition or filesystem was wiped | Verify with blkid; check other partitions if present |
| VPS boots but drops to emergency shell | Broken /etc/fstab entry | Mount from rescue ISO and review /mnt/etc/fstab for invalid entries |
| VPS hangs at "Started GRUB" | GRUB configuration is broken | Reinstall GRUB using the advanced steps above |
| Disk is 100% full | Runaway logs or unmanaged disk growth | Clear space from /var/log, /tmp, and package caches |
Need Help?
If the steps above don't resolve your issue, open a support ticket at support.dartnode.com and include:
- Your VPS hostname or ID
- The output of
lsblk,blkid, and anye2fsckorxfs_repairresults - A description of what happens when you attempt to boot normally
Our team is available 24/7 to assist with recovery.