GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

About Qemu-system-ppc, a PPC Mac emulator for Windows, macOS and Linux that can run Mac OS 9.0 up to Mac OS X 10.5

Moderators: Cat_7, Ronald P. Regensburg

alex195812
Mac Mechanic
Posts: 169
Joined: Mon Aug 29, 2016 3:44 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by alex195812 »

LightBulbFun wrote:Just a heads up I installed OS X Sever 1.2V3 onto a real computer (a then imaged its hard drive and pointed qemu to that image and much to my surprise it did start booting but it hung just after detecting the ATA devices. I tried a couple builds of QEMU with no avail (all hang in the same place) (also note i had to do 8bit colour otherwise it was all corrupted) now this was with mac99

Image

I just now (like after writing the above section) decided to try g3beige machine option and much to my surprise it booted all the way to the normal login screen! sadly my mouse and keyboard are unresponsive in the emulated machine

Image

just a quick post from me heh hope it all makes sense
How long does it take your image to boot to login screen?
As installation cd images don't boot far,won't you upload your image file to try it with different qemu/openbios versions?
User avatar
sentient06
Mac Mechanic
Posts: 188
Joined: Tue Mar 29, 2011 8:57 pm
Location: London, UK

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by sentient06 »

(Quick out of subject observation... page 50! Is this a record?)
User avatar
sentient06
Mac Mechanic
Posts: 188
Joined: Tue Mar 29, 2011 8:57 pm
Location: London, UK

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by sentient06 »

alex195812 wrote: How long does it take your image to boot to login screen?
As installation cd images don't boot far,won't you upload your image file to try it with different qemu/openbios versions?
It would be sweet to have some sort of files repository to exchange these types of things.. I wonder if there is a free service in the wild? 4shared perhaps? It's been ages I don't log into it. Let me give a look.

Update

Indeed, 4shared allows 15GB, it seems. With a monthly traffic of 30GB and a daily traffic of 3GB. It could be used for small files or quick exchanges of larger files. I now remember some members of the Macintosh Garden forum use 4shared to exchange some large files. I happen to have an iMac G3 and a G4 Cube installation and restore disk images. They lost utility to me, but if that is useful to anyone, let me know.
alex195812
Mac Mechanic
Posts: 169
Joined: Mon Aug 29, 2016 3:44 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by alex195812 »

mega.co.nz provides 50G for free...I've downloaded from there several times.And I've backuped some of my iso images there.
andreas_g
Student Driver
Posts: 20
Joined: Thu Dec 02, 2010 5:50 pm
Location: Austria

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by andreas_g »

I'd like to add a question to the file exchange discussion: Does anyone maintain a collection of original install media (or images) of the PPC Mac OS X line (Rhapsody DR1 to Mac OS X v10.5.8)? While developing Previous (NeXT Computer emulator) someone built a complete collection of all versions of 68k NeXTstep(NeXTstep 0.8 to OPENSTEP 4.2). It was very useful for developing and debugging the emulator.
alex195812
Mac Mechanic
Posts: 169
Joined: Mon Aug 29, 2016 3:44 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by alex195812 »

some images (up to 10.3) may be found at https://winworldpc.com, some at http://macintoshgarden.org. I have some images locally.
LightBulbFun
Tinkerer
Posts: 50
Joined: Mon Jul 13, 2015 11:32 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by LightBulbFun »

hyoenmadan wrote:Again, is the same thing that we have commented before. Sawtooth will not do it for older MacOS versions than 9.1.x or 9.0.x with the special Sawtooth Mac OS ROM file "patch". For these older versions you really need a complete Gossamer g3beige emulated in QEMU (or the Yosemite G3 "blue&white", which doesn't exist in QEMU).
apart from the fact that OS X Sever 1.2V3 fully supports real world Sawtooth class machines (all the way up to the PowerMac3,3 Gigabit ethernet G4s and i have been able to boot it with some poking around in Open Firmware on my PowerMac 2,2 Flower power iMac) that and OS X Sever does not use any sort of ROM loaded from Hard disk (only Classic Mac OS does that)

Looking through the OS X Sever boot loader files on New world ROM macs it officially supports: iMac,1 PowerMac1,1 PowerMac1,2 PowerMac2,1 PowerMac3,1 PowerMac3,3 PowerMac5,1 PowerBook1,1 and finally PowerBook2,1. The boot loader checks the machine id in OF and if its not in that list it will abort booting and kick you back to OF. if you simply edit your Model id property in OF its easy to trick OS X Sever to boot on unsupported machines (my iMac for example. and i even tried a 500MHz snow iBook but it panics through the boot but i am able to get into SU with it)
User avatar
sentient06
Mac Mechanic
Posts: 188
Joined: Tue Mar 29, 2011 8:57 pm
Location: London, UK

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by sentient06 »

alex195812 wrote:mega.co.nz provides 50G for free...I've downloaded from there several times.And I've backuped some of my iso images there.
That's really nice, I'm looking into it.
andreas_g wrote:I'd like to add a question to the file exchange discussion: Does anyone maintain a collection of original install media (or images) of the PPC Mac OS X line (Rhapsody DR1 to Mac OS X v10.5.8)? While developing Previous (NeXT Computer emulator) someone built a complete collection of all versions of 68k NeXTstep(NeXTstep 0.8 to OPENSTEP 4.2). It was very useful for developing and debugging the emulator.
Not yet, but that's something I'm looking forward to doing.

I had Rhapsody DR1, never tested though, the iso is lost in some old hard drive limbo. I also have a virtual machine lost somewhere with the DR2 installed in a VMWare machine, it is very unstable, but very nice to take for a spin. I have the ISOs as well, but they didn't work properly in VMWare, so I used a disk image I found in a torrent.

Does Rhapsody DR2 work with QEMU? I have no idea how QEMU handles x86 emulation.
User avatar
UbuntuXP
Tinkerer
Posts: 68
Joined: Sat Feb 08, 2014 8:15 pm

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by UbuntuXP »

I've tried the Intel version of Rhapsody DR2 in QEMU, and even though it can detect both the hd and cdrom, it can't boot from the cdrom, resulting in a kernel panic.

Drivers selected:
Primary/Secondary(Dual) EIDE/ATAPI Device Controller (5.01)

Terminal output:

Code: Select all

dma: command 10 not supported
dma: command 10 not supported
dma: command 14 not supported
dma: command 10 not supported
dma: command 14 not supported
dma: command 10 not supported
dma: command 14 not supported
dma: command 10 not supported
dma: command 14 not supported
dma: command 10 not supported
dma: command 14 not supported
dma: command 10 not supported
dma: command 14 not supported
dma: command 10 not supported
dma: command 14 not supported
dma: command 10 not supported
dma: command 14 not supported
dma: command 10 not supported
dma: command 14 not supported
dma: command 10 not supported
QEMU version: 2.7.0

rhapsodydr2.command

Code: Select all

cd "$(dirname "$0")"

qemu-system-i386 \
-m 128M \
-drive file="RhapsodyDR2.qcow2",index=0,if=ide,format=qcow2,media=disk,cache=writethrough,aio=threads \
-drive file="Rhapsody_x86_DR2/rhapsody_dr2_x86.iso",index=2,if=ide,format=raw,media=cdrom,cache=writethrough,aio=threads \
-drive file="Rhapsody_x86_DR2/Boot Floppy/rhapsody_dr2_x86_InstallationFloppy.img",index=0,if=floppy,format=raw \
-boot order=adc,menu=on \
-cpu 486 \
-name "Rhapsody Developer Release 2" \
-netdev user,id=vlan0 \
-device pcnet,netdev=vlan0 \
-soundhw sb16 \
-vga cirrus \
-L /usr/local/share/qemu \
-bios bios.bin \
-rtc base=localtime
"Unix was not designed to stop you from doing stupid things, because that would also stop you from doing clever things."

Doug Gwyn
User avatar
sentient06
Mac Mechanic
Posts: 188
Joined: Tue Mar 29, 2011 8:57 pm
Location: London, UK

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by sentient06 »

UbuntuXP wrote:I've tried the Intel version of Rhapsody DR2 in QEMU, and even though it can detect both the hd and cdrom, it can't boot from the cdrom, resulting in a kernel panic.
Oh well, I suppose that's a different beast anyway.
andreas_g
Student Driver
Posts: 20
Joined: Thu Dec 02, 2010 5:50 pm
Location: Austria

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by andreas_g »

sentient and alex, thank you for the reply! I'll have a look.

I like the screenshots of Mac OS X Server booting. Somehow you can still see where it came from:

Image
JackMacWindows
Space Cadet
Posts: 3
Joined: Wed Oct 19, 2016 10:07 pm

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by JackMacWindows »

I was able to use the Mac OS 9.2.1 boot ISO listed a bunch of pages back to boot, with the recommended command there on "OpenBIOS 1.1 [Feb 4 2016 21:07]" and QEMU 2.7. I then attached my OS 9.0.4 image and I was able to do a custom install of only the system software and QuickTime. I moved all the extensions to a Disabled folder (there were no control panels) and rebooted. Now when I reboot using -boot c, I get this message and it hangs there:

Code: Select all

Trying hd:,\\:tbxi...
Trying hd:,\ppc\bootinfo.txt...
I am not able to boot into Mac OS. Also, if I leave it for about five minutes the window collapses to a tiny ~64*64 window. Is that normal? How can I fix this? I'm too lazy to scroll through all 50 pages to find something, if anything.

JackMacWindows

P.S.:
julialy wrote:Wow, I wonder where this is going to go...
It ended up going to 50 pages. :lol:
User avatar
Cat_7
Expert User
Posts: 6145
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by Cat_7 »

Hi,

You can always start a new thread for new problems ;-)
For what machine was your 9.0.4 intended originally?
9.0.4 images should be for G4 machines (like the cube), otherwise the included rom will be too old to boot.
Look for the G4 cube installation image on the macintoshgarden site. It can boot directly with qemu and will install and boot from HD image.

What is your current command line? You need to change -boot to "c" and place the drive entry for the hd image before the drive entry of your cd.

Best,
Cat_7
JackMacWindows
Space Cadet
Posts: 3
Joined: Wed Oct 19, 2016 10:07 pm

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by JackMacWindows »

Hello,
I did set the -boot c option originally. I also changed the indices of the drive (cdrom was 0, hd was 1, bad idea) to how they should be, and it is able to get to the NVRAM error. But then QEMU crashes with this error:

Code: Select all

qemu-system-ppc: Trying to execute code outside RAM or ROM at 0x12181020
This usually means one of the following happened:

(1) You told QEMU to execute a kernel for the wrong machine type, and it crashed on startup (eg trying to run a raspberry pi kernel on a versatilepb QEMU machine)
(2) You didn't give QEMU a kernel or BIOS filename at all, and QEMU executed a ROM full of no-op instructions until it fell off the end
(3) Your guest kernel has a bug and crashed by jumping off into nowhere

This is almost always one of the first two, so check your command line and that you are using the right type of kernel for this machine.
If you think option (3) is likely then you can try debugging your guest with the -d debug options; in particular -d guest_errors will cause the log to include a dump of the guest register state at this point.

Execution cannot continue; stopping here.
I used this command:

Code: Select all

qemu-system-ppc -bios ~/Downloads/openbios-qemu_cr_lf_rtas_esccprops.elf -boot c -drive file=~/Downloads/os92_test.iso,index=1,media=cdrom -drive file=~/Downloads/OS9.vdi,format=vdi,index=0 -M mac99 -m 256 -prom-env 'autoboot?=false' -g 1024x768x32 -cpu G3 -net none
I also tried setting -M to g3beige, and I got this error in OpenBIOS:

Code: Select all

MacOS: Boot Failure!  (0xF3C481F6)
I'm not sure what machine this disc image is for, I'm guessing one that does not work based on the errors! :wink:

JackMacWindows
kataetheweirdo
Master Emulator
Posts: 313
Joined: Sun Feb 01, 2009 4:55 pm

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by kataetheweirdo »

MacOS: Boot Failure! (0xF3C481F6)
You can't boot Mac OS 9.x in G3 Beige mode. It's going to be rather hard to get it working in G3 Beige

Also, try changing this...
-drive file=~/Downloads/OS9.vdi,format=vdi,index=0
to...
-drive file=~/Downloads/OS9.vdi,format=vdi,index=0,cache=writethrough
Make sure you use QEMU 2.7 with the default BIOS, because the included BIOS can now boot up Mac OS 9.
JackMacWindows
Space Cadet
Posts: 3
Joined: Wed Oct 19, 2016 10:07 pm

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by JackMacWindows »

I adjusted the command to this:

Code: Select all

qemu-system-ppc -boot c -drive file=~/Downloads/OS9.vdi,format=vdi,index=0,cache=writethrough -M mac99 -m 256 -prom-env 'autoboot?=false' -g 1024x768x32 -cpu G3 -net none
but it still comes up with the same error. Here is a bit more information just in case:

Code: Select all

Trying to write invalid spr 0 (0x000) at 00f110b4
Trying to read invalid spr 0 (0x000) at 00f110bc
That was before the previous error.

JackMacWindows
alex195812
Mac Mechanic
Posts: 169
Joined: Mon Aug 29, 2016 3:44 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by alex195812 »

I think you should add "media=disk" to string "-drive file=..." and place hard disk string before cdrom string on the command line.Also cpu should be G4.
And it seems to me your openbios version is too old.Qemu boots unmodifyed OS9 since about July this year,so no need to disabe any extentons I think.
The messages about invalid spr's are usual for now:I always get them booting OS9.I had similar messages trying to boot AIX in qemu-system-ppc64.As far as I know,it's because several spr's(special purpose registers) are unimplemented in the emulator yet.
User avatar
celebi23
Granny Smith
Posts: 101
Joined: Wed Jun 18, 2008 5:53 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by celebi23 »

What's the Mac build & files needed to get a 256 color mode working for Mac OS 9? The ones I have are probably pretty outdated. Trying to run Freddy Pharkas. Thanks!
User avatar
Cat_7
Expert User
Posts: 6145
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by Cat_7 »

I guess you need this build:
http://www.open.ou.nl/hsp/downloads3/Qe ... 082016.zip
It has the vga enhancements, so you will be able to set resolution and color depth.

Best,
Cat_7
User avatar
celebi23
Granny Smith
Posts: 101
Joined: Wed Jun 18, 2008 5:53 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by celebi23 »

Cat_7 wrote:I guess you need this build:
http://www.open.ou.nl/hsp/downloads3/Qe ... 082016.zip
It has the vga enhancements, so you will be able to set resolution and color depth.

Best,
Cat_7
So that's the build I'm already using. Is there any special things I need to include in the Qemu command file? I'm not seeing the 256 color option in the display settings in Mac OS 9.
kataetheweirdo
Master Emulator
Posts: 313
Joined: Sun Feb 01, 2009 4:55 pm

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by kataetheweirdo »

If you're using the -g command line option, it's not needed to specify the bit depth. I just use -g 640x480 or -g 800x600 and be done with it. However, sound doesn't work yet, reducing the atmosphere of the game a little bit.
User avatar
celebi23
Granny Smith
Posts: 101
Joined: Wed Jun 18, 2008 5:53 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by celebi23 »

kataetheweirdo wrote:If you're using the -g command line option, it's not needed to specify the bit depth. I just use -g 640x480 or -g 800x600 and be done with it. However, sound doesn't work yet, reducing the atmosphere of the game a little bit.
That's what I was trying. Still not seeing the 256 color option in the Monitor Control panel. Not sure what I'm doing wrong/what I'm missing.
User avatar
Cat_7
Expert User
Posts: 6145
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by Cat_7 »

Oh, I see,
There is no 256 color option in that build. Strange, there is in the SDL based Windows build from the same source.
I tried various new installations off different cd images, but the option will indeed not appear.
Builds from the current Qemu master source do show the 256 colors/grays option, but garble the screen.
Seems you are out of luck.

Best,
Cat_7
User avatar
celebi23
Granny Smith
Posts: 101
Joined: Wed Jun 18, 2008 5:53 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by celebi23 »

Cat_7 wrote:Oh, I see,
There is no 256 color option in that build. Strange, there is in the SDL based Windows build from the same source.
I tried various new installations off different cd images, but the option will indeed not appear.
Builds from the current Qemu master source do show the 256 colors/grays option, but garble the screen.
Seems you are out of luck.

Best,
Cat_7
Ah, gotcha. I thought I was crazy for a minute trying to figure out what I missed :P Do you have a link to that SDL Windows version? There's just one bug in Freddy Pharkas that has persisted in SheepShaver, Basilisk II & Mini vMac that I want to check on. I can just reboot into Window 10 to check it out.
william341
Space Cadet
Posts: 3
Joined: Fri Oct 21, 2016 3:35 am

Re: GSOC qemu Boot Mac OS >= 8.5 on PowerPC system

Post by william341 »

The funny thing is that QEMU (which managed to develop this crap in less than a year) is more stable than a 9 year old emu (SheepShaver)
Post Reply