![]() |
|
Xen hypervisor on Rock64 - Printable Version +- PINE64 (https://forum.pine64.org) +-- Forum: ROCK64 (https://forum.pine64.org/forumdisplay.php?fid=85) +--- Forum: Linux on Rock64 (https://forum.pine64.org/forumdisplay.php?fid=88) +--- Thread: Xen hypervisor on Rock64 (/showthread.php?tid=6059) |
Xen hypervisor on Rock64 - tumbleweed - 05-13-2018 Hello, I'm trying to install the Xen hypervisor on rock64, starting with the info at Xen ARM with Virtualization. Here are the steps I followed so far:
Anyone have suggestions on what I might try next to get past this hanging problem? Code: label kernel-xenRE: Xen hypervisor on Rock64 - evilbunny - 05-13-2018 (05-13-2018, 09:03 PM)tumbleweed Wrote: Anyone have suggestions on what I might try next to get past this hanging problem?I haven't tried xen on arm, but there are builds for docker and kubernetes, are these an option for you? RE: Xen hypervisor on Rock64 - tumbleweed - 05-15-2018 (05-13-2018, 11:40 PM)evilbunny Wrote:(05-13-2018, 09:03 PM)tumbleweed Wrote: Anyone have suggestions on what I might try next to get past this hanging problem?I haven't tried xen on arm, but there are builds for docker and kubernetes, are these an option for you? Thanks for the reply. The goal is to run a unikernel under the xen hypervisor. Similar to running containers, but not the same. Is there another forum you’d suggest for posting this question? RE: Xen hypervisor on Rock64 - sstabellini - 05-17-2018 Hi Tumbleweed,I haven\'t tried Xen on Rock64, but I did run Xen on Pine64 successfully in the past.The mkimage step below is only required if you boot Xen from U-Boot. If you boot Xen from extlinux or another bootloader, it will actually cause troubles. Instead, to simplify the boot sequence, I would boot Xen directly from EFI, skipping extlinux completely. To do that, you need to copy xen.efi to the FAT partition, and write a xen.cfg config file. You also need to copy the Dom0 kernel, initrd and device tree to the fat partition. For instance, see this guide for booting Xen on ARM on QEMU:https://wiki.xenproject.org/wiki/Xen_ARM_with_Virtualization_Extensions/qemu-system-aarch64There are a few QEMU specific steps in there, but it also contains the steps to boot Xen directly from UEFI including an example xen.cfg.It might also be possible to boot Xen from extlinux but I don't have experience with that. I recommend booting from UEFI first. Cheers,Stefano (05-13-2018, 09:03 PM)tumbleweed Wrote: Hello, RE: Xen hypervisor on Rock64 - tumbleweed - 05-19-2018 Hi sstabellini, thanks for the suggestions. I tried to setup direct UEFI boot without success. (Basically I started with the QEMU instructions and created /boot/efi/EFI/xen/ with xen.efi , xen.cfg and so forth. ) It appears that EFI booting is skipped altogether, and for example: Code: rock64@rock64:~$ efibootmgr -w -L Xen -l "\EFI\Xen\xen.efi" -cLooking at the Rockchip boot options diagram, it appears that either u-boot.bin or UEFI.FD is run as "Loader 2" , only for "Boot Flow 1". Looking at the serial console output below, it seems to me the Rock64 is following "Boot Flow 2", which uses u-boot, since we see "BL31" running. The serial console output at reboot, if I read it correctly, shows the system directly booting into u-boot. How can I ensure the Rock64 chooses UEFI boot? Code: => resetQuote:sstabelliniHi Tumbleweed,I haven\'t tried Xen on Rock64, but I did run Xen on Pine64 successfully in the past.The mkimage step below is only required if you boot Xen from U-Boot. If you boot Xen from extlinux or another bootloader, it will actually cause troubles. Instead, to simplify the boot sequence, I would boot Xen directly from EFI, skipping extlinux completely. To do that, you need to copy xen.efi to the FAT partition, and write a xen.cfg config file. You also need to copy the Dom0 kernel, initrd and device tree to the fat partition. For instance, see this guide for booting Xen on ARM on QEMU: https://wiki.xenproject.org/wiki/Xen_ARM_with_Virtualization_Extensions/qemu-system-aarch64 There are a few QEMU specific steps in there, but it also contains the steps to boot Xen directly from UEFI including an example xen.cfg.It might also be possible to boot Xen from extlinux but I don't have experience with that. I recommend booting from UEFI first. Cheers,Stefano RE: Xen hypervisor on Rock64 - tumbleweed - 05-23-2018 I was able to get a bit further with loading with the EFI approach. First I flashed u-boot onto SPI flash. Then I loaded the xen.efi onto a micro sd card (as bootaa64.efi), stopped the uboot autoboot, and attempted to manually boot using efi. This yields the errors shown below -- Any suggestions? Code: Hit any key to stop autoboot: 0 For reference, here's what's on the sd card: Code: => ls mmc 1:6RE: Xen hypervisor on Rock64 - darkfader - 11-03-2025 Hey, I know this is an old post but I think the problem is common enough and hard enough to figure. So when you see this scenario - Xen kernel starting and then just "Starting kernel" with regards to Linux, or not even see the Xen kernel starting. I went through that last week with a Cubietruck. It almost always means no more than your output is going to a different or misconfigured or non-existent console. It does almost never mean there was a failure to execute your kernel. In my case, I had to _remove_ the whole set of definitions like dtuart, console=dtuart, earlycons et ceterea. EVERYTHING. just no special setting for Xen, load the correct DTB of course, and for Linux kernel, plain and simple console=hvc0. From that moment on, I had Xen boot output on serial, then Linux kernel boot output on serial, then Linux console on serial. There was other issues, mostly Xen vs Kernel vs. xl toolstack mismatches A non-Xen enabled kernel (alpine-lts iirc) and a few more stupid mishaps. But the main and most common issue was simply that I could not find any indication it was booting when in fact it was booting (and then failed of course), and that the serial console setup didn't work in the "oh lets do it super perfectly addressing the device from dt" way or any other, but worked perfectly in the default which i had never tried since all instructions very specific about giving a device tree address. Just try not doing that and see how it goes. There's also reports that some DTB's have pins inverted and stuff like that, I tried reversing tx+rx cables, nope. The failing setup is more complex than that, but there's no reason (unless you do it commercially) to look into that when you can just not specify it and be done with it. Best, Flo |