> See the slapo-retcode(5) manpage.
Ah !! I was pretty sure I had seen some overlay in the past. Thanks for pointing me to this

But it seems I can't get it working or maybe I didn't understand it correctly.

With some googling I added one such entry:

  dn: olcOverlay=retcode,olcDatabase={1}mdb,cn=config
  changetype: add
  objectClass: olcOverlayConfig
  objectClass: olcRetcodeConfig
  olcOverlay: retcode
  olcRetcodeParent: ou=Users,dc=mydomain
  olcRetcodeItem: "uid=timeout_user" 0x03 sleeptime=10

Now if I query for 'timeout_user' I should observe a delay of 10 seconds and an error ?
How do I induce timeout/timelimit error on the complete base

On Mon, Apr 5, 2021 at 4:31 AM Howard Chu <hyc@symas.com> wrote:
varun mittal wrote:
> Is there any easy way of mocking errors(network timeout, search time limit exceeded etc.) from OpenLDAP server to test if client exception are being handled
> properly ?

See the slapo-retcode(5) manpage.

  -- Howard Chu
  CTO, Symas Corp.           http://www.symas.com
  Director, Highland Sun     http://highlandsun.com/hyc/
  Chief Architect, OpenLDAP  http://www.openldap.org/project/