Clover efi vhdx5/4/2023 – add avx2 to the CPU flags list (MY_OPTIONS variable) – increase the RAM from 4096MB to 8192MB (ALLOCATED_RAM variable) Edit the OpenCore-Boot.sh script and make the following changes:.Create a virtual HDD image where macOS will be qemu-img create -f qcow2 mac_hdd_ng.img 128G.Convert the downloaded BaseSystem.dmg file into the BaseSystem.img dmg2img -i BaseSystem.dmg BaseSystem.img.“Install” OSX in the VM using sudo echo 1 | sudo tee sudo cp kvm.conf sudo groupadd sudo groupadd sudo groupadd sudo usermod -aG kvm sudo usermod -aG libvirt sudo usermod -aG input cd git clone –depth 1 –recursive cd pwd.Iptables -t nat -A PREROUTING -p tcp –dport 5905 -j DNAT –to-destination 10.0.2.100:5900 Iptables -A INPUT -p tcp –dport 5905 -j ACCEPT Iptables -t nat -A PREROUTING -p tcp –dport 2222 -j DNAT –to-destination 10.0.2.100:22 Iptables -A INPUT -p tcp –dport 2222 -j ACCEPT # On the QEMU hypervisor (Linux) host, configure the rules for the ports to be forwarded to the OSX VM: Iptables -I FORWARD 1 -o vde0 -m state –state RELATED,ESTABLISHED -j ACCEPT Iptables -t nat -A POSTROUTING -o wlp5s0 -j MASQUERADE # Internet access to the VMs (execute on the QEMU hypervisor host) where wlp5s0 is the WAN NIC on the Ubuntu QEMU host: # NOTE: it is possible to setup DHCP on the switch but I will be using static IPs in this guide also add an IP address to the switch as it will be the gateway for connected VMs:Įcho 1 > /proc/sys/net/ipv4/conf/vde0/proxy_arp # create a VDE switch and add a subnet range to it. I have put all the networking and firewall rules in a script which can then be executed with a command such as “sudo cat /home/itababa/setup_firewall.sh Setup networking so that the VM has network access:. To confirm you are using the right qemu, run “which qemu-system-x86_64” We will use the much newer version we compiled earlier which we installed in /usr/local/bin/ whereas the one installed by the apt command puts qemu in /usr/bin/. We won’t use the qemu version 6.x installed above. NOTE: this is to make networking config easy.
0 Comments
Leave a Reply. |