.hy 0
 .B retcode\-item <RDN> <errCode> [op=<oplist>] [text=<message>]
 .B [ref=<referral>] [sleeptime=<sec>] [matched=<DN>]
-.B [unsolicited=<OID>[:<data>]]
+.B [unsolicited=<OID>[:<data>]] [flags=disconnect[,...]]
 .RS
 A dynamically generated entry, located below \fBretcode\-parent\fP.
 The \fBerrCode\fP is the number of the response code;
 of an RFC 4511 unsolicited response message; if \fBOID\fP
 is not "0", an extended response is generated, with the optional
 \fBdata\fP appended.
+If \fBflags\fP contains \fBdisconnect\fP, 
+.BR slapd (8)
+disconnects abruptly, without notice.
 .RE
 .TP
 .B retcode\-indir
     SINGLE-VALUE )
 .RE
 .LP
+If TRUE,
+.BR slapd (8)
+disconnects abruptly without notice:
+.RS 4
+( 1.3.6.1.4.1.4203.666.11.4.1.8
+    NAME ( 'errDisconnect' )
+    DESC 'Disconnect without notice'
+    SYNTAX 1.3.6.1.4.1.1466.115.121.1.7
+    SINGLE-VALUE )
+.RE
+.LP
 The abstract class that triggers the overlay:
 .RS 4
 ( 1.3.6.1.4.1.4203.666.11.4.3.0
 
 static AttributeDescription    *ad_errMatchedDN;
 static AttributeDescription    *ad_errUnsolicitedOID;
 static AttributeDescription    *ad_errUnsolicitedData;
+static AttributeDescription    *ad_errDisconnect;
+
 static ObjectClass             *oc_errAbsObject;
 static ObjectClass             *oc_errObject;
 static ObjectClass             *oc_errAuxObject;
        slap_mask_t             rdi_mask;
        struct berval           rdi_unsolicited_oid;
        struct berval           rdi_unsolicited_data;
+
+       unsigned                rdi_flags;
+#define        RDI_DISCONNECT          (0x1U)
+
        struct retcode_item_t   *rdi_next;
 } retcode_item_t;
 
                rs->sr_text = "retcode not found";
 
        } else {
+               if ( rdi->rdi_flags & RDI_DISCONNECT ) {
+                       return rs->sr_err = SLAPD_DISCONNECT;
+               }
+
                rs->sr_err = rdi->rdi_err;
                rs->sr_text = rdi->rdi_text.bv_val;
                rs->sr_matched = rdi->rdi_matched.bv_val;
                }
        }
 
+       /* disconnect */
+       a = attr_find( e->e_attrs, ad_errDisconnect );
+       if ( a != NULL && bvmatch( &a->a_nvals[ 0 ], &slap_true_bv ) ) {
+               return rs->sr_err = SLAPD_DISCONNECT;
+       }
+
        /* error code */
        a = attr_find( e->e_attrs, ad_errCode );
        if ( a == NULL ) {
                                                        &rdi.rdi_unsolicited_oid );
                                        }
 
+                               } else if ( strncasecmp( argv[ i ], "flags=", STRLENOF( "flags=" ) ) == 0 )
+                               {
+                                       if ( strcasecmp( &argv[ i ][ STRLENOF( "flags=" ) ], "disconnect" ) == 0 ) {
+                                               rdi.rdi_flags |= RDI_DISCONNECT;
+
+                                       } else {
+                                               fprintf( stderr, "%s: line %d: retcode: "
+                                                       "unknown flag \"%s\".\n",
+                                                       fname, lineno, &argv[ i ][ STRLENOF( "flags=" ) ] );
+                                               return 1;
+                                       }
+
                                } else {
                                        fprintf( stderr, "%s: line %d: retcode: "
                                                "unknown option \"%s\".\n",
-                                                       fname, lineno, argv[ i ] );
+                                               fname, lineno, argv[ i ] );
                                        return 1;
                                }
                        }
                        "SYNTAX 1.3.6.1.4.1.1466.115.121.1.40 "
                        "SINGLE-VALUE )",
                        &ad_errUnsolicitedData },
+               { "( 1.3.6.1.4.1.4203.666.11.4.1.8 "
+                       "NAME ( 'errDisconnect' ) "
+                       "DESC 'Disconnect without notice' "
+                       "SYNTAX 1.3.6.1.4.1.1466.115.121.1.7 "
+                       "SINGLE-VALUE )",
+                       &ad_errDisconnect },
                { NULL }
        };
 
                                "$ errMatchedDN "
                                "$ errUnsolicitedOID "
                                "$ errUnsolicitedData "
+                               "$ errDisconnect "
                        ") )",
                        &oc_errAbsObject },
                { "( 1.3.6.1.4.1.4203.666.11.4.3.1 "