
Here my rants on a recent problem I had with AFS, also known as AppleFileServer. Before I continue on my complex problems and childish solution however, let me tell you that I do know a bit about internetworking, Unixes and troubleshooting. I made a living for over a decade as a network engineer and sysop. I know TCP/IP, I know Unix. Just to make clear that no matter how easy the solution of my problem is, I know how to get in trouble during the troubleshooting phase :-)
My problem? Let me tell you about my problem. I love Unixes yet have no time anymore to do maintenance and I just want a slick UI and a powerful GUI. So, I paid the appletax and switched all my machines from GNU/Linux (and a windows pc) towards the OSX platform. I have a couple of macbooks, an air, a mini and an iMac. Despite it being an Apple, I still like to make backups. Or rather, one day I might like to do a restore. Nobody likes backups.
So I have a huge external disk to my iMac and use TimeMachine on my macs to do their incremental backups towards this disk. All worked fine. And then one day, backups didnt work. None of my macs could mount any disk on my iMac; the host of my shared TimeMachineDisk. Yes, ping worked. Yes, I could share a screen. Yes, from my imac I still could mount all other disk on all the client. But not from any of the clients towards the iMac.
In fact, as soon as a client wanted to mount any disk on my iMac, it resulted in a very high CPU usage. My iMac has two CPU’s and all available CPU resources were being used by AppleFileServer.

So I googled. And believe me, I am not the only one with this problem. Far from as you can see in this autocomplete Google screenshot:

I did all the tricks, search for all the answers, used all the command line tools to see where the problem starts including TCP dumping the connection. I dsabled auto-disconnect in AFP editing the .plist files, removed spotlight indexing on all AFP volumes, deleted .SpotLight-V100 directories on AFP volume, verified that Host Cache Flushing is disabled, set the following default: defaults write com.apple.desktopservices DSDontWriteNetworkStores true, delete all DS_store files, disabled kerberos for AFP authentication, checked the maxThreads setting for AFP etc etc.
Then I found out that if the iMac /didnt/ had the mountpoint of the external disk (e.g., disk is off or umounted) I could mount all other shares via AFS form the clients. So the problem was within this mountpoint. I made a directory on the external disk and only shared that directory. Yes that worked. But TimeMachine needs a physical disk and I didnt feel like this solution was the way to go. I googled some more. And more. And yes....
All I had to do was *rename* the disc. Rename the disc from “Luchtbed” to “Drijfzand” and then... All worked....
Try this if you have the same problems and dont wont the same troubleshooting.