I have a problem with the SQL server. The connection is disconnected. Sometimes I looked in the events. The code prints event 17886.

saleh ahmed 0 Reputation points
2024-05-14T06:51:54.7566667+00:00

<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">

  • <System> <Provider Name="MSSQLSERVER" /> <EventID Qualifiers="49152">17886</EventID> <Version>0</Version> <Level>2</Level> <Task>2</Task> <Opcode>0</Opcode> <Keywords>0x80000000000000</Keywords> <TimeCreated SystemTime="2024-05-04T09:40:29.6721670Z" /> <EventRecordID>113811</EventRecordID> <Correlation /> <Execution ProcessID="0" ThreadID="0" /> <Channel>Application</Channel> <Computer>SRV-25202</Computer> <Security /> </System>
  • <EventData> <Binary>DE450000140000000A0000005300520056002D0032003500320030003200000000000000</Binary> </EventData> </Event>

\The server will drop the connection, because the client driver has sent multiple requests while the session is in single-user mode. This error occurs when a client sends a request to reset the connection while there are batches still running in the session, or when the client sends a request while the session is resetting a connection. Please contact the client driver vendor

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,912 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Zahid Butt 556 Reputation points
    2024-05-14T13:30:21.2833333+00:00

    Hi Saleh,

    This is something from application side. Please go through below link (It has further link references):

    https://dba.stackexchange.com/questions/232255/how-do-i-identify-the-source-of-the-17886-errors-server-will-drop-the-connecti

    Hope you might get help.

    Regards,

    0 comments No comments

  2. MikeyQiao-MSFT 655 Reputation points Microsoft Vendor
    2024-05-15T06:13:59.7066667+00:00

    Hi,saleh ahmed

    Possible solutions to the problem include:

    1. Add "MultipleActiveResultSets=True" to your connection string.
    2. Add "Async=True" to your connection string.
    3. Use an "Instance Per Request" strategy in your DI instantiation code.
    4. Add "Pooling=false" to your connection string; if its effect is to append options, add "Connection Lifetime=2".

    Refer to this

    Best Regards,

    Mikey Qiao


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.