Bug 910245
| Summary: | [abrt] freeipa-client-3.1.2-1.fc18: ipautil.py:838:get_ipa_basedn:KeyError: 'namingcontexts' | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Ted Henscheid <thenscheid> | ||||||||||
| Component: | freeipa | Assignee: | Rob Crittenden <rcritten> | ||||||||||
| Status: | CLOSED ERRATA | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||||||||
| Severity: | unspecified | Docs Contact: | |||||||||||
| Priority: | unspecified | ||||||||||||
| Version: | 18 | CC: | abokovoy, jboero, mkosek, rcritten, ssorce | ||||||||||
| Target Milestone: | --- | ||||||||||||
| Target Release: | --- | ||||||||||||
| Hardware: | x86_64 | ||||||||||||
| OS: | Unspecified | ||||||||||||
| Whiteboard: | abrt_hash:f33a05535eac74f974299f5085dd66894292857e | ||||||||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||||||||
| Doc Text: | Story Points: | --- | |||||||||||
| Clone Of: | Environment: | ||||||||||||
| Last Closed: | 2013-04-11 10:05:41 UTC | Type: | --- | ||||||||||
| Regression: | --- | Mount Type: | --- | ||||||||||
| Documentation: | --- | CRM: | |||||||||||
| Verified Versions: | Category: | --- | |||||||||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||||||||
| Embargoed: | |||||||||||||
| Attachments: |
|
||||||||||||
Created attachment 696374 [details]
File: backtrace
Created attachment 696375 [details]
File: core_backtrace
Created attachment 696376 [details]
File: environ
Created attachment 696377 [details]
File: smolt_data
Can you provide /var/log/ipaclient-install.log? Can you confirm that the server that it connected to is an IPA server? By checking the Local variables, it is clear, that server returned attribute named NamingContext (CamelCase) while we expected it to be lowercase. I investigated this issue and found out that while 389-ds returns lowercase attributes, OpenLDAP does not: >>> import ldap >>> ldap_url = "ldap://localhost:5389" >>> lh = ldap.initialize(ldap_url) >>> lh.set_option(ldap.OPT_PROTOCOL_VERSION, 3) >>> lh.simple_bind_s("","") (97, [], 1, []) >>> lh.search_ext_s('', scope=ldap.SCOPE_BASE, attrlist=['defaultnamingcontext', 'namingcontexts'])[('', {'namingContexts': ['dc=external,dc=test']})] We need to use our LDAP handling classes in the client discovery, otherwise the client autodiscovery may crash when it tests OpenLDAP server discovered via SRV records. Upstream ticket: https://fedorahosted.org/freeipa/ticket/3446 Fixed upstream: master: 63407ed477035765dda38fbead1353d4f47ac26a Don't download the schema in ipadiscovery cf4b52111d384e8baa250aefe57f21ebda4dad7e Remove unneeded python-ldap imports 664248d5b846321f61e0776b646cca82c5a17884 Use IPAdmin rather than raw python-ldap in migration.py and ipadiscovery.py a0242334feb3da01430f517806768965dabe92c2 Use IPAdmin rather than raw python-ldap in ipa-client-install 91a63cce6203cb8d0cf956d9e30842db365500da Remove ipaserver/ipaldap.py 4e6a2a916d99c4eb9f5e6f5d622517e1b3fe323e Move ipaldap to ipapython I also pushed a fix for ipa-3-1 branch so that it also gets to Fedora 18. 49577a4c66fe4260946f9bf132ad12bdcc213662 Fix client discovery crash freeipa-3.1.3-1.fc18 has been submitted as an update for Fedora 18. https://admin.fedoraproject.org/updates/freeipa-3.1.3-1.fc18 Package freeipa-3.1.3-1.fc18: * should fix your issue, * was pushed to the Fedora 18 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing freeipa-3.1.3-1.fc18' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2013-4460/freeipa-3.1.3-1.fc18 then log in and leave karma (feedback). Package freeipa-3.1.3-2.fc18: * should fix your issue, * was pushed to the Fedora 18 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing freeipa-3.1.3-2.fc18' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2013-4460/freeipa-3.1.3-2.fc18 then log in and leave karma (feedback). Package freeipa-3.1.3-4.fc18: * should fix your issue, * was pushed to the Fedora 18 testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing freeipa-3.1.3-4.fc18' as soon as you are able to. Please go to the following url: https://admin.fedoraproject.org/updates/FEDORA-2013-4460/freeipa-3.1.3-4.fc18 then log in and leave karma (feedback). freeipa-3.1.3-4.fc18 has been pushed to the Fedora 18 stable repository. If problems still persist, please make note of it in this bug report. Just a 2ndary note on this: I was getting this error installing clients in an environment with existing DNS. Maybe it should be a little more obvious, but specifying ipa-client-install --server [server] --domain [domain] manually was my duh workaround. Just in case anybody else encounters this running ipa-client-install with hopes DNS is already set up correctly. Thanks! JohnnyB |
Version-Release number of selected component: freeipa-client-3.1.2-1.fc18 Additional info: cmdline: /usr/bin/python -E /usr/sbin/ipa-client-install --noac --principal=Adminstrator -W dso_list: freeipa-python-3.1.2-1.fc18.x86_64 executable: /usr/sbin/ipa-client-install kernel: 3.7.4-204.fc18.x86_64 uid: 0 Truncated backtrace: ipautil.py:838:get_ipa_basedn:KeyError: 'namingcontexts' Traceback (most recent call last): File "/usr/sbin/ipa-client-install", line 2360, in <module> sys.exit(main()) File "/usr/sbin/ipa-client-install", line 2346, in main rval = install(options, env, fstore, statestore) File "/usr/sbin/ipa-client-install", line 1708, in install ret = ds.search(domain=options.domain, server=options.server, hostname=hostname, ca_cert_path=get_cert_path(options.ca_cert_file)) File "/usr/lib/python2.7/site-packages/ipaclient/ipadiscovery.py", line 231, in search ldapret = self.ipacheckldap(self.server, self.realm, ca_cert_path=ca_cert_path) File "/usr/lib/python2.7/site-packages/ipaclient/ipadiscovery.py", line 299, in ipacheckldap basedn = get_ipa_basedn(lh) File "/usr/lib/python2.7/site-packages/ipapython/ipautil.py", line 838, in get_ipa_basedn contexts = entries[0][1]['namingcontexts'] KeyError: 'namingcontexts' Local variables in innermost frame: conn: <ldap.ldapobject.SimpleLDAPObject instance at 0x19bccf8> entries: [('', {'namingContexts': ['DC=henscheid,DC=com', 'CN=Configuration,DC=henscheid,DC=com', 'CN=Schema,CN=Configuration,DC=henscheid,DC=com', 'DC=DomainDnsZones,DC=henscheid,DC=com', 'DC=ForestDnsZones,DC=henscheid,DC=com'], 'defaultNamingContext': ['DC=henscheid,DC=com']})]