Hide Forgot
Description of problem: Replace ERROR: cannot connect to "http://localhost:8888/ipa/json': [Errno 111] Connection refused" with "IPA is not configured on this system" Version-Release number of selected component (if applicable): ipa-server-4.4.0-7.el7.x86_64 How reproducible: Always. Steps to Reproduce: 1. Ensure all the packages related to ipa-server is installed. 2. Ensure that ipa-server is not installed. 3. Now run the below commands. Actual results: [root@ipaserver ~]# ipa trust-find ipa: ERROR: cannot connect to 'http://localhost:8888/ipa/json': [Errno 111] Connection refused [root@ipaserver ~]# ipa-advise trying http://localhost:8888/ipa/json Forwarding 'schema' to json server 'http://localhost:8888/ipa/json' cannot connect to 'http://localhost:8888/ipa/json': [Errno 111] Connection refused The ipa-advise command failed. [root@ipaserver ~]# ipa-managed-entries status Unexpected error NetworkError: cannot connect to 'http://localhost:8888/ipa/json': [Errno 111] Connection refused [root@ipaserver ~]# ipa-replica-install Configuring client side components WARNING: ntpd time&date synchronization service will not be configured as conflicting service (chronyd) is enabled Use --force-ntpd option to disable it and force configuration of ntpd One of password / principal / keytab is required. Installation failed. Rolling back changes. IPA client is not configured on this system. Removing client side components IPA client is not configured on this system. ipa.ipapython.install.cli.install_tool(Replica): ERROR Configuration of client side components failed! ipa.ipapython.install.cli.install_tool(Replica): ERROR The ipa-replica-install command failed. See /var/log/ipareplica-install.log for more information [root@ipaserver ~]# ipa-compat-manage An IPA server to update cannot be found. Has one been configured yet? The error was: IPA realm not found in DNS, in the config file (/etc/ipa/default.conf) or on the command line. [root@ipaserver ~]# ipa-join cannot open configuration file /etc/ipa/default.conf Unable to determine IPA server from /etc/ipa/default.conf Expected results: Basically all the commands, if possible should check if ipa server is installed in the first place and if not then it should display message like 'IPA is not configured on this system" rather than displaying Network error or any other message. This is for uniformity across all commands behaviour when ipa-server is not installed. Some of the commands which displayed proper message. [root@ipaserver ~]# ipa-nis-manage IPA is not configured on this system. [root@ipaserver ~]# ipa-dns-install The log file for this installation can be found in /var/log/ipaserver-install.log IPA is not configured on this system. [root@ipaserver ~]# ipa-adtrust-install The log file for this installation can be found in /var/log/ipaserver-install.log IPA is not configured on this system. [root@ipaserver ~]# ipa-ca-install IPA server is not configured on this system. [root@ipaserver ~]# ipa-backup IPA is not configured on this system. The ipa-backup command failed. See /var/log/ipabackup.log for more information [root@ipaserver ~]# ipa-client-automount IPA client is not configured on this system. [root@ipaserver ~]# ipa-dns-install The log file for this installation can be found in /var/log/ipaserver-install.log IPA is not configured on this system. [root@ipaserver ~]# ipa-kra-install IPA is not configured on this system. The ipa-kra-install command failed. See /var/log/ipaserver-kra-install.log for more information [root@ipaserver ~]# ipa-server-upgrade IPA is not configured on this system. The ipa-server-upgrade command failed. See /var/log/ipaupgrade.log for more information [root@ipaserver ~]# ipa-winsync-migrate IPA is not configured on this system. Additional info:
Upstream ticket: https://fedorahosted.org/freeipa/ticket/6261
*** Bug 1456595 has been marked as a duplicate of this bug. ***
Fixed upstream master: https://pagure.io/freeipa/c/cac3475a0454b730d6e5b2093c2e63d395acd387
Fixed upstream: ipa-4-5: 73b381e Changing how commands handles error when it can't connect to IPA server
Tested on Red Hat Enterprise Linux Server release 7.6 Beta (Maipo) using ipa-server-4.6.4-3.el7.x86_64 sssd-1.16.2-11.el7.x86_64 389-ds-base-1.3.8.4-9.el7.x86_64 krb5-server-1.15.1-34.el7.x86_64 pki-server-10.5.9-4.el7.noarch selinux-policy-3.13.1-211.el7.noarch Certain commands are still not displaying the change i.e 'IPA client is not configured on this system'. [root@master ~]# ipa-advise 'Env' object has no attribute 'server' The ipa-advise command failed. [root@master ~]# ipa-server-upgrade IPA server upgrade failed: Inspect /var/log/ipaupgrade.log and run command ipa-server-upgrade manually. Unexpected error - see /var/log/ipaupgrade.log for details: AttributeError: 'Env' object has no attribute 'basedn' The ipa-server-upgrade command failed. See /var/log/ipaupgrade.log for more information [root@master ~]# ipa-join cannot open configuration file /etc/ipa/default.conf Unable to determine IPA server from /etc/ipa/default.conf [root@master ~]# ipa-compat-manage status Directory Manager password: Unexpected error AttributeError: 'Env' object has no attribute 'basedn' [root@master ~]# ipa-compat-manage enable Directory Manager password: Unexpected error AttributeError: 'Env' object has no attribute 'basedn' [root@master ~]# ipa-compat-manage disable Directory Manager password: Unexpected error AttributeError: 'Env' object has no attribute 'basedn' [root@master ~]# ipa-replica-install WARNING: conflicting time&date synchronization service 'chronyd' will be disabled in favor of ntpd Configuring client side components One of password / principal / keytab is required. The ipa-client-install command failed. See /var/log/ipaclient-install.log for more information Removing client side components IPA client is not configured on this system. The ipa-client-install command failed. See /var/log/ipaclient-uninstall.log for more information Your system may be partly configured. Run /usr/sbin/ipa-server-install --uninstall to clean up. ipapython.admintool: ERROR Configuration of client side components failed! ipapython.admintool: ERROR The ipa-replica-install command failed. See /var/log/ipareplica-install.log for more information
Fixed upstream master: https://pagure.io/freeipa/c/a5a619abc19af23cfb25d5ce35deb4338cee7822 https://pagure.io/freeipa/c/10c6258929510cb99aa162c95a57b26184a0faca
Fixed upstream ipa-4-7: https://pagure.io/freeipa/c/9f2d8f5b587dd6e63f464dcf696bb3b5f3af2c56 https://pagure.io/freeipa/c/8cf6b6ea095e4270b0a7c3fa56b8018e05e9045b
Fixed upstream ipa-4-6: https://pagure.io/freeipa/c/af2ee7ae345037a30164043bddb247b2bbeb60b6 https://pagure.io/freeipa/c/95af5dc29ff775296d34cc5dc9260105457e0c80 https://pagure.io/freeipa/c/9182917280a5c2590fa677729db54b38a9ac4d1f
Fixed upstream ipa-4-5: https://pagure.io/freeipa/c/2098c9fbb16df0aed2d4a614838af79fec3d7130 https://pagure.io/freeipa/c/a84f17a116bc183f8f2ac6353f6348e511c62471
Automation: ipatests/test_cmdline/test_cli.py::test_command_ipa_not_installed
Reproducible on [root@master ~]# rpm -q ipa-server ipa-client ipa-server-trust-ad ipa-server-4.5.4-10.el7_5.1.x86_64 ipa-client-4.5.4-10.el7_5.1.x86_64 ipa-server-trust-ad-4.5.4-10.el7_5.1.x86_64 [root@master ~]# ipa-run-tests -vvv test_cmdline/test_cli.py -rxXs ... ... test_cmdline/test_cli.py::test_command_ipa_not_installed[args0-1-IPA client is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args1-1-IPA client is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args2-1-IPA client is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args3-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args4-1-IPA is not configured on this system] FAILED test_cmdline/test_cli.py::test_command_ipa_not_installed[args5-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args6-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args7-1-IPA server is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args8-1-IPA is not configured on this system] FAILED test_cmdline/test_cli.py::test_command_ipa_not_installed[args9-1-IPA is not configured on this system] FAILED test_cmdline/test_cli.py::test_command_ipa_not_installed[args10-4-IPA is not configured] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args11-1-IPA is not configured on this system] FAILED test_cmdline/test_cli.py::test_command_ipa_not_installed[args12-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args13-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args14-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args15-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args16-1-IPA is not configured on this system] FAILED test_cmdline/test_cli.py::test_command_ipa_not_installed[args17-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args18-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args19-1-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args20-1-IPA is not configured on this system] PASSED Verified on: [root@master ~]# rpm -q ipa-server ipa-client ipa-server-trust-ad ipa-server-4.6.4-7.el7.x86_64 ipa-client-4.6.4-7.el7.x86_64 ipa-server-trust-ad-4.6.4-7.el7.x86_64 [root@master ~]# ipa-run-tests -vvv test_cmdline/test_cli.py -rxXs ... ... test_cmdline/test_cli.py::test_command_ipa_not_installed[args0-1-None-IPA client is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args1-1-None-IPA client is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args2-1-None-IPA client is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args3-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args4-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args5-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args6-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args7-1-None-IPA server is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args8-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args9-1-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args10-4-None-IPA is not configured] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args11-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args12-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args13-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args14-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args15-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args16-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args17-1-IPA is not configured on this system-None] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args18-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args19-2-None-IPA is not configured on this system] PASSED test_cmdline/test_cli.py::test_command_ipa_not_installed[args20-1-None-IPA is not configured on this system] PASSED
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-2018:3187