RH-SSO realm export fails with "org.keycloak.models.ModelException: LDAP Query failed"

Solution Verified - Updated -


  • Attempting to export realm form the command line following the RH-SSO documentation fails with the following errors:
INFO  [org.keycloak.services] (ServerService Thread Pool -- 68) KC-SERVICES0033: Full model export requested
INFO  [org.keycloak.exportimport.singlefile.SingleFileExportProvider] (ServerService Thread Pool -- 68) Exporting model into file /RH-SSO_HOME/bin/keycloak-export.json
INFO  [org.keycloak.storage.ldap.LDAPIdentityStoreRegistry] (ServerService Thread Pool -- 68) Creating new LDAP Store for the LDAP storage provider: 'ldap', LDAP Configuration: {fullSyncPeriod=[-1], pagination=[true], usersDn=[dc=keycloak,dc=org], connectionPooling=[true], cachePolicy=[DEFAULT], useKerberosForPasswordAuthentication=[false], importEnabled=[true], enabled=[true], changedSyncPeriod=[-1], usernameLDAPAttribute=[uid], bindDn=[uid=testLdap,ou=People,dc=keycloak,dc=org], lastSync=[1612557744], vendor=[rhds], uuidLDAPAttribute=[uid], allowKerberosAuthentication=[false], connectionUrl=[ldap://], syncRegistrations=[false], authType=[simple], debug=[false], searchScope=[2], useTruststoreSpi=[ldapsOnly], priority=[0], trustEmail=[false], userObjectClasses=[inetOrgPerson, organizationalPerson], rdnLDAPAttribute=[uid], validatePasswordPolicy=[false], batchSizeForSync=[1000]}, binaryAttributes: []
FATAL [org.keycloak.services] (ServerService Thread Pool -- 68) org.keycloak.models.ModelException: LDAP Query failed


  • Red Hat Single Sign-On (RH-SSO)
    • 7.5.2

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content