Netatalk: AFP over Appletalk and TCP/IP

Sharing files with retro computers can sometimes be problematic. Nowadays with Samba and ssh it’s easy. But back then such sharing protocols were nowhere near as ubiquitious as we find them now.

AppleTalk Filing Protocol (AFP) was a fairly ubiquitous sharing protocol in the Mac world until Apple deprecated it in favour of SMB (SAMBA). AFP was still around until Apple finally removed it with the release of macOS Big Sur. I’d used a mixture of AFP, NFS and Samba up to that point for sharing files and music/video. But then I got rid of both NFS and AFP and switched to SAMBA. Since then I’d also setup a new NAS and retired the old one for just backup. I never bothered with configuring AFP on the new NAS.

Anyway with my new found interest in Mac OS9 I found myself regretting getting rid of AFP. It’s been around in the Mac world for an age and even before Mac moved to only TCPIP and had AppleTalk as the network protocol.

Netatalk is a project to keep AFP alive. It’s actively developed and packages are available for Debian (which my new NAS runs!). However, when I went to install it it wanted to install a LOT of other packages too. My NAS is headless but runs a plain vanilla Debian. Netatalk wanted to pull in a lof of zeroconf stuff and even some audio libraries. Forget that I want to keep my minimal NAS!

So I switched to Docker of which there are official images available for the Netatalk project. After a bit of messing that runs fine. The image builds your afp.conf file from a series of environment variables that you can set in the Docker Compose file. I will post this in a few weeks when I’ve added a few other cool stuff for Mac OS9. For example Web Rendering Proxy (WRP) which allows you to access HTTPS sites by serving a image with clickable areas to the retro browser on the retro mac!

Netatalk3 is mainly aimed at OSX/macOS. It uses Appletalk but for AFP it shares this over TCP/IP. This works fine for Mac OS9 as long as you manually connect using the IP address, but hey we want the simplicity of auto discovery! I struggled for some time with this before realising that I need to use Netatalk2 which still supports sharing AFP over Appletalk. This will share AFP over Appletalk via TCPIP, rather than AFP over TCPIP. All quite confusing. I was further confused by finding out if I used the standard Docker image of Netatalk3 then Mac OS9 failed to mount the share. Whereas if I built the image myself (from the same Git repository that the developers build their Docker image) then it worked fine! This red herring made me waste quite a bit of time until I actually read the Netatalk documentation!

Anyway once I realised this I switched my Docker compose file to use the netatalk2 image and Mac OS9 immediately saw the share (with netatalk3 I had to manually enter the IP address). Now it even allowed me to save the login details into the Keychain.

Chooser on an old retro Mac OS9 desktop.
Here’s my NAS (U2) in Chooser. Note all my machines are called after whatever music is playing. I used to love U2 but not since the eighties! But it was playing on the radio so….
an AFP login dialog on a old retro Mac OS9 desktop.
The user/password is still the default one for Netatalk! But it’s added to the Keychain.

The NAS share is also served by SAMBA so I can connect from it from my main Mac and Linux workstation. Both protocols give read access to guests but only RW to a logged in user.

a network share on a old retro Mac OS9 desktop.
The afpshare folder.
The Network Browser