Troubleshoot Azure Linux virtual machine boot errors
Applies to: ✔️ Linux VMs
This article consolidates the most common Linux operating system boot errors you may receive when you start a Linux virtual machine (VM) in Microsoft Azure.
Boot errors and solutions
To recover a Linux VM that's unable to boot due to GRUB issues, see Linux virtual machine boots to GRUB rescue.
To troubleshoot a UEFI (Gen2) Linux VM that's unable to load the Linux image, see Troubleshoot UEFI boot failures in Azure Linux virtual machines.
To troubleshoot a Linux VM that lands into the dracut emergency shell, see Azure Linux virtual machine fails to boot and enters dracut emergency shell.
To recover a Linux VM that fails to boot due to VFAT file system disabled, see Azure Linux virtual machine fails to boot after VFAT file system type is disabled.
To troubleshoot a Linux VM that's unable to boot due to file system corruption issues, see Troubleshoot Linux virtual machine boot issues due to filesystem errors.
To fix Linux VM boot issues due to
/etc/fstab
misconfigurations or data file system issues, see Troubleshoot Linux VM boot issues due to fstab errors.To recover a Linux VM that fails to boot with a kernel panic "Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)" due to missing initramfs after a recent patching activity, see Regenerate missing initramfs.
To troubleshoot a Linux VM that fails to boot due to related Linux kernel issues, see Scenario 1: Kernel panic occurs at boot time, and Azure Linux virtual machine fails to boot after applying kernel changes.
To troubleshoot a Linux VM that fails to boot due to Hyper-V driver issues, see Troubleshoot Linux virtual machine boot and network issues due to Hyper-V driver-associated errors.
To recover a Linux VM that fails to start due to root file system full issues, see Troubleshoot Azure Linux virtual machine boot issues due to full OS disk.
Tools to recover Linux VM from no boot scenarios
-
With the Azure Serial Console, you could recover several no boot scenarios, for example:
-
With this tool, you can create a repair VM and attach a copy of the OS disk to it. This copy can be modified to fix no boot scenarios from a chroot environment. For more information, see using chroot to recover from no boot scenarios offline. When you execute commands in a chroot environment, they're executed against the attached OS Disk and not the local rescue/repair VM.
Note
Alternatively, you can create a rescue VM manually by using the Azure portal. For more information, see Troubleshoot a Linux VM by attaching the OS disk to a recovery VM using the Azure portal.
Azure VM repair commands and ALAR2 scripts
Azure Linux Auto Repair (ALAR) is part of the VM repair extension that's described in Repair a Linux VM by using the Azure Virtual Machine repair commands. These scripts simplify the recovery process and enable even inexperienced users to recover their Linux VM easily.
-
If you have an existing VM but you want to swap the disk for a backup disk or another OS disk, you can use the Azure CLI to swap the OS disks. You don't have to delete and recreate the VM. You can even use a managed disk in another resource group as long as it isn't already in use. This tool is used by the Azure VM repair commands to exchange the OS disk of the VMs.
Contact us for help
If you have questions or need help, create a support request, or ask Azure community support. You can also submit product feedback to Azure feedback community.