cd ~/KVMimage/macos
wget https://github.com/foxlet/macOS-Simple-KVM/archive/refs/heads/master.zipunzip master.zip
python3 -m venv myenv
. ./myenv/bin/activate
pip3 install --upgrade pip
./jumpstart.sh
# dnf -y install qemu-kvm qemu-img libvirt virt-install libvirt-client
# qemu-img create -f qcow2 mac_os.qcow2 64G
# vi basic.sh
1 #!/bin/bash
2
3 OSK="ourhardworkbythesewordsguardedpleasedontsteal(c)AppleComputerInc"
4 VMDIR=$PWD
5 OVMF=$VMDIR/firmware
6 #export QEMU_AUDIO_DRV=pa
7 #QEMU_AUDIO_DRV=pa
8
9 qemu-system-x86_64 \ →/usr/libexec/qumu-kvm
10 ¦ -enable-kvm \
11 ¦ -m 2G \
12 ¦ -machine q35,accel=kvm \
13 ¦ -smp 4,cores=2 \
14 ¦ -cpu Penryn,vendor=GenuineIntel,kvm=on,+sse3,+sse4.2,+aes,+xsave,+avx,+xsaveopt,+xsavec,+xgetbv1,+avx2,+bmi2,+smep,+bmi1,+fma,+movbe,+invtsc \
15 ¦ -device isa-applesmc,osk="$OSK" \
16 ¦ -smbios type=2 \
17 ¦ -drive if=pflash,format=raw,readonly,file="$OVMF/OVMF_CODE.fd" \
18 ¦ -drive if=pflash,format=raw,file="$OVMF/OVMF_VARS-1024x768.fd" \
19 ¦ -vga qxl \
20 ¦ -device ich9-intel-hda -device hda-output \
21 ¦ -usb -device usb-kbd -device usb-mouse \
22 ¦ -netdev user,id=net0 \
23 ¦ -device e1000-82545em,netdev=net0,id=net0,mac=52:54:00:c9:18:27 \
24 ¦ -device ich9-ahci,id=sata \
25 ¦ -drive id=ESP,if=none,format=qcow2,file=ESP.qcow2 \
26 ¦ -device ide-hd,bus=sata.2,drive=ESP \
27 ¦ -drive id=InstallMedia,format=raw,if=none,file=BaseSystem.img \
28 ¦ -device ide-hd,bus=sata.3,drive=InstallMedia \
29 ¦ -drive id=SystemDisk,if=none,file=mac_os.qcow2
30 ¦ -device ide-hd,bus=sata.4,drive=SystemDisk
【参考】
https://github.com/foxlet/macOS-Simple-KVM
https://chirashi.twittospia.com/%E6%8A%80%E8%A1%93/ubuntulinux%E3%81%AE%E4%BB%AE%E6%83%B3%E3%83%9E%E3%82%B7%E3%83%B3%E3%81%ABmacos%E3%82%92%E3%82%A4%E3%83%B3%E3%82%B9%E3%83%88%E3%83%BC%E3%83%AB%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95/2021-04-20/
0 件のコメント:
コメントを投稿