Bug 1986329

Summary: ipa-server install failure without DNS
Product: Red Hat Enterprise Linux 9 Reporter: Varun Mylaraiah <mvarun>
Component: ipaAssignee: Florence Blanc-Renaud <frenaud>
Status: CLOSED CURRENTRELEASE QA Contact: ipa-qe <ipa-qe>
Severity: unspecified Docs Contact:
Priority: high    
Version: 9.0CC: cheimes, ksiddiqu, myusuf, pvoborni, rcritten, ssidhaye, tscherf
Target Milestone: betaKeywords: Regression, Triaged
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: ipa-4.9.6-5.el9 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-12-07 21:30:47 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Varun Mylaraiah 2021-07-27 09:41:30 UTC
Description of problem:
ipa-server setup without DNS is failing
Error: 
Synchronizing time
No SRV records of NTP servers found and no NTP server or pool address was provided.
Using default chrony configuration.
Attempting to sync time with chronyc.
Process chronyc waitsync failed to sync time!
Unable to sync time with chrony server, assuming the time is in sync. Please check that 123 UDP port is opened, and any time server is on network.
Warning: IPA was unable to sync time with chrony!
         Time synchronization is required for IPA to work correctly
user 'named' not found


Version-Release number of selected component (if applicable):
ipa-server-4.9.6-4.el9.x86_64
389-ds-base-2.0.6-3.el9.x86_64

How reproducible:
100%

Steps to Reproduce:
#yum install ipa-server -y


[root@master ~]# ipa-server-install --hostname=master.ipadomain.test -r IPADOMAIN.TEST -n ipadomain.test --ip-address=10.0.103.88 -p Secret123 -a Secret123 -U

The log file for this installation can be found in /var/log/ipaserver-install.log
==============================================================================
This program will set up the IPA Server.
Version 4.9.6

This includes:
  * Configure a stand-alone CA (dogtag) for certificate management
  * Configure the NTP client (chronyd)
  * Create and configure an instance of Directory Server
  * Create and configure a Kerberos Key Distribution Center (KDC)
  * Configure Apache (httpd)
  * Configure the KDC to enable PKINIT


The IPA Master Server will be configured with:
Hostname:       master.ipadomain.test
IP address(es): 10.0.103.88
Domain name:    ipadomain.test
Realm name:     IPADOMAIN.TEST

The CA will be configured with:
Subject DN:   CN=Certificate Authority,O=IPADOMAIN.TEST
Subject base: O=IPADOMAIN.TEST
Chaining:     self-signed

Disabled p11-kit-proxy
Synchronizing time
No SRV records of NTP servers found and no NTP server or pool address was provided.
Using default chrony configuration.
Attempting to sync time with chronyc.
Process chronyc waitsync failed to sync time!
Unable to sync time with chrony server, assuming the time is in sync. Please check that 123 UDP port is opened, and any time server is on network.
Warning: IPA was unable to sync time with chrony!
         Time synchronization is required for IPA to work correctly
user 'named' not found
The ipa-server-install command failed. See /var/log/ipaserver-install.log for more information


[root@master ~]# id named
id: ‘named’: no such user



Expected results:
ipa-server setup without DNS should work

Additional info:
ipa-server setup without DNS works fine after ipa-server with DNS is install and uninstall

Comment 2 Christian Heimes 2021-07-27 10:02:25 UTC
The issue was introduce by one of these commits:

https://pagure.io/freeipa/c/16e1cbdc5e2192e47f11df4148069a8b7e2220f7
https://pagure.io/freeipa/c/1c4ae37293c31c5030556e8464099cad22d49db8

We never ran into the issue during testing because our test infra has ipa-server-dns and named installed by default. I recommend to introduce a test scenario without ipa-server-dns installed and with named user and group absent.

Comment 3 François Cami 2021-07-27 10:05:13 UTC
Upstream ticket:
https://pagure.io/freeipa/issue/8936

Comment 4 Christian Heimes 2021-07-27 14:02:22 UTC
Upstream fix: https://github.com/freeipa/freeipa/pull/5927

Comment 6 Rob Crittenden 2021-07-30 12:59:43 UTC
Fixed upstream
master:
https://pagure.io/freeipa/c/8170659d15f11e9eb3b66f25109c6ce271cdcff3

Comment 7 Rob Crittenden 2021-08-02 13:54:40 UTC
Fixed upstream
ipa-4-9:
https://pagure.io/freeipa/c/a1eb13cdbc109da8c028bb886a1207ea2cc23cee

Comment 14 Mohammad Rizwan 2021-08-20 11:01:13 UTC
version:
ipa-server-4.9.6-5.el9

============================= test session starts ==============================
platform linux -- Python 3.9.6, pytest-6.2.2, py-1.10.0, pluggy-0.13.1 -- /usr/bin/python3
cachedir: /home/cloud-user/.pytest_cache
metadata: {'Python': '3.9.6', 'Platform': 'Linux-5.14.0-0.rc4.35.el9.1.x86_64-x86_64-with-glibc2.34', 'Packages': {'pytest': '6.2.2', 'py': '1.10.0', 'pluggy': '0.13.1'}, 'Plugins': {'metadata': '1.7.0', 'multihost': '3.0', 'sourceorder': '0.5', 'html': '3.1.1'}}
rootdir: /usr/lib/python3.9/site-packages/ipatests
plugins: metadata-1.7.0, multihost-3.0, sourceorder-0.5, html-3.1.1
collecting ... collected 1 item

test_integration/test_installation.py::TestInstallWithoutNamed::test_replica0_install PASSED [100%]

=============================== warnings summary ===============================
../pytest_sourceorder.py:31
  /usr/lib/python3.9/site-packages/pytest_sourceorder.py:31: PytestUnknownMarkWarning: Unknown pytest.mark.source_order - is this a typo?  You can register custom marks to avoid this warning - for details, see https://docs.pytest.org/en/stable/mark.html
    cls = pytest.mark.source_order(cls)

-- Docs: https://docs.pytest.org/en/stable/warnings.html
---------------- generated xml file: /home/cloud-user/junit.xml ----------------
----------- generated html file: file:///home/cloud-user/report.html -----------
================== 1 passed, 1 warning in 1305.70s (0:21:45) ===================

Automaton passed, Hence marking the bug as verified. report.html is attached for reference.