DB Mirroring Error

Posted on 2012-08-26
Last Modified: 2012-08-28
Hi Team,
I am trying to setup DB Mirroring in our setup and Need your help here!

I've 3 servers (2 (Principal and witness) of them are in one machine and 1 (Mirror) is in other machine) setup ... Firewalls are turned off on all 3 of them.... I want to set them up as Principle, mirror and witness respectively.... Before configuring the mirroring, I backed up the database on Principal and restored it on Mirror database (Restore With No Recovery) . I did it first for the DB backup file and then the transaction log file.......
Now, when I configure mirroring on my my principle server and after choosing my respective serves are principle, mirror and witness.When I am trying to start mirroring I am receiving the below error,

TITLE: Database Properties
An error occurred while starting mirroring.
Alter failed for Database 'COSBCS_TEST_4GL'.  (Microsoft.SqlServer.Smo)
For help, click:
An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
The server network address "TCP://" cannot be reached or does not exist. Check the network address name and that the ports for the local and remote endpoints are operational. (Microsoft SQL Server, Error: 1418)
For help, click:

Can you let me know how to fix this error?

Question by:COS_IT_AU
    LVL 18

    Expert Comment

    are you able to connect SSMS to ?

    DB Mirror uses ¿      7022 TCP port, check if is open.

    are you sure there are no "real" (not windows firewall) firewalls between servers?
    LVL 5

    Expert Comment

    1.type firewall.cpl in the run.
    Turn off the firewall if it's opened.

    2. Both principal and secondary SQL server agent should run under same user account.
    It shouldn't be local.

    I feel most probably second type will fix your issue.
    LVL 10

    Expert Comment

    check my blog for simple steps for Database mirroring in Simple Steps

    all the SQL Services are started with the same service account, check for login credentails and permissions
    try to do

    alter database dbname set partner ='TCP://'

    check the state of the Mirroring End Points

    select * from sys.endpoints

    if the endpoints state is stopped , try to start the endpoints

    Author Comment

    Hi All,

    I tried with all the possible solutions to fix the error but I am getting the same error.
    Below are the list of tasks/steps i have done to fix this issue,

    1) I can able to telnet the mirror database from principal server with 5023 port.
    2) I have tried to use the same service account and tried it.
    3) Altered the database and checked both the endpoints they are in started mode.

    Kindly let me know any possible ways to fix this issue.

    LVL 10

    Accepted Solution

    check my blog

    check it i have used IP adress before starting the Database Mirroring

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    I have written a PowerShell script to "walk" the security structure of each SQL instance to find:         Each Login (Windows or SQL)             * Its Server Roles             * Every database to which the login is mapped             * The associated "Database User" for this …
    In this article I will describe the Detach & Attach method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
    Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
    Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    8 Experts available now in Live!

    Get 1:1 Help Now