Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Moderators: Cat_7, Ronald P. Regensburg
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
I've been playing with your macOS alpha app, having installed system 7 Pro on a 2gig hard drive image. It's been very stable, but I'm experiencing a high load on the host. What could be causing it? Is there a way to throttle it back?
I'm also experiencing a graphics refresh issue with Prince of Persia in 256k color. It opens with a black screen and music, if I click in the window the graphics suddenly appear. During scene changes, only a portion of the graphics are displayed, however as the character moves across the scene the graphic is updated. I'm guessing it has something to do with the alpha build?
I'm also experiencing a graphics refresh issue with Prince of Persia in 256k color. It opens with a black screen and music, if I click in the window the graphics suddenly appear. During scene changes, only a portion of the graphics are displayed, however as the character moves across the scene the graphic is updated. I'm guessing it has something to do with the alpha build?
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
I wouldn't know. That would be something for the developer to look into.I'm guessing it has something to do with the alpha build?
Best,
Cat_7
- adespoton
- Forum All-Star
- Posts: 4287
- Joined: Fri Nov 27, 2009 5:11 am
- Location: Emaculation.com
- Contact:
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Just to be clear: the developers aren't the ones providing test builds here, so the best place to report bugs is probably the Issues tracker on https://gitlab.com/mcayland/qemu/-/tree/q800.upstream2 -- either that, or hope that Mark reads this threadmarbre wrote: ↑Fri Aug 19, 2022 2:08 am I've been playing with your macOS alpha app, having installed system 7 Pro on a 2gig hard drive image. It's been very stable, but I'm experiencing a high load on the host. What could be causing it? Is there a way to throttle it back?
I'm also experiencing a graphics refresh issue with Prince of Persia in 256k color. It opens with a black screen and music, if I click in the window the graphics suddenly appear. During scene changes, only a portion of the graphics are displayed, however as the character moves across the scene the graphic is updated. I'm guessing it has something to do with the alpha build?
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
My apologies, I did stray off topic.adespoton wrote: ↑Fri Aug 19, 2022 3:20 pm Just to be clear: the developers aren't the ones providing test builds here, so the best place to report bugs is probably the Issues tracker on https://gitlab.com/mcayland/qemu/-/tree/q800.upstream2 -- either that, or hope that Mark reads this thread
I see networking is discussed for windows host and A/UX on macOS, how about System 7/8? Is it possible using Open Transport?
Thanks,
Mark
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Hi,
What exactly would you like to do with OT?
It used for network connections over the ethernet card, but also for modem connection through the printer/modem port.
Ethernet works, including Appletalk. I believe there is no modem/printer port available to connect to a real modem.
Best,
Cat_7
What exactly would you like to do with OT?
It used for network connections over the ethernet card, but also for modem connection through the printer/modem port.
Ethernet works, including Appletalk. I believe there is no modem/printer port available to connect to a real modem.
Best,
Cat_7
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Sure,
You can use something like: -nic user,hostfwd=tcp::8080-:80
Take a look here: https://www.emaculation.com/doku.php/m6 ... rk_options
Best,
Cat_7
You can use something like: -nic user,hostfwd=tcp::8080-:80
Take a look here: https://www.emaculation.com/doku.php/m6 ... rk_options
Best,
Cat_7
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
What have I missed?
Edit: needed the model number
Code: Select all
qemu-system-m68k-MacOS-alpha: —nic: Could not open '—nic': No such file or directory
Code: Select all
-nic user,model=dp83932,hostfwd=tcp::8080-:80 \
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
I believe I have it working, 'info usernet' shows
Is there a way to share folders?
Thanks,
Mark
Code: Select all
(qemu) info usernet
Hub -1 (#net062):
Protocol[State] FD Source Address Port Dest. Address Port RecvQ SendQ
TCP[HOST_FORWARD] 15 * 8080 10.0.2.15 80 0 0
UDP[200 sec] 12 10.0.2.15 32768 10.0.2.3 53 0 0
Thanks,
Mark
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Hi,
No, not like the shared folder functionality available in Basilisk or SheepShaver.
You can install something like an ftp server inside Mac OS and forward the ftp port as you did with the http port.
https://macintoshgarden.org/apps/netpresenz
https://macintoshgarden.org/apps/ftpd-v300
https://macintoshgarden.org/apps/rumpus-20-ftp-server
Best,
Cat_7
No, not like the shared folder functionality available in Basilisk or SheepShaver.
You can install something like an ftp server inside Mac OS and forward the ftp port as you did with the http port.
https://macintoshgarden.org/apps/netpresenz
https://macintoshgarden.org/apps/ftpd-v300
https://macintoshgarden.org/apps/rumpus-20-ftp-server
Best,
Cat_7
- adespoton
- Forum All-Star
- Posts: 4287
- Joined: Fri Nov 27, 2009 5:11 am
- Location: Emaculation.com
- Contact:
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
That should also work, as long as you're running an FTP server on the host (which is insecure if your host ever leaves a trusted network).
Since your host OS is macOS 11, check out my other thread in General about the hfsfuse filesystem plugin working again -- as long as you only mount the image on the host OR guest at any given time, you can copy files on/off to your heart's content, with proper resource fork handling, file names and metadata. I recommend using a second image for this purpose so you don't accidentally open it in both places at once.
QEMU also includes a built-in SMB share that's a bit flaky and may not work in m68k (I haven't tested it, YMMV): it's enabled using `-net user,smb=<file path to share>`.
QEMU ALSO includes a built-in FAT-16 share that's REALLY flaky and may not work in m68k (same disclosure as above): it's enabled using `-drive file=fat:rw:<file path to share>,bus=0,unit=1,if=scsi,format=raw,media=disk` and may require fiddling with the unit value and WILL require the DOS filesystem extension. If you go this route, I suggest trying out Mt Everything as well, to recognize and mount the filesystem.
Cat_7 probably has a pocket full of good reasons not to try the last two options, from garbled file names to loss of resource forks to "it doesn't actually work on m68k" but I figured I'd capture all the potential options in one place
Note that using "regular" file sharing on the host or guest (SMB or AppleShare IP) won't work, as the host and guest have no compatible versions of either of these protocols.
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Enabling remote login under 'Sharing' allows SFTP access to the host to copy files to and from it--simple, if it works. If I need an ftp server on the host side, I was thinking CyberDuck.
hfsfuse would make disk swapping easier, but I haven't figured out how to do that on the fly. I've been modifying the shell script every time I needed to use an image or cdrom--very tedious. I tried 'change' but haven't got it work.
hfsfuse would make disk swapping easier, but I haven't figured out how to do that on the fly. I've been modifying the shell script every time I needed to use an image or cdrom--very tedious. I tried 'change' but haven't got it work.
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Haha, so trueCat_7 probably has a pocket full of good reasons not to try the last two options
Seeing all those possibilities to exchange files, I notice we don't have a full overview of options and contexts (user, tap or vmnet) / (local network, internet) in which they work. But surely we need to leave some tinkering to the user
Do we have a modern enough ftp client for Mac OS 8 to connect to built-in s/ftp on the host?
Best,
Cat_7
- adespoton
- Forum All-Star
- Posts: 4287
- Joined: Fri Nov 27, 2009 5:11 am
- Location: Emaculation.com
- Contact:
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
The bigger issue is 68k support; there's no hardware support for encryption, so anything's going to be really slow and resource intensive. MacSFTP is available for Mac OS 8.1+, but it's PPC-only. Something to watch that IS compatible right back to the Mac Plus is https://github.com/cy384/ssheven/releases -- but he hasn't got file transfer implemented yet. It also appears that SSHeven doesn't implement TLS1.2/1.3, which means it can't connect to modern ssh servers that have protocol fallback disabled (for very valid security reasons).Cat_7 wrote: ↑Tue Aug 23, 2022 6:25 pmHaha, so trueCat_7 probably has a pocket full of good reasons not to try the last two options
Seeing all those possibilities to exchange files, I notice we don't have a full overview of options and contexts (user, tap or vmnet) / (local network, internet) in which they work. But surely we need to leave some tinkering to the user
Do we have a modern enough ftp client for Mac OS 8 to connect to built-in s/ftp on the host?
Best,
Cat_7
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
ftp isn't working when set to active mode
in guest, NetPresenz log shows "NcFTP @4 transfer failed -23008".
Code: Select all
ncftp> open -P 2121 localhost
Connecting to 127.0.0.1...
NetPresenz v4.1 awaits your command.
Logging in...
This file must be in the Startup Messages folder in either the same
folder as NetPresenz or in the NetPresenz Preferences folder in the
Preferences folder, and will be displayed to guests user when they log
in. Guest users log in by using the username "ftp" or "anonymous".
Anonymous login to 1 volumes. Access restrictions apply. "/".
Logged in to localhost.
ncftp / > rhelp SITE
SITE ABCHILPQSUV - See "HELP SITE <letter>".
ncftp / > quote PWD
"/" PWD command successful.
ncftp / > quote TYPE I
Type set to I, binary transfer mode [macbinary disabled].
ncftp / > quote PORT 10,0,2,15,187,185
PORT command successful.
ncftp / > quote LIST
ASCII transfer started.
ncftp / > close
- adespoton
- Forum All-Star
- Posts: 4287
- Joined: Fri Nov 27, 2009 5:11 am
- Location: Emaculation.com
- Contact:
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Active mode means the server connects out to the client to make the data transfer on a randomly selected port specified by the client in the data transfer request. In this case, you're attempting to get the NetPrezenz server to connect to the ncftp client at address 10.0.2.15 on ports 187 and 185. Is everything set up to support that on the host?marbre wrote: ↑Thu Aug 25, 2022 1:53 pm ftp isn't working when set to active modein guest, NetPresenz log shows "NcFTP @4 transfer failed -23008".Code: Select all
ncftp> open -P 2121 localhost Connecting to 127.0.0.1... NetPresenz v4.1 awaits your command. Logging in... This file must be in the Startup Messages folder in either the same folder as NetPresenz or in the NetPresenz Preferences folder in the Preferences folder, and will be displayed to guests user when they log in. Guest users log in by using the username "ftp" or "anonymous". Anonymous login to 1 volumes. Access restrictions apply. "/". Logged in to localhost. ncftp / > rhelp SITE SITE ABCHILPQSUV - See "HELP SITE <letter>". ncftp / > quote PWD "/" PWD command successful. ncftp / > quote TYPE I Type set to I, binary transfer mode [macbinary disabled]. ncftp / > quote PORT 10,0,2,15,187,185 PORT command successful. ncftp / > quote LIST ASCII transfer started. ncftp / > close
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Could use some help. Right now I have
It's counter-intuitive that I have to use localhost:2121 to open the connection, when Mac OS is on 10.0.2.15:21 according to NetPresenz. Very confusing.
Code: Select all
-nic user,model=dp83932,hostfwd=tcp::2121-:21,hostfwd=tcp::8080-:80 \
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
You don't _have_ to use the port numbers suggested. Using the suggested numbers mainly prevents interfering with services that might already run on those ports on the host.
Best,
Cat_7
Best,
Cat_7
- adespoton
- Forum All-Star
- Posts: 4287
- Joined: Fri Nov 27, 2009 5:11 am
- Location: Emaculation.com
- Contact:
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Think of it this way: you've got a host system, which may or may not have an FTP server sitting listening on port 21, and likely nothing listening on port 2121.marbre wrote: ↑Thu Aug 25, 2022 2:58 pm Could use some help. Right now I have
It's counter-intuitive that I have to use localhost:2121 to open the connection, when Mac OS is on 10.0.2.15:21 according to NetPresenz. Very confusing.Code: Select all
-nic user,model=dp83932,hostfwd=tcp::2121-:21,hostfwd=tcp::8080-:80 \
Then you've got the guest system, that needs to open up some ports. It can't reliably open a port on port 21, because all that QEMU is doing here is passing through traffic that's on a port on the host system. And port 21 may already be occupied by other non-QEMU processes.
So that configuration opens a connection on the host on port 2121 and passes all data it receives to a virtual port 21 on the guest. So as far as the guest is concerned, the traffic came through on port 21, but in reality it went to the host on port 2121.
But with FTP, there are TWO channels in use: the control channel (used for sending commands) that listens on port 21 for new connections, and the data channel (used for sending files etc.) that uses a random port.
In the early days of FTP, there was only Active mode. Active mode works by the ftp client that's already connected to the server over the control channel (port 21) sending a request for data that includes instructions for what port on the client machine the SERVER should connect to to send the data. This was useful because you could have a different client managing the request than the one receiving the data -- so client A could request a file from server B, but tell it to send the file to client C... and the server would do so.
However, this ran into issues with subnetworks and firewalls, where the server may not actually be able to access the client's IP/port directly. So the solution was to create Passive mode, where the server opened a new random port and told the client where to connect to download the file. This worked, because the client could already connect to the server IP, and the server could adjust its firewall rules to allow the client's IP address to access the temporary port to make the connection and download the file.
The issue with QEMU, is we've got the entire situation in reverse. The client has no restrictions regarding address or port, but the SERVER is abstracted away -- any ports opened on it won't actually be viewable on the host or any other systems on the subnet unless there is an explicit mapping from the host to the guest to allow it. Which is difficult when the ports are being dynamically opened on a random port on the fly by the guest.
So the solution is to go back to using Active mode, and then have your FTP client explicitly name the IP and random port where it is accessible to the guest-hosted server.
For SLIP connections though, there is generally no direct route to the host interfaces; you can't loop back to the host from the guest. But connecting from a secondary interface (either on another computer on the subnet, or on the same host) should let you do so.
Confusing? yes. Especially when all you really want is to transfer files between a running guest system and the host system.
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
My MacBook is using these ports
Traditionally, ftp uses port 20 for data transfer. Do I need a third port to forward, i.e.
and then set PORT
NetPresenz log has 10.0.2.2 for machine, should I use that or localhost?
PORT 10,0,2,2,20
or PORT 127,0,0,1,2020
Code: Select all
q800_vm $ sudo lsof -nP -iTCP -sTCP:LISTEN
Password:
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
launchd 1 root 7u IPv6 0x7e1d84486654fccb 0t0 TCP *:22 (LISTEN)
launchd 1 root 8u IPv4 0x7e1d844866556453 0t0 TCP *:22 (LISTEN)
launchd 1 root 10u IPv6 0x7e1d84486654fccb 0t0 TCP *:22 (LISTEN)
launchd 1 root 11u IPv4 0x7e1d844866556453 0t0 TCP *:22 (LISTEN)
launchd 1 root 24u IPv6 0x7e1d84486655032b 0t0 TCP *:445 (LISTEN)
launchd 1 root 26u IPv4 0x7e1d844866556e7b 0t0 TCP *:445 (LISTEN)
launchd 1 root 28u IPv6 0x7e1d84486655032b 0t0 TCP *:445 (LISTEN)
launchd 1 root 29u IPv4 0x7e1d844866556e7b 0t0 TCP *:445 (LISTEN)
kdc 137 root 5u IPv6 0x7e1d84486655098b 0t0 TCP *:88 (LISTEN)
kdc 137 root 7u IPv4 0x7e1d8448665578a3 0t0 TCP *:88 (LISTEN)
rapportd 43226 marbre 5u IPv4 0x7e1d844880434593 0t0 TCP *:61204 (LISTEN)
rapportd 43226 marbre 6u IPv6 0x7e1d8448862abccb 0t0 TCP *:61204 (LISTEN)
Dropbox 83327 marbre 108u IPv6 0x7e1d8448862ac98b 0t0 TCP *:17500 (LISTEN)
Dropbox 83327 marbre 109u IPv4 0x7e1d84487f483fbb 0t0 TCP *:17500 (LISTEN)
Dropbox 83327 marbre 137u IPv4 0x7e1d84488045ba2b 0t0 TCP 127.0.0.1:17600 (LISTEN)
Dropbox 83327 marbre 141u IPv4 0x7e1d84487f482143 0t0 TCP 127.0.0.1:17603 (LISTEN)
qemu-syst 84880 marbre 15u IPv4 0x7e1d84487f483593 0t0 TCP *:8080 (LISTEN)
qemu-syst 84880 marbre 16u IPv4 0x7e1d84487f48171b 0t0 TCP *:2121 (LISTEN)
q800_vm $ ncftp
Code: Select all
-nic user,model=dp83932,hostfwd=tcp::2020-:20,hostfwd=tcp::2121-:21,hostfwd=tcp::8080-:80 \
Code: Select all
ncftp / > quote HELP PORT
PORT <h0>, <h1>, <h2>, <h3>, <p0>, <p1> - machine/port to send/receive from.
PORT 10,0,2,2,20
or PORT 127,0,0,1,2020
- adespoton
- Forum All-Star
- Posts: 4287
- Joined: Fri Nov 27, 2009 5:11 am
- Location: Emaculation.com
- Contact:
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Port forwarding should only be needed if you're in Passive mode. Otherwise, it's the client that's listening, not the server. So the issue is ensuring that the server can connect to the host port the client is listening on. If you run a web server on port 80 on the host, can a browser in the guest connect to it? If yes, FTP *should* be working already. If no, then you've got an issue with SLIrP network routing you need to solve some other way -- it's possible you need to connect ncftp to a different interface (try en0 IP, 10.0.2.2 and localhost and see if one of them works).marbre wrote: ↑Thu Aug 25, 2022 6:02 pm My MacBook is using these ports
Traditionally, ftp uses port 20 for data transfer. Do I need a third port to forward, i.e.Code: Select all
q800_vm $ sudo lsof -nP -iTCP -sTCP:LISTEN Password: COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME launchd 1 root 7u IPv6 0x7e1d84486654fccb 0t0 TCP *:22 (LISTEN) launchd 1 root 8u IPv4 0x7e1d844866556453 0t0 TCP *:22 (LISTEN) launchd 1 root 10u IPv6 0x7e1d84486654fccb 0t0 TCP *:22 (LISTEN) launchd 1 root 11u IPv4 0x7e1d844866556453 0t0 TCP *:22 (LISTEN) launchd 1 root 24u IPv6 0x7e1d84486655032b 0t0 TCP *:445 (LISTEN) launchd 1 root 26u IPv4 0x7e1d844866556e7b 0t0 TCP *:445 (LISTEN) launchd 1 root 28u IPv6 0x7e1d84486655032b 0t0 TCP *:445 (LISTEN) launchd 1 root 29u IPv4 0x7e1d844866556e7b 0t0 TCP *:445 (LISTEN) kdc 137 root 5u IPv6 0x7e1d84486655098b 0t0 TCP *:88 (LISTEN) kdc 137 root 7u IPv4 0x7e1d8448665578a3 0t0 TCP *:88 (LISTEN) rapportd 43226 marbre 5u IPv4 0x7e1d844880434593 0t0 TCP *:61204 (LISTEN) rapportd 43226 marbre 6u IPv6 0x7e1d8448862abccb 0t0 TCP *:61204 (LISTEN) Dropbox 83327 marbre 108u IPv6 0x7e1d8448862ac98b 0t0 TCP *:17500 (LISTEN) Dropbox 83327 marbre 109u IPv4 0x7e1d84487f483fbb 0t0 TCP *:17500 (LISTEN) Dropbox 83327 marbre 137u IPv4 0x7e1d84488045ba2b 0t0 TCP 127.0.0.1:17600 (LISTEN) Dropbox 83327 marbre 141u IPv4 0x7e1d84487f482143 0t0 TCP 127.0.0.1:17603 (LISTEN) qemu-syst 84880 marbre 15u IPv4 0x7e1d84487f483593 0t0 TCP *:8080 (LISTEN) qemu-syst 84880 marbre 16u IPv4 0x7e1d84487f48171b 0t0 TCP *:2121 (LISTEN) q800_vm $ ncftp
and then set PORTCode: Select all
-nic user,model=dp83932,hostfwd=tcp::2020-:20,hostfwd=tcp::2121-:21,hostfwd=tcp::8080-:80 \
NetPresenz log has 10.0.2.2 for machine, should I use that or localhost?Code: Select all
ncftp / > quote HELP PORT PORT <h0>, <h1>, <h2>, <h3>, <p0>, <p1> - machine/port to send/receive from.
PORT 10,0,2,2,20
or PORT 127,0,0,1,2020
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
I don't have a web server running. I can connect to the ftp server on the guest, I'm not able to list directory contents or do file transfer. I don't know anything about SLIrP.
btw, I started with passive but was having the same issues with dir listing and transfers.
btw, I started with passive but was having the same issues with dir listing and transfers.
- adespoton
- Forum All-Star
- Posts: 4287
- Joined: Fri Nov 27, 2009 5:11 am
- Location: Emaculation.com
- Contact:
Re: Qemu-system-m68k for macOS to run MacOS 7.1-8.1
Do you have any service running on the host that you can try connecting to with the guest? Because that appears to be where your current issues are. Going with Active instead of Passive is the right route, but if your network proxying from the guest to the host is over SLIrP, you can only connect out to other devices, not to the host. And since Active FTP has the data connection going from the server to the client, it won't be able to reach the client if it's running on the host. There are workarounds for this, however, including reverse port redirection.marbre wrote: ↑Thu Aug 25, 2022 9:22 pm I don't have a web server running. I can connect to the ftp server on the guest, I'm not able to list directory contents or do file transfer. I don't know anything about SLIrP.
btw, I started with passive but was having the same issues with dir listing and transfers.