locked
Mirroring Endpoint Error 1418 RRS feed

  • Question

  • I am trying to set up mirroring for a database called MirrorTest between two SQL Server 2008 instances on seperate machines. The machines are on the same domain and both instances are running under the same domain account. When I try to set the mirror as the partner for the principal instance I get the following error:

    "The server network address "TCP://mirror.domain.net:5025" can not be reached or does not exist. Check the network address name and that the ports for the local and remote endpoints are operational."

    The error code is 1418. mirror is the name of the server hosting the mirror instance.

    I've verified through the SQL Server Network Configuration in SQL Server Configuration Manager that both the mirror and principal are set up to allow TCP/IP connections. I've checked that the ports I have specified for the mirroring endpoints can be connected to using telnet from both servers. I've checked that SQL Server is using these ports by running netstat -abn on both servers. I've checked that the endpoints are both in the STARTED state. I cant figure out where I'm going wrong!

    Before anyone asks, here are the TSQL commands I used:

    To create the mirroring end points on both principal and mirror (they use the same port number on different machines):

     

    CREATE ENDPOINT MirroringEndPoint
     STATE = STARTED
     AS TCP ( LISTENER_PORT = 5025 )
     FOR DATABASE_MIRRORING (
      AUTHENTICATION = WINDOWS KERBEROS,
      ENCRYPTION = SUPPORTED,
      ROLE=PARTNER);
    GO

     

    Then restored the MirrorTest database onto the mirror server with NORECOVERY specified

    RESTORE DATABASE MirrorTest 
    FROM DISK = 'G:\Backup\MirrorTest.bak' 
    WITH NORECOVERY,
    MOVE 'MirrorTest' TO 'G:\Data\MirrorTest.mdf',
    MOVE 'MirrorTest_log' TO 'G:\Data\MirrorTest_log.ldf'
    GO
    
    
    RESTORE LOG MirrorTest
    FROM DISK = 'G:\Backup\MirrorTest_log.bak' 
    WITH FILE=1, NORECOVERY
    GO

    Then running this on the mirror to partner it with the principal

    ALTER DATABASE MirrorTest
    SET PARTNER = 'TCP://principal.domain.net:5025'

    and then running this on the principal to partner it with mirror at which point I get the error.

    ALTER DATABASE MirrorTest
    SET PARTNER = 'TCP://mirror.domain.net:5025'

    Any ideas anyone?


    Tuesday, September 7, 2010 3:49 AM

Answers

  • Ok found the answer here: http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SQL_Server_2008/Q_26294382.html

     

    Turns out it was the Windows Kerberos authentication specified for the endpoints which was causing trouble. I changed it to plain Windows and it worked.

    • Marked as answer by MadJimmy Tuesday, September 7, 2010 7:41 AM
    Tuesday, September 7, 2010 7:40 AM

All replies

  • Does the SQL Server service account have rights to both instances?  1418 is unfortunately generic and could mean several things.  I'd run through the listing to ensure even of the steps are validated in the link below before going too far

    http://msdn.microsoft.com/en-us/library/ms189127.aspx

    I'm assuming the principal is also a test database and not changing?  if not, the log may need to be rolled forward on the mirror again by taking a new tail backup on the principal side if you have let it go too long while troubleshooting this.


    Ted Krueger Blog on lessthandot.com @onpnt on twitter
    Tuesday, September 7, 2010 4:00 AM
  • Also please read the below article

    http://msdn.microsoft.com/en-us/library/aa337361.aspx


    Best Regards, Uri Dimant SQL Server MVP http://dimantdatabasesolutions.blogspot.com/ http://sqlblog.com/blogs/uri_dimant/
    Tuesday, September 7, 2010 5:42 AM
  • I checked the SQL error log and found this entry which may provide further information:

    2010-09-07 17:17:39.43 Logon       Database Mirroring login attempt failed with error: 'Connection handshake failed. An OS call failed: (80090303) 0x80090303(The specified target is unknown or unreachable). State 66.'.  [CLIENT: 159.137.45.68]

    Tuesday, September 7, 2010 7:22 AM
  • Ok found the answer here: http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SQL_Server_2008/Q_26294382.html

     

    Turns out it was the Windows Kerberos authentication specified for the endpoints which was causing trouble. I changed it to plain Windows and it worked.

    • Marked as answer by MadJimmy Tuesday, September 7, 2010 7:41 AM
    Tuesday, September 7, 2010 7:40 AM
  • In first place try to TELNET the port 5025 on the mirror from your principal instance.
    Thanks, Leks
    Tuesday, September 7, 2010 7:41 AM
    Answerer
  • Thank you.. Saved my day. :) The above fix resolved the DB Mirroring configuration.
    Tuesday, October 30, 2018 12:36 AM