Run Fedora 12 for PowerPC on Intel x86 with qemu-system-ppc


====Why is it so hard to find examples?====
It’s almost impossible to find functional examples of how to run qemu-system-ppc without a kernel panic, core dump, or ending up in bios limbo. So here’s one way I came up with that works for me. This assumes I have already created the qcow virtual hard drive named vm-hd-ppc.img and obtained a copy of the kernel and initrd. Without these, you need a yaboot.conf which is similar to grub.conf.

qemu-system-ppc -cdrom Fedora-12-ppc.iso -hda vm-hd-ppc.img -m 512 -net nic,model=pcnet,macaddr=00:11:DE:AD:BE:EF -net tap,ifname=tap0,script=/etc/qemu-ifup -boot d -vnc :1 -vga none -kernel vmlinuz.ppc.fc12 -append “root=CDLABEL=Fedora-12-Live-ppc rootfstype=iso9660 ro liveimg 3″ -initrd initrd.img

You’ve probably found an endless supply of URLs where people complain that they can’t get anything to boot with qemu-system-ppc and many supposed guides to follow that work. I couldn’t find a single guide that worked completely. But I ended up piecing it all together from many, many, many different sources.

If you’re booting from a DVD iso and you’re stuck at the bios, I found these strings worked for me with Fedora:

For a 64-bit guest
cd:0,\ppc\chrp\yaboot conf=cd:0,\ppc\ppc64\yaboot.conf

For a 32-bit guest
cd:0,\ppc\chrp\yaboot conf=cd:0,\ppc\ppc32\yaboot.conf

(source: https://bugzilla.redhat.com/show_bug.cgi?id=545328)

The QEMU bios by default will try to load \ppc\chrp\yaboot.conf and fail. After booting up, I looked in the image and found there was a valid yaboot configuration under \ppc\chrp so i’m not sure why it didn’t just work right out of the box.

Another issue was running under sudo. I did this at first to get networking working properly, but it caused a kernel panic half-way through the boot process. I didn’t want to run it as root anyway, so I never tracked this issue down.


Posted on March 23rd, by admica in doh.

One thought on “Run Fedora 12 for PowerPC on Intel x86 with qemu-system-ppc

  1. I had to add -M mac99 to list of command line params to make F11 or F12 work.