#4342 ipa-server-install fails when using a single part domain of 'test'
Closed: Fixed None Opened 9 years ago by nkinder.

I was setting up two fresh Fedora 20 VMs as FreeIPA servers, and the installation consistently failed when using the following steps:

  • install F20 ('Infrastructure Server' package selection)
  • yum update -y
  • yum install -y freeipa-server bind-dyndb-ldap
  • set the hostname to 'freeipa.test' in /etc/hostname (note that I did not edit /etc/hosts)
  • reboot
  • ipa-server-install --setup-dns

The install progresses pretty far, but it fails when it tries to restart the services. I don't have the exact installer output around anymore, but there was nothing very useful. I do still have the output from the journal though:

---------------------------------------------------------------------------------------
May 08 17:57:20 freeipa.test ipactl[4395]: Starting Directory Service
May 08 17:57:20 freeipa.test ipactl[4395]: Starting krb5kdc Service
May 08 17:57:20 freeipa.test ipactl[4395]: Starting kadmin Service
May 08 17:57:20 freeipa.test ipactl[4395]: Starting named Service
May 08 17:57:20 freeipa.test systemd[1]: ipa.service: main process exited, code=exited, status=1/FAILURE
May 08 17:57:20 freeipa.test systemd[1]: Failed to start Identity, Policy, Audit.
-- Subject: Unit ipa.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit ipa.service has failed.
-- 
-- The result is failed.
May 08 17:57:20 freeipa.test systemd[1]: Unit ipa.service entered failed state.
---------------------------------------------------------------------------------------

I didn't see anything of interest in any of the other logs.

After running 'ipa-server-install --uninstall' and changing my hostname to 'host.freeipa.test', the install completed successfully on both of my test VMs.


I think this is a known issue. Single item domains are not supported. Mail attribute syntax validation chokes on it. At least that has been in the past. I think it is even documented that such setup is not supported.

Should probably check for that immediately at initial install and error out rather than go all the way down to named install.

I did come across the ticket that Dmitri mentions, but this failure seemed different. Not supporting single part domains is fine, but the installer should validate the domain when it is entered and refuse to continue.

In my test, this choked on DS configuration (deadlock?):

# ipa-server-install -p kokos123 -a kokos123 --setup-dns --ip-address 10.x.x.x --hostname ipa.rhel71
...
Configuring directory server (dirsrv): Estimated time 1 minute
  [1/38]: creating directory server user
  [2/38]: creating directory server instance



# tail /var/log/ipaserver-install.log 
ServerPort=   389
ServerIdentifier=   RHEL71
Suffix=   dc=rhel71
RootDN=   cn=Directory Manager
InstallLdifFile= /var/lib/dirsrv/boot.ldif
inst_dir=   /var/lib/dirsrv/scripts-RHEL71

2015-02-10T08:04:21Z DEBUG calling setup-ds.pl
2015-02-10T08:04:21Z DEBUG Starting external process
2015-02-10T08:04:21Z DEBUG args='/usr/sbin/setup-ds.pl' '--silent' '--logfile' '-' '-f' '/tmp/tmp0RPcb7'
[root@ipa ~]# cat /tmp/tmp0RPcb7

[General]
FullMachineName=   ipa.rhel71
SuiteSpotUserID=   dirsrv
SuiteSpotGroup=    dirsrv
ServerRoot=    /usr/lib64/dirsrv
[slapd]
ServerPort=   389
ServerIdentifier=   RHEL71
Suffix=   dc=rhel71
RootDN=   cn=Directory Manager
RootDNPwd= kokos123
InstallLdifFile= /var/lib/dirsrv/boot.ldif
inst_dir=   /var/lib/dirsrv/scripts-RHEL71


# tail /var/log/dirsrv/slapd-RHEL71/errors
[10/Feb/2015:03:04:23 -0500] - import userRoot: Generating numsubordinates (this may take several minutes to complete)...
[10/Feb/2015:03:04:23 -0500] - import userRoot: Generating numSubordinates complete.
[10/Feb/2015:03:04:23 -0500] - import userRoot: Gathering ancestorid non-leaf IDs...
[10/Feb/2015:03:04:23 -0500] - import userRoot: Finished gathering ancestorid non-leaf IDs.
[10/Feb/2015:03:04:23 -0500] - Nothing to do to build ancestorid index
[10/Feb/2015:03:04:23 -0500] - import userRoot: Created ancestorid index (new idl).
[10/Feb/2015:03:04:23 -0500] - import userRoot: Flushing caches...
[10/Feb/2015:03:04:23 -0500] - import userRoot: Closing files...
[10/Feb/2015:03:04:23 -0500] - All database threads now stopped
[10/Feb/2015:03:04:23 -0500] - import userRoot: Import complete.  Processed 1 entries in 0 seconds. (0.00 entries/sec)

I tested again. The error above was actually doe to SELinux problem and bad /dev/null permissions. It works with FreeIPA 4.1 already:

# ipa-server-install -p Secret123 -a Secret123 --setup-dns --forwarder=10.0.0.1--ip-address 10.0.0.2 --hostname ipa.f21

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

This includes:
  * Configure a stand-alone CA (dogtag) for certificate management
  * Configure the Network Time Daemon (ntpd)
  * Create and configure an instance of Directory Server
  * Create and configure a Kerberos Key Distribution Center (KDC)
  * Configure Apache (httpd)
  * Configure DNS (bind)

To accept the default shown in brackets, press the Enter key.

Existing BIND configuration detected, overwrite? [no]: y
Warning: skipping DNS resolution of host ipa.f21

Warning: hostname ipa.f21 does not match system hostname vm-046.idm.lab.bos.redhat.com.
System hostname will be updated during the installation process
to prevent service failures.

The domain name has been determined based on the host name.

Please confirm the domain name [f21]:

Adding [10.0.0.2 ipa.f21] to your /etc/hosts file
The kerberos protocol requires a Realm name to be defined.
This is typically the domain name converted to uppercase.

Please provide a realm name [F21]: 
Checking forwarders, please wait ...
WARNING: DNS forwarder 10.0.0.1 does not return DNSSEC signatures in answers
Please fix forwarder configuration to enable DNSSEC support.
(For BIND 9 add directive "dnssec-enable yes;" to "options {}")
WARNING: DNSSEC validation will be disabled
Do you want to configure the reverse zone? [yes]: 
Please specify the reverse zone name [0.0.10.in-addr.arpa.]: 
Using reverse zone(s) 0.0.10.in-addr.arpa.

The IPA Master Server will be configured with:
Hostname:       ipa.f21
IP address(es): 10.0.0.2
Domain name:    f21
Realm name:     F21

BIND DNS server will be configured to serve IPA domain with:
Forwarders:    10.0.0.1
Reverse zone(s):  0.0.10.in-addr.arpa.

Continue to configure the system with these values? [no]: y

The following operations may take some minutes to complete.
Please wait until the prompt is returned.

Configuring NTP daemon (ntpd)
  [1/4]: stopping ntpd
  [2/4]: writing configuration
  [3/4]: configuring ntpd to start on boot
  [4/4]: starting ntpd
Done configuring NTP daemon (ntpd).
Configuring directory server (dirsrv): Estimated time 1 minute
  [1/38]: creating directory server user
  [2/38]: creating directory server instance
  [3/38]: adding default schema
  [4/38]: enabling memberof plugin
  [5/38]: enabling winsync plugin
  [6/38]: configuring replication version plugin
  [7/38]: enabling IPA enrollment plugin
  [8/38]: enabling ldapi
  [9/38]: configuring uniqueness plugin
  [10/38]: configuring uuid plugin
  [11/38]: configuring modrdn plugin
  [12/38]: configuring DNS plugin
  [13/38]: enabling entryUSN plugin
  [14/38]: configuring lockout plugin
  [15/38]: creating indices
  [16/38]: enabling referential integrity plugin
  [17/38]: configuring certmap.conf
  [18/38]: configure autobind for root
  [19/38]: configure new location for managed entries
  [20/38]: configure dirsrv ccache
  [21/38]: enable SASL mapping fallback
  [22/38]: restarting directory server
  [23/38]: adding default layout
  [24/38]: adding delegation layout
  [25/38]: creating container for managed entries
  [26/38]: configuring user private groups
  [27/38]: configuring netgroups from hostgroups
  [28/38]: creating default Sudo bind user
  [29/38]: creating default Auto Member layout
  [30/38]: adding range check plugin
  [31/38]: creating default HBAC rule allow_all
  [32/38]: initializing group membership
  [33/38]: adding master entry
  [34/38]: configuring Posix uid/gid generation
  [35/38]: adding replication acis
  [36/38]: enabling compatibility plugin
  [37/38]: tuning directory server
  [38/38]: configuring directory to start on boot
Done configuring directory server (dirsrv).
Configuring certificate server (pki-tomcatd): Estimated time 3 minutes 30 seconds
  [1/27]: creating certificate server user
  [2/27]: configuring certificate server instance
  [3/27]: stopping certificate server instance to update CS.cfg
  [4/27]: backing up CS.cfg
  [5/27]: disabling nonces
  [6/27]: set up CRL publishing
  [7/27]: enable PKIX certificate path discovery and validation
  [8/27]: starting certificate server instance
  [9/27]: creating RA agent certificate database
  [10/27]: importing CA chain to RA certificate database
  [11/27]: fixing RA database permissions
  [12/27]: setting up signing cert profile
  [13/27]: set certificate subject base
  [14/27]: enabling Subject Key Identifier
  [15/27]: enabling Subject Alternative Name
  [16/27]: enabling CRL and OCSP extensions for certificates
  [17/27]: setting audit signing renewal to 2 years
  [18/27]: configuring certificate server to start on boot
  [19/27]: restarting certificate server
  [20/27]: requesting RA certificate from CA
  [21/27]: issuing RA agent certificate
  [22/27]: adding RA agent as a trusted user
  [23/27]: configure certmonger for renewals
  [24/27]: configure certificate renewals
  [25/27]: configure RA certificate renewal
  [26/27]: configure Server-Cert certificate renewal
  [27/27]: Configure HTTP to proxy connections
Done configuring certificate server (pki-tomcatd).
Configuring directory server (dirsrv): Estimated time 10 seconds
  [1/3]: configuring ssl for ds instance
  [2/3]: restarting directory server
  [3/3]: adding CA certificate entry
Done configuring directory server (dirsrv).
Configuring Kerberos KDC (krb5kdc): Estimated time 30 seconds
  [1/10]: adding sasl mappings to the directory
  [2/10]: adding kerberos container to the directory
  [3/10]: configuring KDC
  [4/10]: initialize kerberos container
  [5/10]: adding default ACIs
  [6/10]: creating a keytab for the directory
  [7/10]: creating a keytab for the machine
  [8/10]: adding the password extension to the directory
  [9/10]: starting the KDC
  [10/10]: configuring KDC to start on boot
Done configuring Kerberos KDC (krb5kdc).
Configuring kadmin
  [1/2]: starting kadmin 
  [2/2]: configuring kadmin to start on boot
Done configuring kadmin.
Configuring ipa_memcached
  [1/2]: starting ipa_memcached 
  [2/2]: configuring ipa_memcached to start on boot
Done configuring ipa_memcached.
Configuring ipa-otpd
  [1/2]: starting ipa-otpd 
  [2/2]: configuring ipa-otpd to start on boot
Done configuring ipa-otpd.
Configuring the web interface (httpd): Estimated time 1 minute
  [1/16]: setting mod_nss port to 443
  [2/16]: setting mod_nss protocol list to TLSv1.0 - TLSv1.2
  [3/16]: setting mod_nss password file
  [4/16]: enabling mod_nss renegotiate
  [5/16]: adding URL rewriting rules
  [6/16]: configuring httpd
  [7/16]: configure certmonger for renewals
  [8/16]: setting up ssl
  [9/16]: importing CA certificates from LDAP
  [10/16]: setting up browser autoconfig
  [11/16]: publish CA cert
  [12/16]: creating a keytab for httpd
  [13/16]: clean up any existing httpd ccache
  [14/16]: configuring SELinux for httpd
  [15/16]: restarting httpd
  [16/16]: configuring httpd to start on boot
Done configuring the web interface (httpd).
Applying LDAP updates
Restarting Directory server to apply updates
  [1/2]: stopping directory server
  [2/2]: starting directory server
Done.
Restarting the directory server
Restarting the KDC
Restarting the certificate server
Configuring DNS (named)
  [1/12]: generating rndc key file
  [2/12]: adding DNS container
  [3/12]: setting up our zone
  [4/12]: setting up reverse zone
  [5/12]: setting up our own record
  [6/12]: setting up records for other masters
  [7/12]: adding NS record to the zones
  [8/12]: setting up CA record
  [9/12]: setting up kerberos principal
  [10/12]: setting up named.conf
  [11/12]: configuring named to start on boot
  [12/12]: changing resolv.conf to point to ourselves
Done configuring DNS (named).
Configuring DNS key synchronization service (ipa-dnskeysyncd)
  [1/7]: checking status
  [2/7]: setting up bind-dyndb-ldap working directory
  [3/7]: setting up kerberos principal
  [4/7]: setting up SoftHSM
  [5/7]: adding DNSSEC containers
  [6/7]: creating replica keys
  [7/7]: configuring ipa-dnskeysyncd to start on boot
Done configuring DNS key synchronization service (ipa-dnskeysyncd).
Restarting ipa-dnskeysyncd
Restarting named

Global DNS configuration in LDAP server is empty
You can use 'dnsconfig-mod' command to set global DNS options that
would override settings in local named.conf files

Restarting the web server
==============================================================================
Setup complete

Next steps:
    1. You must make sure these network ports are open:
        TCP Ports:
          * 80, 443: HTTP/HTTPS
          * 389, 636: LDAP/LDAPS
          * 88, 464: kerberos
          * 53: bind
        UDP Ports:
          * 88, 464: kerberos
          * 53: bind
          * 123: ntp

    2. You can now obtain a kerberos ticket using the command: 'kinit admin'
       This ticket will allow you to use the IPA tools (e.g., ipa user-add)
       and the web user interface.

Be sure to back up the CA certificate stored in /root/cacert.p12
This file is required to create replicas. The password for this
file is the Directory Manager password

# kinit admin
Password for admin@F21:

# ipa user-find
--------------
1 user matched
--------------
  User login: admin
  Last name: Administrator
  Home directory: /home/admin
  Login shell: /bin/bash
  UID: 1889400000
  GID: 1889400000
  Account disabled: False
  Password: True
  Kerberos keys available: True
----------------------------
Number of entries returned 1
----------------------------

Metadata Update from @nkinder:
- Issue assigned to mkosek
- Issue set to the milestone: FreeIPA 4.1.4

7 years ago

Login to comment on this ticket.

Metadata