qemu boot from USB external disk in an x86_64 Linux system

Hello everyone!

First post, thank you devs for all your work.

I hear, from this post here in the forum:

https://dietpi.com/forum/t/acpi-shutdown-does-nothing/3340/1

it can be done.

Can anyone share their experiences in this?

Perhaps the posters from that thread? ingenium and / or hd888 ?

Note, I am writing this post with not much information because, currently I am at my phone’s interface. I intend to post more details in a while.

Thanks beforehand!

Hi again (finally :frowning: )

Here’s the additional information that may be useful,

I am on an up-to-date archlinux distro.

uname -a
Linux (machine name) 5.13.7-arch1-1 #1 SMP PREEMPT Sat, 31 Jul 2021 13:18:52 +0000 x86_64 GNU/Linux

The purpose of this is to be able to migrate the data from a Nextcloud Server laying inside the dietpi to a docker container inside my only raspberry pi 4b that would be running a libreelec kodi distro. Since I have only one raspberry pi 4b (4GiBi of RAM) and because I would like to perform the migration between running machines, I suppose this would be the only way…

I intend to do it like this because I barely used qemu-kvm and I am looking forward to learn something from it.

I hope that there is someone that can shed some light into my obscured mind, and that’s about it for now…

See you soon, cheers!

I’m not 100% sure what you are trying to do. What kind of data you have on this HDD?

Hello Joulinar , thank you for your answer.

I am trying to migrate the nextcloud server from a dietpi raspberry pi 4b hardware onto a libreelec kodi peppered up with docker nextcloud + mysql (mariadb) containers.

Since I own only one Rasbperry Pi 4b I was trying to do this with the target system (libreelec) running on the Raspberry pi hardware. While the source system would be up inside a virtual machine. I thought this machine could be a qemu (kvm?) one managed for instance with virt-manager front-end.

That was the initial plan to do it. And do note that I was intending to do it without having to ‘image’ any of the disks. But I think that this is not possible or advisable (I mean, to make qemu boot from the physical disk itself), :thinking:

I’ve seen that some dietpi fellow users (see above) managed to ‘qemu’ dietpi for raspberry pi. So I was interested in doing the same for one of the distros, either dietpi or libreelec, while the other one libreelec or dietpi (conversely), would be standing online in the rpi to be able to flight data from one setup to the other.

Untlil now I mirrored libreelec onto a disk image and tried to boot it with qemu-kvm libvirt virt-manager front-end. I got stuck at the virtual machine uefi interface, where it sits waiting for some other file. And there my “expertise” :slight_smile: goes to shambles. I don’t know how to surpass this step to be able to boot libreelec from then on.

Joulinar do you understand my doubts now?

I appreciate any help.

Thank you, and hopefully I’ll ‘hear’ from you sooner or later.

Until then Cheers!

I understood, but wich data you have located on your HDD at the moment?

Hello again Joulinar ,

Thank you for your answers.

I have:

  1. External SSD with dietpi system

  2. (Another) External SSD with libreelec mirrored to a raw disk image.

  3. This raw disk image is the one I’m trying to boot with qemu in an Arch Linux distro.

All disk systems are bootable with the exception of the raw disk image that I’m failing yet to understand how to properly boot inside qemu. Up until now I only managed to get into an UEFI interface and corresponding shell at the qemu system image…

What’s intriguing me for the moment is the boot procedure and how should I go about it:

Which “file” do I feed the UEFI interface for it to boot libreelec distro? Do I need boot parameters for it? Which, how?

Thank you beforehand!

See you sooner or later hopefully!

Cheers!

maybe this forum post could help you to get an RPI image running on QEMU https://dietpi.com/forum/t/emulate-rpi-with-qemu-fails/4503/3

Hi Joulinar !

Thank you.

I’ll follow the link you’ve posted.

Cheers!

See you in a while!