AzureLinux

From Piszczynski

Linux VMs in Azure

Unable to access serial console while booting

In Azure console output is sent to the log diagnostics console rather than the serial console when booting. This can cause issues as you cannot send commands to the console screen to manage any boot options the VM may be requesting.

To fix this you will need to access the GRUB boot menu. Select the recovery option and press "e"

Change the following:

linux /boot/vmlinuz-4.15.0-1023-azure root=UUID=21b294f1-25bd-4265-9c4e-d6e4aeb57e97 ro recovery nomodeset

change to

linux /boot/vmlinuz-4.15.0-1023-azure root=UUID=21b294f1-25bd-4265-9c4e-d6e4aeb57e97 ro recovery console=ttyS0

this will enable the console output to be sent to the serial console rather than the boot diagnostics

The same option can be used on the standard boot option - just remove the "recovery" command before "console=ttyS0"