Description of problem: novajoin-ipa-setup fails with the following traceback. Traceback (most recent call last): File "/usr/libexec/novajoin-ipa-setup", line 70, in <module> console = log_mgr.get_handler('console') AttributeError: 'module' object has no attribute 'get_handler' Version-Release number of selected component (if applicable): RHEL7.6 python-novajoin-1.0.18-2.el7ost.noarch Steps to Reproduce: 1. install python-novajoin on RHEL7.6 2. run a join to create the OTP /usr/libexec/novajoin-ipa-setup --principal admin --password 12345678 --server freeipa-0.redhat.local --realm REDHAT.LOCAL --domain redhat.local --hostname undercloud-0.redhat.local --precreate Actual results: novajoin-ipa-setup returns a traceback Expected results: The undercloud is joined to IPA and a OTP is returned.
Seems this bug was introduced by a change in the IPA client libraries. I was pointed to this commit in freeipa f62a0fdb904d2a4bb1961847e240dbb6df3b0b67 [1] We need to make sure that this works with both the old interface (the current code base) and the newer interface (RHEL 7.5 and 7.6) [1] https://github.com/freeipa/freeipa/commit/f62a0fdb904d2a4bb1961847e240dbb6df3b0b67
This was done to suppress the message "[try %d]: Forwarding '%s' to %s server '%s'" when using the API You can make this version-specific with something like: from ipapython import version if version.NUM_VERSION < 40600: from ipapython.ipa_log_manager import log_mgr console = log_mgr.get_handler('console') console.setLevel(logging.WARN) elif version.NUM_VERSION < 40700: ...something... In 4.7.0 the Forwarding is a debug level message so nothing special is needed. The something is probably going to be a somewhat ugly hack. There are no named handlers so you'll need to iterate through root_handler.handlers to find the StreamHandler for the console. You might be able to, for example, look for handler.stream.name == '<stderr>'... Or live with the Forwarding message. It doesn't hurt anything I just felt it was ugly.
This has significant impact on tls-everywhere topology on all OSP versions which are about to switch to RHEL7.6 (OSP12/13/14). The command (i.e.): "/usr/libexec/novajoin-ipa-setup --principal admin --password 12345678 --server freeipa-0.redhat.local --realm REDHAT.LOCAL --domain redhat.local --hostname undercloud-0.redhat.local --precreate" fails on mentioned AttributeError.
Adding external tracker for RDO patch that bumps novajoin version.
Removing abandoned patch, adding new one.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2019:0088
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 500 days