Open m1ch69 opened 2 years ago
Is the problem with ansible-freeipa or with FreeIPA?
If the problem is (or seems to be) with ansible-freeipa, we need some more information about your setup. Please provide the package versions for:
Version 4.6.8.
Running the ipaclient_join
module, I get the following:
fatal: [server1.example]: FAILED! => {"changed": false, "msg": "Cannot obtain CA certificate\n'ldap://idm.example' doesn't have a certificate."}
Checks the logs /var/log/ipaclient-install.log
fatal: [server1.example]: FAILED! => {"changed": false, "msg": "Cannot obtain CA certificate\n'ldap://idm.example' doesn't have a certificate."}
DEBUG trying to retrieve CA cert via LDAP from idm.example
DEBUG retrieving schema for SchemaCache url=ldap://idm.example:389 conn=<ldap.ldapobject.SimpleLDAPObject instance at 0x7fbb854a2950>
ERROR unable to convert the attribute u'cacertificate;binary' value '0. BINARY DATA' to type <class 'cryptography.x509.base.Certificate'>
DEBUG get_ca_certs_from_ldap() error: unsupported format character '\' (0x5c) at index 723
DEBUG unsupported format character '\' (0x5c) at index 723
To fix it first convert the existing CA certificate into DER format:
$ openssl x509 -in /etc/ipa/ca.crt -out /tmp/ca.der -outform der
Then remove the current value from LDAP and replace it with the correct format (replace the domain to match your own):
$ ldapmodify -x -D 'cn=directory manager' -W
Enter LDAP Password:
dn: cn=CAcert,cn=ipa,cn=etc,dc=example
changetype: modify
delete: cACertificate;binary
-
add: cACertificate;binary
cACertificate;binary:< file:///tmp/ca.der
@tscherf This is the first time this has happened, though the server2
does not have this issue, or any other of my clients/servers. I've downgraded pyasn1
and pyasn-modules
on server1
to match server2
using python2
(pyasn1: 0.1.9
and pyasn1-modules: 0.0.8
.
This works flawless on server2, but not on server1...
Short:
Running the role
ipaclient
on two identical CentOS 7 servers. When trying to runipa-client-install
manually I get this:While on the other server this works great.