Hi All,
I know this is an age-old problem with a million different possible fixes out there, but it's driving me nuts and hopefully somebody has seen this particular flavor before. My apologies in advance for the super-long post, but there is a lot going on here.
We have a fleet of Macs deployed in computer labs on campus (All Yosemite builds) that are experiencing extremely slow login times when a user attempts to log in with their domain account for the first time. Anywhere from two minutes to ten minutes. We are not using network-based home folders, and we are not using mobile accounts.
One thing that we found is that by switching to the time server in our environment rather than using the default time.apple.com server is that we have managed to get subsequent, new-user logins to get to a usable desktop within 25 seconds. Until the machine is rebooted. Then we're back to the same situation where the first new user account that logs in has to wait a couple of minutes to get to a usable desktop.
So it goes something like this:
Newuser1 sits down at a freshly booted Mac and logs in. It takes about one minute forty five seconds for the login to process and for the user to get to a usable desktop. During this time, the default user template is being applied, home directory created, etc., etc. Newuser1 then logs out of the computer.
Newuser2, logs into the computer and gets to a usable desktop 25 seconds later. When newuser2 is done, he/she reboots the computer.
If either of the previous users come back to the computer after it has been rebooted, they will be able to log in and get to their desktop in about 25 seconds (we clear the home folders once a week). However, if a user who already has a home folder logs into the machine first, and then Newuser3 comes along, newuser3 will have to wait for 1:45 to get to the desktop. After that, additional new users will be able to get to the usable desktop within 25 seconds.
So all of this says to me that when the first new user after a reboot logs in and waits the 1:45 to get to the desktop, something is happening in the background that becomes cached/remembered and available to the process of creating additional new user home folders, and stays available until the next time the machine is rebooted, and then the process starts all over again. I just can't figure out what, and my head is getting sore from being beaten against the wall over this problem.
In Directory Utility < Services my AD bind settings are the following:
User Experience:
Create mobile account at login - unchecked
Force local home directory on startup disk - checked
Use UNC path from Active Directory to derive network home location - unchecked
Mappings: All set to defaults
Administrative:
Prefer this domain server - unchecked (and I have been strongly advised not to put anything in there)
Allow authentication from any domain in the forest - unchecked
In Directory Services < Search Policies I have removed all references to "All Domains" and have explicitly defined the domain that I want people logging in from.
I have also defined my domain in System Preferences < Network < DNS < Search Domains. I tried adding "local" and/or ".local" to into the Search Domains but it had no effect.
I also tried changing the timeout options for the ActiveDirectory.plist file, (I had to find the plist file first because it's not in the same place as most of the articles say it is), but that seemed to have no effect either.
Now, I will also say that my default user template is ~400 MB. It could be smaller, but I don't think that template in and of itself is the problem, because if I create a new, local user, that user can log into the machine in 25 seconds or less. It seems like this is somewhat related to the network login, but I just can't find the connection.
I have had our network engineering team monitor the traffic happening on one of my test machines, and while they can see a bunch of LDAP packet errors happening during login, but the percentage of packet errors is not consistent with the amount of time that it takes to log in, so none of us think that those errors realistically are the problem, and there are no other smoking guns in the traffic logs.
Has anybody run into a similar situation, and if so, any ideas?
Thanks in advance for any help/insights.
