To confirm,I tried this tonight WITHOUT using UTM, only Apple. I used some swift from an Apple sample project that used VZEFIBootLoader() & another sample with the serial console window.
Correct, it's a serial console in window using https://github.com/migueldeicaza/TermKit to deal with ANSI. Using Swift without UTM, the VGA display is blank – same as UTM.To confirm,I tried this tonight WITHOUT using UTM, only Apple. I used some swift from an Apple sample project that used VZEFIBootLoader() & another sample with the serial console window.
This window is not the VGA graphics from the CHR VM, but a SwiftUI window connecting to the serial port of the CHR?
Yup. Apparently, the specific are Rosetta will help with any X86's running inside Apple Virtualized machine – the actual Linux disto needs to also be same arm. So "Ampere" support is needed. Actually looked it up: https://developer.apple.com/documentati ... th_rosettaDid a try on mac arm and it doesn't work for me.
[...]
Probably AMPERE (coming soon) may solve that?
Rosetta doesn’t support the bootstrapping or installation of Intel Linux distributions on Mac computers with Apple silicon using the Virtualization framework. Intel Linux distributions can run using the Virtualization framework on Intel-based Mac computers without the need for this translation capability.
Totally @kriszos - it was worth a search for UEFI in the forum.... but I would have never got to the partition scheme in the RAW image was the reason EFI didn't work & given up before trying gdiskI am glad that my work help you resolve your problem.
But tried.We checked our suggestion list, and you are the only person who asked about Apple Hypervisor.
We noted it, but it is not a big chance that it will be implemented soon.
SUP-145276Should more of us file support/feature requests for generic UEFI support in CHR?
So still QEMU on M1/M2/... but "UEFI boot" for CHR should be selectable in other hypervisors using these images I think.Rosetta doesn’t support the bootstrapping or installation of Intel Linux distributions on Mac computers with Apple silicon using the Virtualization framework. Intel Linux distributions can run using the Virtualization framework on Intel-based Mac computers without the need for this translation capability.
I tried on Equinox Metal, but couldn't get it work. I do not think it's Mikrotik fault... Metal uses iPXE with netboot.xyz for custom OSes. I use VMWare on X86... so I gave up quick since I don't know iPXE stuff (although similar problem as here – what's the kernel & initfs to use for RouterOS ). But kinda did want to see it boot on something before spelunking on ARM Mac. But no success on Metal.I'm excited to see what people come up with now that the Ampere ISO is out. I tried messing around with it but I can't get things to boot.
Thanks for sharing your scripts. Some working examples always help.I was able to boot Ampere/ARM64 ISO on Qemu with KVM acceleration: https://github.com/ayufan-research/mikrotik-qemu-arm64. Works just fine. Tested on Raspberry PI 5 and Rock 5B.
... qemu-system-aarch64 ...
-vga none -nographic -monitor none
-serial chardev:term0 -chardev stdio,id=term0
I have a Studio and MacBook Pro. You've given me a couple ideas to try. There is an efiboot.img on the ISO. It also has all the packages on the ISO. Kernel boots on Apple and on QEMU but doesn't know where init is.I tried on Equinox Metal, but couldn't get it work. I do not think it's Mikrotik fault... Metal uses iPXE with netboot.xyz for custom OSes. I use VMWare on X86... so I gave up quick since I don't know iPXE stuff (although similar problem as here – what's the kernel & initfs to use for RouterOS ). But kinda did want to see it boot on something before spelunking on ARM Mac. But no success on Metal.I'm excited to see what people come up with now that the Ampere ISO is out. I tried messing around with it but I can't get things to boot.
I don't have an ARM Mac handy, but next time I can check I'll see what happens. At the end of the day, Apple Virtualization needs some EFI executable file and a ramdisk with RouterOS file system (e.g. routeros.npk uncompressed AFAIK) — just how it find/pick them may be tricky align.
I'm not expect here, but re-packaging I can do. I added ZIP file output to my GitHub "X86 UEFI CHR builder", while it doesn't have symlinks and stuff. If you extract the ZIP file, you can see how the IMG get's structured without mounting the disk on Mac (since it's cannot read the 2nd partition):I have a Studio and MacBook Pro. You've given me a couple ideas to try. There is an efiboot.img on the ISO. It also has all the packages on the ISO. Kernel boots on Apple and on QEMU but doesn't know where init is.
This is likely problem of UEFI or HVF accelerator implemented in QEMU on MacOS.I have a Studio and MacBook Pro. You've given me a couple ideas to try. There is an efiboot.img on the ISO. It also has all the packages on the ISO. Kernel boots on Apple and on QEMU but doesn't know where init is.
Just for fun, I tried the ARM64 ISO, emulated in UTM on Intel Mac — WORKED.OK. You can boot/install via UTM:
qemu-img convert -O qcow2 mikrotik-7.15beta4-arm64.iso mikrotik-7.15beta4-arm64.qcow2
The step 10. does this conversion (or rather attachment of RAW).Just for fun, I tried the ARM64 ISO, emulated in UTM on Intel Mac — WORKED.
Instructions almost just work on Intel UTM with QEMU emulation.... Clearly the NVMe disk seem required (tried IDE or VirtIO – neither worked). But for Intel UTM, the ISO image seems to need to be first converted manually to a .qcow2 with VirtIO for the 1st partition to boot before importing it.
Code: Select allqemu-img convert -O qcow2 mikrotik-7.15beta4-arm64.iso mikrotik-7.15beta4-arm64.qcow2
Yeah that may be a bug in UTM (or gremlins)... it seem to try to convert it, and then reports in dialog it cannot find mikrotik-7.15beta4-arm64.qcow. Just something I noticed. (Keep in mind, I tested on Intel Mac using emulation, so may not happen on ARM Mac)The step 10. does this conversion (or rather attachment of RAW).Code: Select allqemu-img convert -O qcow2 mikrotik-7.15beta4-arm64.iso mikrotik-7.15beta4-arm64.qcow2
Ah yes, the license scheme is different. Which also makes sense why there isn't a virtio blk driver for it either.The NVMe device is required as MikroTik requires some Serial Number to be configured to get Hardware ID. The VirtIO does not allow that.
Nice! There is hope.I'm personally running ARM64 variant on my Rock 5B now via KVM virtualization, and it achieves maximum throughput!
I'll have to try it via KVM on my SolidRun Honeycomb LX2 that's collecting dust. It doesn't support UEFI boot and their UEFI shim is out of date. Otherwise I'd have spent some more time on booting it natively.I'm personally running ARM64 variant on my Rock 5B now via KVM virtualization, and it achieves maximum throughput!
Via KVM it works just fine. No objections there, and especially a better idea for something that will rather be unsupported by MikroTik.I'll have to try it via KVM on my SolidRun Honeycomb LX2 that's collecting dust. It doesn't support UEFI boot and their UEFI shim is out of date. Otherwise I'd have spent some more time on booting it natively.I'm personally running ARM64 variant on my Rock 5B now via KVM virtualization, and it achieves maximum throughput!
Isn't there some extra-nic.npk you can install – maybe already did – just a thought.But it doesn't see any of the NICs or USB interfaces.
It does replicate QEMU where the CD-ROM had to be transformed into a disk image. IDK about modern bootloaders, but AFAIK EFI will mount the CD-ROM for an OS install to START. But when the "real" OS boot, it depends on its own driver for CD-ROM. But a physical disk (or emulated one) be same ID/etc in both EFI and RouterOS kernel.That would probably explain why the install kernel doesn't see the USB drive after it takes over from UEFI.
This be good news for Mac ARM users. I suspect if it work under Apple Virtualization on ARM Mac... it work any other KVM hypervisor using AArch64. e.g. Apple is kinda "worse case" since only supports VirtIO. KVM long offered VirtIO, but most Linux hypervisors do have other supporting functions too... but with Apple it's 100% VirtIO drivers (and clearly a limited subset of them too).CHR images are coming in next betas
Mac does not offer KVM. It does offer HVF and Virtualization framework. Qemu can support anything HVF.This be good news for Mac ARM users. I suspect if it work under Apple Virtualization on ARM Mac... it work any other KVM hypervisor using AArch64. e.g. Apple is kinda "worse case" since only supports VirtIO. KVM long offered VirtIO, but most Linux hypervisors do have other supporting functions too... but with Apple it's 100% VirtIO drivers (and clearly a limited subset of them too).
True. I just found it telling that even Apple adopted KVM's VirtIO in "HVF", not their own drivers/VMXNET3/something ... Even to the extent that "HVF" is likely a "even more pure" VirtIO-based hypervisor, than even KVMMac does not offer KVM. It does offer HVF and Virtualization framework. Qemu can support anything HVF.This be good news for Mac ARM users. I suspect if it work under Apple Virtualization on ARM Mac... it work any other KVM hypervisor using AArch64. e.g. Apple is kinda "worse case" since only supports VirtIO. KVM long offered VirtIO, but most Linux hypervisors do have other supporting functions too... but with Apple it's 100% VirtIO drivers (and clearly a limited subset of them too).
This is incorrect:True. I just found it telling that even Apple adopted KVM's VirtIO in "HVF", not their own drivers/VMXNET3/something ... Even to the extent that "HVF" is likely a "even more pure" VirtIO-based hypervisor, than even KVM
More a thought that HVF kinda useful for general VM testing.... if OS has poor VirtIO support, you'll get nothing from Apple.
If you are coming from VMWare please checkout the Proxmox VE. It is brilliant. Build on top of Debian, QEMU and KVM. And Open Source. The company behind it offers paid support.Thanks @ayufanpl. Used VMWare for decades and for a time built iOS apps. Most server/apps/OS supported VMWare, while KVM was hit/miss. Seems the reverse is happening, which is good since VMWare is now pretty expensive. While I know UNIX/Linux well enough, all the KVM/QEMU stuff I'm trying to learn. Seems complicated onion.
...
I kinda liked the generic concept of have an "/Application" that put some nice SwiftUI (perhaps NOT a terminal) around some Linux thing more generically. At some point, I'll put the "MacOS CHR" code/app on GitHub (perhaps, "AHR") when I have time. Hopefully Mikrotik will have a ARM64 CHR image by then too.
LOL. Yeah I recently just installed Proxmox VE on an old server to test it... It better from a UI POV for sure. And the disk management is just more logical too. Plus seem QEMU has come a long way since I start with VMWare in the 90s. CHR was an addition on ESXi a few years, but it super handy for dealing with all the networking stuff vSwitch can't & avoid need the even more price vSphere stuff. e.g. RouterOS VRRP on two VMWare ESXI does similar HA things to vSphere & easier, and $100/server is a bargain. On Proxmox VE, there is all Linux newer data plane stuff. Haven't gotten there yet with Proxmox VE.If you are coming from VMWare please checkout the Proxmox VE. It is brilliant. Build on top of Debian, QEMU and KVM. And Open Source. The company behind it offers paid support.
Not really. The disk images are transferable between Proxmox VE and UTM, since both are based on QEMU, both can boot UEFI, both use VirtIO for most of emulated devices. They are super similar on how they configure QEMU and interact with it. The problem with UTM is that it can run amd64 or arm64 natively depending on MacOS arch. The Proxmox VE at least now is only amd64. So, you can transfer UTM <-> PVE only when running on Intel Macs. There are some GitHub repos trying to bring PVE to arm64 with mixed degree of success.It was the Fusion to UTM part of conversion that got me here. It was nice to be able test a VMX-based VM on Mac Fusion, and just copy files to ESXi (or vise versa). But if want to do same with Proxmox, I need KVM/QEMU on Mac...
One note: @TomjNorthIdaho (who runs an open btest server from his ISP) is in same boat re VMWare. @ayufanpl, if you had any Proxmox advice, might want to share it here: viewtopic.php?t=203953&hilit=vmware
utm://downloadVM?url=https://github.com/tikoci/chr-utm/releases/download/v7.17.2/RouterOS.utm.zip
utm://downloadVM?url=https://github.com/tikoci/chr-utm/releases/download/v7.17.2/RouterOS.utm.zip