Emaculation.com
 

Running qemu-system-m68k in Windows

(Guide last edited August 27th, 2021)

NOTE: This guide describes the use of a Qemu Alpha build, functionality and command line options are likely to change!

Introduction

Qemu-system-m68k can emulate the Apple Macintosh Quadra 800 machine, which allows running the 68k versions of Mac OS 7.1 up to 8.1, A/UX 3.x and the 68k port of NetBSD.

Status

The status of various guests based on the latest builds available from the forum:

Guest Default build Specific command line arguments Remarks
Mac OS 7.1 OK none none
Mac OS 7.5 OK none none
Mac OS 8.1 OK none none
A/UX 3.0.1 OK none none
A/UX 3.1.1 OK none none
NetBSD 9.2 OK none none

Running qemu-system-m68k with Mac OS 7.1-8.1 guests

Requirements

  • The qemu-system-m68k program
  • An Apple Macintosh Quadra 800 rom file
  • Disk images for the m68k versions of Mac OS you want to install

Assumptions in this guide

This guide assumes you are installing Mac OS 8.0 on a 2gb file that will act as your hard disk for Mac OS.
The CD image you install from is called MacOS8.0.iso and the hard disk is called MacOS8.0.img

Installations of other versions of Mac OS (roughly) follow the same path.

Preparing to install Mac OS

  • Create a folder for Qemu-related files and unpack the download. Put your Mac OS disk images in this folder.
  • Create an empty disk image to install Mac OS on.
  • Create a pram disk image to hold information about the system, such as screen resolution.

Open a command prompt and navigate to your Qemu folder.

Note: If you create a disk image larger than 2Gb, you will have to partition the disk so the first partition is 2Gb or less in size. Otherwise Mac OS will not boot after installation.

qemu-img.exe create -f raw -o size=2G MacOS8.0.img 
qemu-img.exe create -f raw pram-macos.img 256b

Open your favorite text editor and create a file called qemu-macos.bat with the following content:

qemu-system-m68k.exe ^
-L pc-bios ^
-M q800 ^
-bios Quadra800.rom ^
-boot d ^
-drive file=pram-macos.img,format=raw,if=mtd ^
-device scsi-hd,scsi-id=0,drive=hd0,vendor="SEAGATE",product="ST225N",ver="1.0" ^
-drive file=MacOS8.0.img,media=disk,format=raw,if=none,id=hd0 ^
-device scsi-cd,scsi-id=3,drive=cd0,vendor="MATSHITA",product="CD-ROM CR-8005",ver="1.0k" ^
-drive file=MacOS8.0.iso,media=cdrom,if=none,id=cd0

Save qemu-macos.bat

Starting qemu-system-m68k to install Mac OS

  • Double-click qemu-macos.bat. This starts Qemu and boots the MacOS8.0.iso installation CD image.
  • Partition the hard disk image by using the Drive setup tool from the Utilities folder.
  • Install Mac OS from the CD onto the hard disk image, then shut down.

Running MacOS

Edit qemu-m68k.bat to remove the cd entry:

qemu-system-m68k.exe ^
-L pc-bios ^
-M q800 ^
-bios Quadra800.rom ^
-drive file=pram-macos.img,format=raw,if=mtd ^
-device scsi-hd,scsi-id=0,drive=hd0,vendor="SEAGATE",product="ST225N",ver="1.0" ^
-drive file=MacOS8.0.img,media=disk,format=raw,if=none,id=hd0

Save qemu-macos.bat and run it.

Display options

There are 3 resolutions available: vga 640×480, supervga 800×600 and 1152×870.
When nothing is set on the command line 640×480 and 800×600 up to 24 bit colour/greyscale are available through the monitors control panel. Once set, the setting is preserved on reboot.
To use the 1152×870 resolution, add -g 1152x870x8 to the command line. This adds the Apple 21 monitor with that resolution.
Due to vram limitations it only supports up to 8 bit colour depth. Please note that in this case the other resolutions are not available.

Running qemu-system-m68k with A/UX 3.x guests in Windows

Assumptions in this guide

This guide assumes you are installing A/UX 3.x on a 2gb file that will act as your hard disk for A/UX. The CD image you install from is called AUX301.iso and the hard disk is called AUX301.img

Preparing to install A/UX

You need:

  • The qemu-system-m68k program
  • An Apple Macintosh Quadra 800 rom file
  • A disk image with the A/UX 3.x boot floppy content (but also see below)
  • A disk image of the A/UX installation CD Rom
  • A disk image of the A/UX 3.1 update.

The A/UX related files can all be found here: http://www.cilinder.be/archive/aux_3.0.1/ but the files have to be unpacked with e.g. 7-zip and renamed to fit this guide. You'll have to source a rom file yourself.

Create the required disk images:

qemu-img.exe create -f raw -o size=2G AUX301.img 
qemu-img.exe create -f raw pram.img 256b

Currently, partitioning a disk created with qemu-img while installing A/UX will not work. So download this disk image (expands to 2Gb): https://surfdrive.surf.nl/files/index.php/s/ddioctL8cL00RvB/download

Download the Qemu program to run A/UX from here: https://www.emaculation.com/forum/viewtopic.php?f=37&t=11326
Download a boot floppy image named AUXBootfloppy.img from here: https://surfdrive.surf.nl/files/index.php/s/ZcJMgrSBqFAqfQA/download
This boot floppy also contains the AWS Tune-up 2.0 software that can be applied after upgrading the initial installation of A/UX 3.0.1 to 3.1

Open your favorite text editor and create a file called qemu-aux.bat with the following content:

qemu-system-m68k.exe ^
-L pc-bios ^
-m 128 ^
-M q800 ^
-display sdl ^
-serial stdio ^
-bios Quadra800.rom ^
-g 800x600x8 ^
-net nic,model=dp83932 -net user ^
-drive file=pram.img,format=raw,if=mtd ^
-device scsi-hd,scsi-id=0,drive=fd0,vendor="SEAGATE",product="ST225N",ver="1.0" ^
-drive file=AUXBootfloppy.img,media=disk,format=raw,if=none,id=fd0 ^
-device scsi-hd,scsi-id=1,drive=hd0,vendor="SEAGATE",product="ST225N",ver="1.0" ^
-drive file=AUX301.img,media=disk,format=raw,if=none,id=hd0 ^
-device scsi-cd,scsi-id=3,drive=cd0,vendor="MATSHITA",product="CD-ROM CR-8005",ver="1.0k" ^
-drive file=AUX301.iso,format=raw,media=cdrom,if=none,id=cd0 
 

Save and run qemu-aux.bat

When you run qemu-aux.bat, qemu boots from the bootfloppy image, which in turn starts the A/UX installation.

Actual installation

For the actual installation and initial configuration you can follow this guide: http://www.aux-penelope.com/aux_3.0.htm

When you get to the networking part of that guide, use the steps outlined below!

More in-depth information about configuring A/UX can be found here:
https://wiki.preterhuman.net/Newbie_Guide_To_A/UX_(Apple_UNIX)

Note: You'll have to reboot several times during installation, update, enabling network.
Reboot will not work, so you need to shut down A/UX and restart Qemu.

Networking

If you run Qemu with “-net user” you can use the following settings to get networking going:

IP address 10.0.2.15
Netmask 255.255.255.0
Nameserver 10.0.2.3
Default route 10.0.2.2

Open a command shell and run “newconfig”. Enter the data required:

configure this interface: yes
hostname: (enter some unique name)
nis domain name: (can be left empty when not using nis)
ao0 internet address: 10.0.2.15
netmask: 255.255.255.0 
OK?: yes

Set the default route with:

echo /usr/etc/route add default 10.0.2.2 1 >> /etc/rc

Set the name server with:

echo nameserver 10.0.2.3 > /etc/resolv.conf

Reboot (Shut down, restart)

After the installation

After the installation, you can remove the boot floppy and installation iso from your qemu-aux.bat file, so the lines

-device scsi-hd,scsi-id=0,drive=fd0,vendor="SEAGATE",product="ST225N",ver="1.0" ^
-drive file=AUXBootfloppy.img,media=disk,format=raw,if=none,id=fd0 ^
-device scsi-cd,scsi-id=3,drive=cd0,vendor="MATSHITA",product="CD-ROM CR-8005",ver="1.0k" ^
-drive file=AUX301.iso,format=raw,media=cdrom,if=none,id=cd0 

can be removed, making sure the last line in the file does NOT end with a ^

Upgrade to A/UX 3.1

To start the upgrade to A/UX 3.1, you first need to add the disk image containing the upgrade to your qemu-aux.bat file:

device scsi-cd,scsi-id=3,drive=cd0,vendor="MATSHITA",product="CD-ROM CR-8005",ver="1.0k" ^
drive file=AUX_3.1_Update.iso,format=raw,media=cdrom,if=none,id=cd0  

save the file and start qemu-aux.bat

After boot has completed, the cd image with the updater appears on the desktop.

Upgrade to A/UX 3.1.1

For your convenience, the AWS Tune-up 2.0 has been included on the boot floppy you used before.
So re-add the bootfloppy to the command line and boot A/UX, then follow the steps in the readme to install the update.

Running qemu-system-m68k with NETBSD guests in Windows (Guide in progress)

The traditional way of installing NETBSD takes place from inside Mac OS, so to use this guide you need an already running system.
So create an additional disk image onto which you can install NetBSD and add the image and the NetBSD installation iso to the command line:

qemu-system-m68k.exe ^
-M q800 ^
-m 128 ^
-bios Quadra800.rom ^
-serial stdio ^
-display sdl ^
-net nic,model=dp83932 -net user ^
-drive file=pram.img,format=raw,if=mtd ^
-g 800x600x8 ^
-device scsi-hd,scsi-id=1,drive=hd1,vendor="SEAGATE",product="ST225N",ver="1.0" ^
-drive file=system8.1.img,media=disk,format=raw,if=none,id=hd1 ^
-device scsi-hd,scsi-id=0,drive=hd0,vendor="SEAGATE",product="ST225N",ver="1.0" ^
-drive file=netbsd92_1gb.img,media=disk,format=raw,if=none,id=hd0 ^
-device scsi-cd,scsi-id=3,drive=cd0,vendor="MATSHITA",product="CD-ROM CR-8005",ver="1.0k" ^
-drive file=NetBSD-9.2-mac68k.iso,media=cdrom,if=none,id=cd0

Preparing a hard disk image

First initialise the target disk with the Mac OS 8 setup tool.
Then use the Apple HD SCSI setup tool from the bootfloppy image to partition the disk as AppleServer disk
Create 1 partition of 850Mb
Create 1 partition of 100Mb
Create 1 partition of 50Mb

Installation

BSD Partitioning tool, Installer and Booter

On the installation iso, go to the Mac68K/Installation/Misc folder and copy:

BSD_MAC68K_BOOTER.BIN
INSTALLER_1_1H_SEA.BIN
MKFS_1_47_SEA.BIN

Into a folder on your Mac OS installation. Unstuff Installer and MKFS.

Start MKFS, select the scsi id of the hard disk to partition and format the usr and swap partitions.
This can take a while….

Next, start the Installer and navigate to Mac68K/BINARY/SETS and select the software sets you want to install. For each set select it, then click Add. Make sure to also select and add a kernel. The KERN_GENERIC.TGZ works fine.

After adding all desired sets, click Done and go for lunch.
Once completed, select Build Devices from the installer and then quit the installer.

Open the Booter and set Boot options to boot Single User (Also check the scsi id of your disk.
Set Serial Ports to Serial Console on Modem.

Save the Booter options and Select Boot Now.

In the Qemu command window, press Enter, then type “mount -a”
“cd /dev && ./MAKEDEV all”

#######Quit Qemu and restart Qemu.

#######Edit the /etc/rc.conf file with vi: #######“export TERM=vt100” #######“vi /etc/rc.conf”

#######“reboot”

#######Close the command window, qemu will quit. Start Qemu again and open the Booter.
#######At Boot Options uncheck Single User and save the boot options.

m68k-qemu-on-windows.txt · Last modified: 2021/10/13 22:54 by cat_7
 
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 4.0 International
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki