Skip to content

Instantly share code, notes, and snippets.

@tom-code
Created December 30, 2023 05:43
Show Gist options
  • Save tom-code/acc8c8aa6421a13356c3747ed20bdd83 to your computer and use it in GitHub Desktop.
Save tom-code/acc8c8aa6421a13356c3747ed20bdd83 to your computer and use it in GitHub Desktop.
openwrt in qemu
sudo qemu-system-aarch64 \
-kernel /Volumes/data/qemu/openwrt-23.05.05-armsr/openwrt-23.05.2-armsr-armv8-generic-initramfs-kernel.bin \
-drive file=/Volumes/data/qemu/openwrt-23.05.05-armsr/openwrt-23.05.2-armsr-armv8-generic-squashfs-rootfs.img.work,if=virtio,format=raw \
-append root=/dev/vda \
-cpu cortex-a57 -m 2048 -smp 2 -machine virt \
-nographic \
-device virtio-net-pci,netdev=net0 -netdev vmnet-host,id=net0,net-uuid=86d5e2de-594c-421e-be0d-8a3ac19dc207 \
-device virtio-net-pci,netdev=net1 -netdev vmnet-bridged,ifname=en0,id=net1
sudo qemu-system-x86_64 -m 1024 -hda alpine.qcow -accel hvf -device virtio-net-pci,netdev=net0,mac=52:54:00:12:34:01 -netdev vmnet-host,id=net0,net-uuid=86d5e2de-594c-421e-be0d-8a3ac19dc207
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment