#8889 [tests] healthcheck 0.9
Closed: fixed 2 years ago by rcritten. Opened 2 years ago by slev.

With recently released freeipa-healthcheck 0.8 -> 0.9 test_source_ipahealthcheck_ipa_host_check_ipahostkeytab fails with:

1   [2021-06-21 05:32:57] test_integration/test_ipahealthcheck.py::TestIpaHealthCheck::test_source_ipahealthcheck_ipa_host_check_ipahostkeytab [ipatests.pytest_ipa.integration.host.Host.master1.IPAOpenSSHTransport] RUN ['python3', '-c', "from ipaplatform.services import knownservices; print(knownservices['dirsrv'].service_instance('IPA-TEST'))"]
1   [2021-06-21 05:32:57] [ipatests.pytest_ipa.integration.host.Host.master1.cmd184] RUN ['python3', '-c', "from ipaplatform.services import knownservices; print(knownservices['dirsrv'].service_instance('IPA-TEST'))"]
1   [2021-06-21 05:32:58] [ipatests.pytest_ipa.integration.host.Host.master1.cmd184] dirsrv@IPA-TEST.service
1   [2021-06-21 05:32:58] [ipatests.pytest_ipa.integration.host.Host.master1.cmd184] Exit code: 0
1   [2021-06-21 05:32:58] [ipatests.pytest_ipa.integration.host.Host.master1.IPAOpenSSHTransport] RUN ['systemctl', 'stop', 'dirsrv@IPA-TEST.service']
1   [2021-06-21 05:32:58] [ipatests.pytest_ipa.integration.host.Host.master1.cmd185] RUN ['systemctl', 'stop', 'dirsrv@IPA-TEST.service']
1   [2021-06-21 05:33:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd185] Exit code: 0
1   [2021-06-21 05:33:00] [ipatests.pytest_ipa.integration.host.Host.master1.IPAOpenSSHTransport] RUN ['ipactl', 'status']
1   [2021-06-21 05:33:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] RUN ['ipactl', 'status']
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] ipa: INFO: The ipactl command was successful
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] Directory Service: STOPPED
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] krb5kdc Service: RUNNING
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] kadmin Service: RUNNING
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] named Service: RUNNING
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] httpd Service: RUNNING
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] ipa-custodia Service: RUNNING
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] pki-tomcatd Service: RUNNING
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] ipa-otpd Service: RUNNING
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] ipa-dnskeysyncd Service: RUNNING
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd186] Exit code: 0
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.IPAOpenSSHTransport] RUN ['ipa-healthcheck', '--source', 'ipahealthcheck.ipa.host', '--check', 'IPAHostKeytab', '--output-type', 'json']
1   [2021-06-21 05:34:00] [ipatests.pytest_ipa.integration.host.Host.master1.cmd187] RUN ['ipa-healthcheck', '--source', 'ipahealthcheck.ipa.host', '--check', 'IPAHostKeytab', '--output-type', 'json']
1   [2021-06-21 05:35:02] [ipatests.pytest_ipa.integration.host.Host.master1.cmd187] Source 'ipahealthcheck.ipa.host' is missing one or more requirements 'krb5kdc, dirsrv'
1   [2021-06-21 05:35:02] [ipatests.pytest_ipa.integration.host.Host.master1.cmd187] Exit code: 1

With https://github.com/freeipa/freeipa-healthcheck/commit/501554e0860cd4bc403858f26a8ec4056a1a2545 dirsrv is mandatory service for IPAHostKeytab check.

Current test_source_ipahealthcheck_ipa_host_check_ipahostkeytab does the most simplest thing to trigger the error (stops the dirsrv). If we still want to check the healthcheck's error message then this test should be modified, for example, by moving away the host's keytab. At least this kind of check will work for freeipa-healthcheck <= 0.9.


master:

  • 3597ab9 ipatests: healthcheck: Update IPAHostKeytab assumptions

ipa-4-9:

  • d744ff3 ipatests: healthcheck: Update IPAHostKeytab assumptions

Metadata Update from @rcritten:
- Issue close_status updated to: fixed
- Issue status updated to: Closed (was: Open)

2 years ago

Metadata Update from @frenaud:
- Issue tagged with: test-failure, tests

2 years ago

Test Failure observed in testing_master_previous PR 1027 Logs

master:

  • c64eaa4 ipatests: Fix for test_source_ipahealthcheck_ipa_host_check_ipahostkeytab

ipa-4-9:

  • 26be7ff ipatests: Fix for test_source_ipahealthcheck_ipa_host_check_ipahostkeytab

Login to comment on this ticket.

Metadata