Friday 6 March 2020

Using qemu to run or test a Linux Mint ISO (or USB)

I grabbed a Linux Mint ISO from here: https://www.linuxmint.com/download.php

and ripped it to USB following instructions here: https://www.linux.com/tutorials/how-burn-iso-usb-drive/

However, the qemu step didn't work for me. I got excellent help from irc://irc.freenode.net/##linux (user "][_R_][" in particular).

Step 1, use the right tool:
qemu-system-x86_64 (the guide says just 'qemu')

Step 2, debug this weird 'kernel panic':
The key phrase (for google) being:
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
Turns out this is VERY simple (for a 1337 expert) to fix. It's just an issue of not allocating enough memory to the VM!

The fix is:
qemu-system-x86_64 -cdrom linuxmint-19.3-xfce-64bit.iso -m 2G

To make things run good you can also say:
sudo qemu-system-x86_64 -cdrom linuxmint-19.3-xfce-64bit.iso -m 6G -enable-kvm -cpu host


No comments: