Closed kforner closed 6 years ago
Replication failed. So, probably the database in iparig is not populated but the service should be running on port 389. Is daemon ns-slapd running ?
Is daemon ns-slapd running ?
No.
# ps -fA
UID PID PPID C STIME TTY TIME CMD
root 1 0 0 18:08 ? 00:00:00 /usr/sbin/init --show-status=false
root 41 1 0 18:08 ? 00:00:00 tail --silent -n 0 -f --retry /var/log/ipa-server-configure-first.log /var/log/ipa-server-run.log
root 54 1 0 18:08 ? 00:00:00 /usr/lib/systemd/systemd-journald
dbus 59 1 0 18:08 ? 00:00:00 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only
root 64 0 0 18:08 ? 00:00:00 bash
root 81 64 0 18:08 ? 00:00:00 ps -fA
# ipactl status
Directory Service: STOPPED
ntpd Service: STOPPED
ipa: INFO: The ipactl command was successful
# ipactl start
Upgrade required: please run ipa-server-upgrade command
Aborting ipactl
Shoud I run ipa-server-upgrade ??
Since we are troubleshooting the port access, we could just start directory service:
systemctl start dirsrv@QUARTZBIO-COM.service
ok: on rig (inside the docker):
systemctl start dirsrv@QUARTZBIO-COM.service
on master (inside the docker):
# openssl s_client -connect 10.9.70.8:389
CONNECTED(00000003)
140314875082616:error:140790E5:SSL routines:ssl23_write:ssl handshake failure:s23_lib.c:177:
---
no peer certificate available
---
No client certificate CA names sent
---
SSL handshake has read 0 bytes and written 201 bytes
---
New, (NONE), Cipher is (NONE)
Secure Renegotiation IS NOT supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
SSL-Session:
Protocol : TLSv1.2
Cipher : 0000
Session-ID:
Session-ID-ctx:
Master-Key:
Key-Arg : None
Krb5 Principal: None
PSK identity: None
PSK identity hint: None
Start Time: 1502296212
Timeout : 300 (sec)
Verify return code: 0 (ok)
---
Let's use hostname. Not ip address.
And particularly from ipa to rig.
When starting replication, it's ipa node that connects to rig to send the data.
For instance, in ipa:
ldapsearch -p 389 -h rig -D "cn=directory manager" -W -b "" -s base
on ipa (docker):
# ldapsearch -p 389 -h rig -D "cn=directory manager" -W -b "" -s base
Enter LDAP Password:
# extended LDIF
#
# LDAPv3
# base <> with scope baseObject
# filter: (objectclass=*)
# requesting: ALL
#
#
dn:
objectClass: top
defaultnamingcontext: dc=quartzbio,dc=com
dataversion: 020170809162814
netscapemdsuffix: cn=ldap://dc=iparig,dc=quartzbio,dc=com:389
lastusn: -1
ipatopologypluginversion: 1.0
ipatopologyismanaged: off
ipaDomainLevel: 0
# search result
search: 2
result: 0 Success
# numResponses: 2
# numEntries: 1
Is it right ?
Some news: after a bit of a struggle, I managed to setup a new replica, but not on a docker, on a fresh fedora 26 laptop. In the process I learned taht a potential problem could be missing DNS entries (from freeIPA) DNS. So I created a new DNS entry for iparig, then relaunched the replica install, and it worked better. Still crashed, but much farther:
2017-08-15T13:36:52Z DEBUG [39/42]: activating sidgen plugin
2017-08-15T13:36:52Z DEBUG [40/42]: activating extdom plugin
2017-08-15T13:36:52Z DEBUG [41/42]: tuning directory server
2017-08-15T13:36:56Z DEBUG wait_for_open_ports: localhost [389] timeout 300
2017-08-15T13:36:57Z DEBUG [42/42]: configuring directory to start on boot
2017-08-15T13:36:58Z DEBUG [1/27]: creating certificate server user
2017-08-15T13:36:58Z DEBUG [2/27]: configuring certificate server instance
[CA]
2017-08-15T13:37:33Z DEBUG [error] RuntimeError: CA configuration failed.
and
Loading deployment configuration from /tmp/tmpDrGyti.
Installing CA into /var/lib/pki/pki-tomcat.
Storing deployment configuration into /etc/sysconfig/pki/tomcat/pki-tomcat/ca/deployment.cfg.
Importing certificates from /tmp/ca.p12:
---------------
5 entries found
---------------
Certificate ID: e12228b23df70b90f2ea082de903908a93f3fba4
Serial Number: 0x2
Nickname: ocspSigningCert cert-pki-ca
Subject DN: CN=OCSP Subsystem,O=QUARTZBIO.COM
Issuer DN: CN=Certificate Authority,O=QUARTZBIO.COM
Has Key: true
Certificate ID: 8777903969dce3806a014d746748b4f144947b4e
Serial Number: 0x4
Nickname: subsystemCert cert-pki-ca
Subject DN: CN=CA Subsystem,O=QUARTZBIO.COM
Issuer DN: CN=Certificate Authority,O=QUARTZBIO.COM
Has Key: true
Certificate ID: 3ee52926a3371a627ad3da893bee4d8966d04131
Serial Number: 0x1
Nickname: caSigningCert cert-pki-ca
Subject DN: CN=Certificate Authority,O=QUARTZBIO.COM
Issuer DN: CN=Certificate Authority,O=QUARTZBIO.COM
Has Key: true
Certificate ID: 8a7c017f1b47027d4ac9d16992f5385d203f06d3
Serial Number: 0x3
Nickname: Server-Cert cert-pki-ca
Subject DN: CN=ipa.quartzbio.com,O=QUARTZBIO.COM
Issuer DN: CN=Certificate Authority,O=QUARTZBIO.COM
Has Key: true
Certificate ID: 833075eac0ed3dac5932823ccc29b5b4ffc074b
Serial Number: 0x5
Nickname: auditSigningCert cert-pki-ca
Subject DN: CN=CA Audit,O=QUARTZBIO.COM
Issuer DN: CN=Certificate Authority,O=QUARTZBIO.COM
Has Key: true
---------------
Import complete
---------------
Imported certificates in /etc/pki/pki-tomcat/alias:
Certificate Nickname Trust Attributes
SSL,S/MIME,JAR/XPI
ocspSigningCert cert-pki-ca u,u,u
subsystemCert cert-pki-ca u,u,u
Server-Cert cert-pki-ca u,u,u
caSigningCert cert-pki-ca CTu,Cu,Cu
auditSigningCert cert-pki-ca u,u,Pu
Installation failed:
<!DOCTYPE html><html><head><title>Apache Tomcat/8.0.43 - Error report</title><style type="text/css">H1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-siz
e:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-
size:14px;} BODY {font-family:Tahoma,Arial,sans-serif;color:black;background-color:white;} B {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;} P {font-family:T
ahoma,Arial,sans-serif;background:white;color:black;font-size:12px;}A {color : black;}A.name {color : black;}.line {height: 1px; background-color: #525D76; border: none;}</style> </head
><body><h1>HTTP Status 500 - java.lang.Exception: Missing system certificate: ocspSigningCert cert-pki-ca</h1><div class="line"></div><p><b>type</b> Exception report</p><p><b>message</b
> <u>java.lang.Exception: Missing system certificate: ocspSigningCert cert-pki-ca</u></p><p><b>description</b> <u>The server encountered an internal error that prevented it from fulfill
ing this request.</u></p><p><b>exception</b></p><pre>org.jboss.resteasy.spi.UnhandledException: java.lang.Exception: Missing system certificate: ocspSigningCert cert-pki-ca
org.jboss.resteasy.core.ExceptionHandler.handleApplicationException(ExceptionHandler.java:77)
org.jboss.resteasy.core.ExceptionHandler.handleException(ExceptionHandler.java:220)
org.jboss.resteasy.core.SynchronousDispatcher.writeException(SynchronousDispatcher.java:175)
and from /var/log/pki/pki-tomcat/ca/debug:
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: ConfigurationUtils.importKeyCert()
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Deleting existing certificates:
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Certificate caSigningCert cert-pki-ca
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Certificate ocspSigningCert cert-pki-ca
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Certificate subsystemCert cert-pki-ca
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Certificate auditSigningCert cert-pki-ca
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Master certs:
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - preop.cert.signing.dn: cn=Certificate Authority,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - preop.cert.ocsp_signing.dn: cn=OCSP Subsystem,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - preop.cert.subsystem.dn: cn=CA Subsystem,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - preop.cert.audit_signing.dn: cn=CA Audit,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Importing new keys:
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Key: CN=OCSP Subsystem,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Find cert with subject DN CN=OCSP Subsystem,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Certificate is missing/removed, ignore key
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Key: CN=CA Subsystem,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Find cert with subject DN CN=CA Subsystem,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Certificate is missing/removed, ignore key
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Key: CN=Certificate Authority,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Find cert with subject DN CN=Certificate Authority,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Imported cert 1
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Key: CN=ipa.quartzbio.com,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Key not in master list, ignore key
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Key: CN=CA Audit,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Find cert with subject DN CN=CA Audit,O=QUARTZBIO.COM
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Certificate is missing/removed, ignore key
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Importing new certificates:
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: - Certificate: caSigningCert cert-pki-ca
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Property preop.master.signing.nickname: caSigningCert cert-pki-ca
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: CA signing cert: true
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: Imported cert 1
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: SystemConfigService: verify certificates
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: ConfigurationUtils.verifySystemCertificates(): checking certificate caSigningCert cert-pki-ca
[15/Aug/2017:13:37:33][http-bio-8443-exec-3]: ConfigurationUtils.verifySystemCertificates(): checking certificate ocspSigningCert cert-pki-ca
java.lang.Exception: Missing system certificate: ocspSigningCert cert-pki-ca
at com.netscape.cms.servlet.csadmin.ConfigurationUtils.verifySystemCertificates(ConfigurationUtils.java:1014)
at org.dogtagpki.server.rest.SystemConfigService.configureClone(SystemConfigService.java:898)
at org.dogtagpki.server.rest.SystemConfigService.configureSubsystem(SystemConfigService.java:1019)
at org.dogtagpki.server.rest.SystemConfigService.configure(SystemConfigService.java:164)
hi @kforner, since this doesn't seem an issue related directly to ipa container, could you post it on freeipa-users list: freeipa-users@lists.fedorahosted.org? There, there are more people able to help you.
Hello folks who have followed this issue -- is there anything that might be needed specifically for the container case?
We might have lost traction here, closing.
Hi,
Sorry, I have no idea from my side.
Regards,
German
On Fri, Jul 20, 2018, 1:54 PM Jan Pazdziora notifications@github.com wrote:
We might have lost traction here, closing.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/freeipa/freeipa-container/issues/150#issuecomment-406578548, or mute the thread https://github.com/notifications/unsubscribe-auth/AXnZa2s3T8qr8EUBik6SWHRQFPUq6mDkks5uIcTqgaJpZM4Oq12U .
I'm still stuck with my master and its replica running an old version of the freeipa-server docker (adelton/freeipa-server:latest-systemd). I was trying to setup a new replica using the latest freeipa/freeipa-server.
I had to add the
--skip-conncheck
option toipa-data/ipa-replica-install-options
because there is no ssh installed in the docker.But it still fails at some point. Here are the IMHO relevant lines from
/var/log/ipareplica-install.log
, out of ~ 2000 lines: