How to find if the LDAP server is not rechable

Alan DeKok aland at deployingradius.com
Tue Apr 14 14:03:46 CEST 2015


On Apr 14, 2015, at 7:10 AM, Adarsha S <s.adarsha at gmail.com> wrote:
> I've a setup with freeradius-server-2.2.3 and Windows AD 2008 [LDAP
> server]for authentication.
> I need to implement fall back feature where if Windows AD server is not
> reachable , I need to authenticate using  local database.

  That's simple enough.

> The problem I'm facing is :
> When LDAP server is reachable and giving wrong password result is
> RLM_MODULE_REJECT. LDAP server not reachable the result is RLM_MODULE_FAIL.

  Yes... see "man unlang".  You can check for different return codes from modules.  You can also put the modules into a "redundant" block, where the second one is called only when the first one fails.

  e.g.

	redundant {
		ldap
		other_database
	}

  See "man unlang".

  Alan DeKok.




More information about the Freeradius-Users mailing list