<html>We're seeing problems with some hosts which appears to be caused by the new ad_maximum_machine_account_password_age support in sssd (which notes that a recent adcli is required for this functionality).<br /><br />For some hosts, there is one set of credentials in krb5.keytab, and AD indicates that the machine account password was changed 30 days after the timestamp on those credentials. On other hosts, we see a second set of credentials,<br />30 days newer than the first set, whose timestamp matches AD's PasswordLastSet property for that host. For the latter set, users report that authentication works some of the time.<br /><br />It may be relevant that this is a large multi-site domain, and we've also found that some hosts have been set up with "ad_site" specified in sssd.conf, pointing at a site that is incorrect (in that it is not the closest site).<br /><br />Both sssd and adcli are out of date on the hosts we're troubleshooting, but I don't see any bugzilla entries, mailing list topics, or release notes that indicate that this is a known problem that has been fixed.<br /><br />Which components should I be looking at when diagnosing this problem further, and what log settings might be most useful as I'm hunting down the problem?<br /><br /><br /><br />Symptoms for host1:<br /><br />System keytab contains old credentials.<br /><br /> [root@host1 ~]# klist -kt /etc/krb5.keytab<br /> Keytab name: FILE:/etc/krb5.keytab<br /> KVNO Timestamp Principal<br /> ---- ------------------- ------------------------------------------------------<br /> 4 05/04/2018 11:10:30 host/host1.domain.lan@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 host/HOST1@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 host/host1.domain.lan@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 host/HOST1@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 host/host1.domain.lan@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 host/HOST1@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 host/host1.domain.lan@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 host/HOST1@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 host/host1.domain.lan@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 host/HOST1@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 HOST1$@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 HOST1$@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 HOST1$@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 HOST1$@DOMAIN.LAN<br /> 4 05/04/2018 11:10:30 HOST1$@DOMAIN.LAN<br /><br />The date of the new credentials matches the “PasswordLastSet” property on that host in AD:<br /><br /> PS H:\> Get-ADComputer -Identity host1 -Properties name,LastLogonDate,PasswordLastSet,modified,modifyTimeStamp<br /><br /> DistinguishedName : CN=HOST1,OU=Build,OU=DOMAIN_DevIT,DC=domain,DC=lan<br /> DNSHostName : host1.domain.lan<br /> Enabled : True<br /> LastLogonDate : 6/1/2018 10:41:59 AM<br /> Modified : 6/3/2018 3:27:10 PM<br /> modifyTimeStamp : 6/3/2018 3:27:10 PM<br /> Name : HOST1<br /> ObjectClass : computer<br /> ObjectGUID : d21d7f72-xxxx-xxxx-xxxx-aac9cf895d31<br /> PasswordLastSet : 6/3/2018 3:26:59 PM<br /> SamAccountName : HOST1$<br /> SID : S-1-5-21-xxxxxxxxxx-xxxxxxxxxx-xxxxxxxxx-xxxxxx<br /> UserPrincipalName :<br /> UserPrincipalName :<br /><br />adcli and sssd are out of date on that host:<br /><br /> [root@host1 ~]# rpm -q adcli sssd<br /> adcli-0.8.1-3.el7.x86_64<br /> sssd-1.15.2-50.el7_4.11.x86_64<br /><br />The current versions are:<br /><br /> $ yum list adcli sssd<br /> …<br /> Installed Packages<br /> sssd.x86_64 1.16.0-19.el7 @base<br /> Available Packages<br /> adcli.x86_64 0.8.1-4.el7 base<br /><br />Logs include:<br /><br /> [sssd[ldap_child[1271]]]: Failed to initialize credentials using keytab [MEMORY:/etc/krb5.keytab]: Preauthentication failed. Unable to create GSSAPI-encrypted LDAP connection.<br /> [sssd[ldap_child[1271]]]: Preauthentication failed<br /><br /><br /><br />Symptoms for host2:<br /><br />System keytab contains new credentials, 30 days newer than a previous set.<br /><br /> [it@host2 ~]$ sudo klist -kt /etc/krb5.keytab<br /> [sudo] password for it:<br /> Keytab name: FILE:/etc/krb5.keytab<br /> KVNO Timestamp Principal<br /> ---- ------------------- ------------------------------------------------------<br /> 3 05/21/2018 11:50:41 host/host2.domain.lan@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 host/host2.domain.lan@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 host/host2.domain.lan@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 host/host2.domain.lan@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 host/host2.domain.lan@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 host/HOST2@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 host/HOST2@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 host/HOST2@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 host/HOST2@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 host/HOST2@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 HOST2$@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 HOST2$@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 HOST2$@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 HOST2$@DOMAIN.LAN<br /> 3 05/21/2018 11:50:41 HOST2$@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 HOST2$@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 HOST2$@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 HOST2$@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 HOST2$@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 HOST2$@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/host2.domain.lan@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/host2.domain.lan@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/host2.domain.lan@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/host2.domain.lan@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/host2.domain.lan@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/HOST2@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/HOST2@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/HOST2@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/HOST2@DOMAIN.LAN<br /> 4 06/21/2018 08:09:02 host/HOST2@DOMAIN.LAN<br /><br /><br />The date of the new credentials matches the “PasswordLastSet” property on that host in AD:<br /><br /> PS H:\> Get-ADComputer -Identity host2 -Properties name,LastLogonDate,PasswordLastSet,modified,modifyTimeStamp<br /><br /> DistinguishedName : CN=HOST2,OU=Build,OU=DOMAIN_DevIT,DC=domain,DC=lan<br /> DNSHostName : host2.domain.lan<br /> Enabled : True<br /> LastLogonDate : 7/6/2018 10:51:11 PM<br /> Modified : 7/6/2018 10:52:06 PM<br /> modifyTimeStamp : 7/6/2018 10:52:06 PM<br /> Name : HOST2<br /> ObjectClass : computer<br /> ObjectGUID : f70a3bab-xxxx-xxxx-xxxx-932457b18768<br /> PasswordLastSet : 6/21/2018 8:09:02 AM<br /> SamAccountName : HOST2$<br /> SID : S-1-5-21-xxxxxxxxxx-xxxxxxxxxx-xxxxxxxxx-xxxxxx<br /> UserPrincipalName :<br /><br />adcli and sssd are out of date on that host:<br /><br /> [root@host2 ~]# rpm -q adcli sssd<br /> adcli-0.8.1-3.el7.x86_64<br /> sssd-1.14.0-43.el7_3.14.x86_64<br /><br />The current versions are:<br /><br /> $ yum list adcli sssd<br /> …<br /> Installed Packages<br /> sssd.x86_64 1.16.0-19.el7 @base<br /> Available Packages<br /> adcli.x86_64 0.8.1-4.el7 base<br /><br />Logs include:<br /><br /> [sssd[krb5_child[21580]]]: Preauthentication failed<br /><br /> </html>