I have SQL Server 2008 R2 Installed. It contains three instances.
- Default (MSSQLServer)
- First Instance
- Second Instance
All these are Log On as Network Service..
Default Instance is Principal server
First Instance is Mirror
Second Instance is Witness Server
I initially took the Full Backup and Transactional Log Backup of my Principal Database.
Restored it to the First Instance by keeping the same Database Name and Recovery State is No-Recovery
Finally, I started the Mirroring and I am getting two error messages shown below.
Best Answer
Try some basic connectivity tests.
From the command line :
On my server, you can see that 5022 is listening.
Next make sure that you can connect to those ports via telnet
As it mentions in the Note section of the Mirroring Properties GUI, just below the witness field, the server names have to be fully qualified tcp addresses.
You should just see a black screen. In this example I chose a name that would cause a connection failure. If you see "Could not open connection", then the server(s) defined as mirror, principal and witness aren't reachable or you are not using the right name.
The telnet client can be added under Features in Windows 2008.
In Windows 2008, when you right click on Computer, you can see the full computer name. You should be able to ping it as well from the command line. ex: ping myservername
Update
Please run the following queries on each SQL Server instance and put the results in your question. Many of these troubleshooting tips come from: http://msdn.microsoft.com/en-us/library/ms189127.aspx
Show tcp endpoints
Display status of mirroring endpoints
Check that the ROLE is correct
Display permissions to endpoints
The login for the service account from the other server instance requires CONNECT permission. Make sure that the login from the other server has CONNECT permission. To determine who has CONNECT permission for an endpoint, on each server instance use the following Transact-SQL statement.
Example output:
Grantor is the account that assigned (CO) connect permission, Grantee is the account that has connect permission
From the command line run
ipconfig /all
and note what Host Name returns.