Mirroring/Endpoint Restart Connection Issue

  • Hey everyone,

    Need some help figuring out why I get connection issues to the principal database when restarting the endpoints.

    History:

    DBWitness is on a VMServer. For some reason, when the VM was restarted, we started getting the following messages in the error log:

    Message

    Database mirroring connection error 4 'An error occurred while receiving data: '64(The specified network name is no longer available.)'.' for 'TCP://192.168.100.64:9200'.

    Doing a little research into it, to resolve the issue, you need to stop and start the mirroring endpoints. I did that with the following statements:

    alter endpoint Mirror State = stopped

    alter endpoint Mirror State = started

    The code above needed to be run on the witness, mirror, and principal servers. After running the statement, we get a call from the client screaming that he didn't have access to his system.

    Going in to review and sure engough, the database stopped taking connections. Specifically, it happened twice. Once during the restart of the endpoints on the mirrored server and once during the restart of the endpoints on the principal server. Here is what I get from the SQL Error logs when I retstarted the endpoint on the mirrored server. These messages are from the principal database. I get the same messages in the mirrored error log as well.

    Database mirroring connection error 4 'An error occurred while receiving data: '64(The specified network name is no longer available.)'.' for 'TCP://192.168.100.69:9200'.

    Database mirroring is inactive for database 'MyDatabase'. This is an informational message only. No user action is required.

    Restart packet created for dbid 8.

    Restart packet processing for dbid 8.

    Database mirroring connection error 2 'Connection attempt failed with error: '10061(No connection could be made because the target machine actively refused it.)'.' for 'TCP://192.168.100.69:9200'.

    SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'Object Plans' cachestore (part of plan cache) due to some database maintenance or reconfigure operations.

    SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'SQL Plans' cachestore (part of plan cache) due to some database maintenance or reconfigure operations.

    SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'Bound Trees' cachestore (part of plan cache) due to some database maintenance or reconfigure operations.

    Starting up database 'MyDatabase'.

    Analysis of database 'MyDatabase' (8) is 100% complete (approximately 0 seconds remain). This is an informational message only. No user action is required.

    52 transactions rolled forward in database 'MyDatabase' (8). This is an informational message only. No user action is required.

    0 transactions rolled back in database 'MyDatabase' (8). This is an informational message only. No user action is required.

    Recovery is writing a checkpoint in database 'MyDatabase' (8). This is an informational message only. No user action is required.

    CHECKDB for database 'MyDatabase' finished without errors on 2012-07-09 10:37:33.333 (local time). This is an informational message only; no user action is required.

    Database mirroring is active with database 'MyDatabase' as the principal copy. This is an informational message only. No user action is required.

    The Database Mirroring protocol transport has stopped listening for connections.

    Reading the error log, it is almost like the database went offline and then came back online. The total time on this was about 30 second. During this time, we recieved almost 300 errors stating that the web application that uses the database couldn't connection to the database. Additionally, no failover occurred (which is understandable since the witness didn't know the mirror exists due to the endpoint connection issue).

    Anyone got any thoughts on what is going on here?

    Thanks,

    Fraggle

  • This was removed by the editor as SPAM

  • Fraggle-805517 - Thursday, August 23, 2012 7:22 AM

    Hey everyone, Need some help figuring out why I get connection issues to the principal database when restarting the endpoints. History: DBWitness is on a VMServer. For some reason, when the VM was restarted, we started getting the following messages in the error log: Message Database mirroring connection error 4 'An error occurred while receiving data: '64(The specified network name is no longer available.)'.' for 'TCP://192.168.100.64:9200'. Doing a little research into it, to resolve the issue, you need to stop and start the mirroring endpoints. I did that with the following statements: alter endpoint Mirror State = stopped alter endpoint Mirror State = started The code above needed to be run on the witness, mirror, and principal servers. After running the statement, we get a call from the client screaming that he didn't have access to his system. Going in to review and sure engough, the database stopped taking connections. Specifically, it happened twice. Once during the restart of the endpoints on the mirrored server and once during the restart of the endpoints on the principal server. Here is what I get from the SQL Error logs when I retstarted the endpoint on the mirrored server. These messages are from the principal database. I get the same messages in the mirrored error log as well. Database mirroring connection error 4 'An error occurred while receiving data: '64(The specified network name is no longer available.)'.' for 'TCP://192.168.100.69:9200'. Database mirroring is inactive for database 'MyDatabase'. This is an informational message only. No user action is required. Restart packet created for dbid 8. Restart packet processing for dbid 8. Database mirroring connection error 2 'Connection attempt failed with error: '10061(No connection could be made because the target machine actively refused it.)'.' for 'TCP://192.168.100.69:9200'. SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'Object Plans' cachestore (part of plan cache) due to some database maintenance or reconfigure operations. SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'SQL Plans' cachestore (part of plan cache) due to some database maintenance or reconfigure operations. SQL Server has encountered 1 occurrence(s) of cachestore flush for the 'Bound Trees' cachestore (part of plan cache) due to some database maintenance or reconfigure operations. Starting up database 'MyDatabase'. Analysis of database 'MyDatabase' (8) is 100% complete (approximately 0 seconds remain). This is an informational message only. No user action is required. 52 transactions rolled forward in database 'MyDatabase' (8). This is an informational message only. No user action is required. 0 transactions rolled back in database 'MyDatabase' (8). This is an informational message only. No user action is required. Recovery is writing a checkpoint in database 'MyDatabase' (8). This is an informational message only. No user action is required. CHECKDB for database 'MyDatabase' finished without errors on 2012-07-09 10:37:33.333 (local time). This is an informational message only; no user action is required. Database mirroring is active with database 'MyDatabase' as the principal copy. This is an informational message only. No user action is required. The Database Mirroring protocol transport has stopped listening for connections. Reading the error log, it is almost like the database went offline and then came back online. The total time on this was about 30 second. During this time, we recieved almost 300 errors stating that the web application that uses the database couldn't connection to the database. Additionally, no failover occurred (which ispower understandable since the witness didn't know the mirror exists due to the endpoint connection issue). Anyone got any thoughts on what is going on here? Thanks, Fraggle

    My 2 Cents -- by seeing the error log posted your end point is going into sleep mode. which might be causing connection attempt failure errors. check if partner time out is set to higher value can  solve this. And also check if your server is using

    BALANCED POWER MODE/ POWER SAVING MODE. if yes then please use HIGH PERFORMANCE MODE , this is observed some times servers with power saving modes CPU's will go ideal and will not respond to connections.

    @JayMunnangi

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply