Want to highlight a helpful answer? Upvote!

Did someone help you, or did an answer or User Tip resolve your issue? Upvote by selecting the upvote arrow. Your feedback helps others! Learn more about when to upvote >

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Slow AFP login

This started as a Lion Server issue but the problem is still present after upgrading to Mountain Lion yesterday. Logins to sharepoints via AFP take about ~30 seconds for authentication. That's 30 secodns after submitting username/password credentials before being presented with a list of sharepoints to choose from. It's the same delay whether selecting the sever from the sidebar or using a URL/IP address in connect to server. Strangly though, this delay only exists for the connections to the server on the LAN. Connections via "VPNing" into the network and then using connect to server with the same IP address do not get any delay at all. Same when enabling a port forward for AFP connections. Only connections from clients on the same subnet as the server are affected. The issue only affects OD accounts. Local accounts on the server always login at normal speeds.


There are multiple external services that authenticate users from this OD server including a Kerio Connect mail server and a wordpress installation to name a few. All do so without any errors or slow downs.


There are no errors in any od/password server/kerberos log I can find to explain the slow down. Using a Bonjour browser confirms on the correct IPv4/6 addresses are being advertised for the AFP service.


Configuration:

ML 10.8.3

OD Master with one remote replica (also experiencing same symptom of fast via VPN and slow on LAN)

Static IP, correct forward and reverse DNS setup (changeip -checkhostname reports success)

DNS is external, not on same server

Only file sharing, caching, time machine and OD are running on the server


Troubleshooting so far:

This server started life as a Lion server and everything was great. Then there was an ISP change. Once the new internet connection was live the server had lots of problems authenticating users for a couple of hours. Then the problems went away by themselves while we were still troubleshooting. Nothing had changed, just suddenly everything was authenticating successfully. But AFP authentication was slow with this 30 second delay.


The server has been archived, demoted to standalone, promoted back to a master and restored. The issue is unchanged. The archive has been restored to another server setup with the same configuration (hostname, network settings, etc) in a test environment and the issue is not present so it's not something contained within the archive.


A strange thing happened after the restore however. A few hours after the restore, the server app would only see local users and groups. Workgroup manager could see the directory users but would not accept the directory admin credentials even though the same password worked on the replica. Using command line tools to reset that password to it's correct value didn't work either. So the server was upgraded to Mountain Lion. After the upgrade the new server app could see all the directory accounts and the admin account password was being accepted by the 10.8 version of workgroup manager.


I'm at a complete loss to understand why the authentication process would have this delay for clients on the LAN vs clients connecting via a VPN connection or port forwarding from the internet. Anyone ever seen anything like this or have any tips on which logs to look at to get further information?

Mac mini, OS X Server, 10.8.3

Posted on May 1, 2013 5:30 PM

Reply
4 replies

May 2, 2013 11:19 PM in response to Linc Davis

It didn't solve the problem but it did make me think about looking more closely at the clients. I hadn't done that because the issue is affecting all of them equally including my machine which works fine connecting to other servers.


I found some useful entries in the system.log file when one of the client machines was trying trying to authenticate to the server.


May 2 16:28:51 10-10-10-403.tpgi.com.au NetAuthSysAgent[1269]: NAHSelectionAcquireCredential complete: iakerb 957F00BCA6D299DB37F35877063A97BD - testuser: GSSCred: 0x7f8fb362f600 <MC: iakerb testaccount@WELLKNOWN:COM.APPLE.LKDC>

May 2 16:28:52 10-10-10-403.tpgi.com.au NetAuthSysAgent[1269]: NAHSelectionAcquireCredential The operation couldn’t be completed. (com.apple.NetworkAuthenticationHelper error -1765328228 - acquire_kerberos failed testaccount@OFFICE.EXAMPLE.COM: -1765328228 - unable to reach any KDC in realm OFFICE.EXAMPLE.COM)

May 2 16:29:24 10-10-10-403.tpgi.com.au NetAuthSysAgent[1269]: NAHSelectionAcquireCredential The operation couldn’t be completed. (com.apple.NetworkAuthenticationHelper error -1765328228 - acquire_kerberos failed testaccount@TPGI.COM.AU: -1765328228 - unable to reach any KDC in realm TPGI.COM.AU)


This all seems to suggest to me that the computer checks for a kdc realm on the machine that is maintained by Apple. Then it tries OFFICE.EXAMPLE.COM then TPGI.COM.AU. TPG is the ISP at this site and reverse dns lookups of the WAN IP address have tpgi.com.au at the end of them so it looks like the final fall back is that kerberos on the computer is doing a reverse dns of the wan ip and doing a hail mary looking for a kdc.


What's interesting is the one in the middle. The actual realm name is SERVER.OFFICE.EXAMPLE.COM and the server's address is server.office.example.com. The only place that OFFICE.EXAMPLE.COM exists on it's own is in the external DNS (it's an A record for the WAN IP address to allow simple remote connections) and as the search domain in the network DHCP configuration (option 15 to be specific).


Anyone know the process of how a Mountain Lion client identifies realms to look for during afp authentication?

Slow AFP login

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.