Difference between revisions of "From QEMU to BigEndian FreeBSD"
Jump to navigation
Jump to search
Line 18: | Line 18: | ||
</pre> | </pre> | ||
− | Using the example of FreeBSD 14.3, | + | Using the example of FreeBSD 14.3, fbsd.raw as the destination storage device, and 2222 as the ssh port: |
<pre> | <pre> |
Revision as of 14:31, 28 June 2025
This tutorial takes the reader from the bare minimum to launch a virtual machine with QEMU to a full installation of big-endian FreeBSD.
The short version:
Download the most recent version of big-endian FreeBSD from
https://download.freebsd.org/releases/powerpc/powerpc64/ISO-IMAGES/
Create a raw disk file to be the installation destination:
# qemu-img create fbsd.raw 120G Formatting 'fbsd.raw', fmt=raw size=128849018880 # ls -sl total 924700 4 -rw-r--r-- 1 root root 128849018880 Jun 28 13:31 fbsd.raw 924696 -rw-r--r-- 1 root root 952018944 Jun 25 05:04 FreeBSD-14.3-RELEASE-powerpc-powerpc64-disc1.iso
Using the example of FreeBSD 14.3, fbsd.raw as the destination storage device, and 2222 as the ssh port:
# qemu-system-ppc64 --enable-kvm -M pseries,cap-nested-hv=true,cap-ibs=workaround -cpu host -smp cores=4,threads=4,sockets=1 -m 8G -nographic -drive file=fbsd.raw,format=raw,if=virtio,id=drive0 -drive file=FreeBSD-14.3-RELEASE-powerpc-powerpc64-disc1.iso,media=cdrom,if=virtio,id=drive1 -nic user,ipv6=off,model=e1000,mac=52:54:98:76:54:32,hostfwd=tcp::2222-:22
The long version:
https://www.qemu.org/docs/master/system/invocation.html
https://www.qemu.org/docs/master/tools/qemu-img.html
No devices added (default SLOF boot):
0 > dev / ok 0 > ls 7e644530 : / 7e644b40 : |-- ibm,persistent-memory 7e644da0 : |-- hypervisor 7e644f00 : |-- chosen 7e645310 : |-- rtas 7e646638 : |-- event-sources 7e6467f0 : | |-- hot-plug-events 7e646948 : | +-- epow-events 7e646ae8 : |-- cpus 7e646db0 : | |-- PowerPC,POWER9@0 7e6477e8 : | |-- PowerPC,POWER9@4 7e648220 : | |-- PowerPC,POWER9@8 7e648c58 : | +-- PowerPC,POWER9@c 7e649738 : |-- pci@800000020000000 7e64bd18 : | |-- vga@0 7e64c230 : | +-- usb-xhci@1 7e68f7f8 : | |-- usb-keyboard@1 7e6902b8 : | +-- usb-mouse@2 7e64c908 : |-- vdevice 7e64cb88 : | |-- vty@71000000 7e64cda8 : | |-- nvram@71000001 7e64d018 : | |-- l-lan@71000002 7e64d3e8 : | +-- v-scsi@71000003 7e673ba8 : | +-- disk 7e64d8a8 : |-- memory@0 7e64daa0 : |-- interrupt-controller 7e650be0 : |-- aliases 7e650ce8 : |-- options 7e650da8 : |-- openprom 7e650eb0 : |-- packages 7e650f78 : | |-- deblocker 7e651a18 : | |-- disk-label 7e6560b8 : | |-- fat-files 7e658830 : | |-- rom-files 7e659250 : | |-- ext2-files 7e65bcc8 : | |-- obp-tftp 7e65c098 : | +-- iso-9660 7e660ae0 : +-- mmu ok 0 >
With CDROM and hard drive:
Ready! 0 > dev / ok 0 > ls 7e644530 : / 7e644b40 : |-- ibm,persistent-memory 7e644da0 : |-- hypervisor 7e644f00 : |-- chosen 7e645310 : |-- rtas 7e646638 : |-- event-sources 7e6467f0 : | |-- hot-plug-events 7e646948 : | +-- epow-events 7e646ae8 : |-- cpus 7e646db0 : | |-- PowerPC,POWER9@0 7e6477e8 : | |-- PowerPC,POWER9@4 7e648220 : | |-- PowerPC,POWER9@8 7e648c58 : | +-- PowerPC,POWER9@c 7e649738 : |-- pci@800000020000000 7e64bd18 : | |-- vga@0 7e64c230 : | |-- usb-xhci@1 7e692660 : | | |-- usb-keyboard@1 7e693120 : | | +-- usb-mouse@2 7e64c860 : | |-- scsi@2 <-- Added device 7e64ce18 : | +-- scsi@3 <-- Added device 7e64d478 : |-- vdevice 7e64d6f8 : | |-- vty@71000000 7e64d918 : | |-- nvram@71000001 7e64db88 : | |-- l-lan@71000002 7e64df58 : | +-- v-scsi@71000003 7e674718 : | +-- disk 7e64e418 : |-- memory@0 7e64e610 : |-- interrupt-controller 7e651750 : |-- aliases 7e651858 : |-- options 7e651918 : |-- openprom 7e651a20 : |-- packages 7e651ae8 : | |-- deblocker 7e652588 : | |-- disk-label 7e656c28 : | |-- fat-files 7e6593a0 : | |-- rom-files 7e659dc0 : | |-- ext2-files 7e65c838 : | |-- obp-tftp 7e65cc08 : | +-- iso-9660 7e661650 : +-- mmu ok
With the network card:
0 > dev / ok 0 > ls 7e644530 : / 7e644b40 : |-- ibm,persistent-memory 7e644da0 : |-- hypervisor 7e644f00 : |-- chosen 7e645310 : |-- rtas 7e646638 : |-- event-sources 7e6467f0 : | |-- hot-plug-events 7e646948 : | +-- epow-events 7e646ae8 : |-- cpus 7e646db0 : | |-- PowerPC,POWER9@0 7e6477e8 : | |-- PowerPC,POWER9@4 7e648220 : | |-- PowerPC,POWER9@8 7e648c58 : | +-- PowerPC,POWER9@c 7e649738 : |-- pci@800000020000000 7e64bd18 : | |-- ethernet@0 <-- Added device 7e64c280 : | |-- vga@1 7e64c798 : | |-- usb-xhci@2 7e6933f8 : | | |-- usb-keyboard@1 7e693eb8 : | | +-- usb-mouse@2 7e64cdc8 : | |-- scsi@3 7e64d380 : | +-- scsi@4 7e64d9e0 : |-- vdevice 7e64dc60 : | |-- vty@71000000 7e64de80 : | |-- nvram@71000001 7e64e0f0 : | +-- v-scsi@71000002 7e6742b8 : | +-- disk 7e64e5b0 : |-- memory@0 7e64e7a8 : |-- interrupt-controller 7e6518e8 : |-- aliases 7e6519f0 : |-- options 7e651ab0 : |-- openprom 7e651bb8 : |-- packages 7e651c80 : | |-- deblocker 7e652720 : | |-- disk-label 7e656dc0 : | |-- fat-files 7e659538 : | |-- rom-files 7e659f58 : | |-- ext2-files 7e65c9d0 : | |-- obp-tftp 7e65cda0 : | +-- iso-9660 7e6617e8 : +-- mmu ok