2 Replies Latest reply on Sep 17, 2008 11:53 AM by Boleslaw Dawidowicz

    Configuration with two LDAP

    Jimenez Remy Newbie

      Hello,

      I configured jboss Portal to connect to LDAP
      But this is my issue: if the LDAP server is not connected, i need to connect Jboss to an other.

      Is it possible ?

        • 1. Re: Configuration with two LDAP
          Peter Johnson Master

          Try this. Change the ldap host name within ldap_identify-config.xml as follows:

          <option>
           <name>host</name>
           <value>${ldap.host:defaultldaphost}</value>
          </option>


          where 'defaultldaphost' is your current ldap host's name. This name will be used if you do not set the ldap.host system property. Then when you want to use the other LDAP host, run JBossAS as follows:

          run -Dldap.host=otherldaphost

          where 'otherldaphost' is the name of the other LDAP host.

          Caveat: the above suggestion is based on the assumption that the ldap configuration file handles system property expansion like the other JBossAS configuration files do; I have not actually tried this.

          • 2. Re: Configuration with two LDAP
            Boleslaw Dawidowicz Master

            Also you can use external JNDI context (described in portal docs) and configure connection with several provider urls. This is supported on the JNDI side.

            "Instead of just one URL, you can also supply a space-separated list of URLs. In this case, the LDAP provider will attempt to use each URL in turn until it is able to create a successful connection. The LDAP provider will then set the Context.PROVIDER_URL property to the successful URL, so that the application can determine which URL is being used. "