Вы находитесь на странице: 1из 3

Data Base Mirroring

1 What is Database Mirroring?


DB Mirroring maintaining two synchronized copies of database is called mirroring
. Secondary database will be in no recovery always .only one copy of database is
available to users at any time .
2. How many servers in mirroring?
Principal server : - Primary server is a source server contains user transactions .
Mirror server
:- Secondary server contains destination database ,stores log
buffer that comes from principal .
Witness server :- Optional server that principal and mirror servers .
3. What are Recovery models supports Database Mirroring?
Database Mirroring is supported with Full Recovery model.
4. What is End point ?
An endpoint is a network protocol which is used to communicate Principal,
Mirror and Witness servers over the network.
5. What is the default of end points (port numbers) of principal, mirror
and witness servers?
The default port numbers of principal, mirror and Witness servers are 5022,
5023 and 5024
6.How many Types of Mirroring ?
Synchronous Mirroring :

Principal server was forced to wait until it receives acknowledgement from


Mirror server .After receiving acknowledgement then only it commits the
transaction fully in principal.
Users have to wait more time until it commits the data on both servers
.performance is slow but the data will be highly synchronized

Asynchronous Mirroring :

For high performance in mirroring ,once transaction comes to principal


server it copies log buffer to mirror server and commit transaction
immediately in principal server it will not wait for acknowledgement from
mirror .Here we high performance but synchronization of data is less .

7.What is operating modes in mirroring ?

High performance (Asynchronous)


High safety without automatic failover
High safety with automatic failover (synchronous)

8. What are the minimum requirements for Database Mirroring?


Database base recovery model should be full
Database name should be same on both SQL Server instances
Server should be in the same domain name
Mirror database should be initialized with principle server
9.How to configuring mirroring ?

Connect to principal server


mirroring .

-> select database -> go to properties -> select

10.Types of failovers ?
1 .Automatic failover : -Witness will detect heart beat failure , we use it in high
availability mode 2.Manual failover ;Using T-SQL script
ALTER DATABASE DATABASE-NAME SET PARTNER FAIL OVER
Using GUI
Right click on database -> go to properties -> go to mirroring -> from mirroring
wizard ->click failover .
3.Forced failover ;ALTER DATABASE DATABASE-NAME SET PARTNER FAIL OVER WITH FORCE
ALLOW
11.What is Quorum ?

Quorum is a communication between Principal server and Mirror server and


Wintness server .

12 .What Database Snapshot ?


It provides a read only static view of a datebase ,
CREATE DATABASE DB-SNAPSHOT ON (NAME=LOGICAL NAME ,FILE NMAE=
(PHYSICAL PATH
) AS SNAPSHOT OF DB NAME
13. What is Role switching?

Inter changing of roles like principal and mirror are called role switching.

14.Which Trace flag is used in mirroring ?


Trace flag are used to temporarily set specific server characteristics or off/on a
particular behavior. 1400 trace flag used in the mirroring.
To set trace flag for database mirroring:- configuration manager->RC server
instance->properties->advance tab->startup parameters-> -t1400(add)
15.What are Advantages and Disadvantages in mirroring ?
Advantages :

Configuration easy compared to log shipping .


Data loss might be low .
Failover is automatic and it can take less time .

Disadvantages:

We can maintain only one mirror server .


No Backus available .

16.When principal server down what will happen in mirroring ?


MIND Q
17.What happens if mirror server down ?
MIND Q

18. What happens if witness is down ?


MIND Q
19. Incase of mirror is down for more days ?
MIND Q
20. How to monitoring Mirroring?
There are six methods are available for monitoring the Database
Mirroring
a) Database Mirroring Monitor:Database Mirroring Monitor is a GUI tool
Right click on Principal Database > Tasks > Select Launch Database Mirroring
Monitor.
b) SQL Server Management Studio:A green arrow on the mirror server is indicates running well. A red arrow indicates
problems that need to investigate.
c) SQL Server Log:It provides information of Mirroring establishmentand status. If any errors occur it
will be logged to SQL Server log and Windows event log.
d) Performance Monitor:It can provides realtime information about Database mirroring. We can use
performance counters to get status of the database mirroring such as Bytes
received/sec, Bytes sent/sec, Transaction delay etc.
e) Profiler:Profiler:many events are providing the status of the Database mirroring .
f) System Stored Procedures: sp_dbmmonitoraddmonitoring
sp_dbmmonitorchangemonitoring
sp_dbmmonitorhelpmonitoring
sp_dbmmonitordropmonitoring

Вам также может понравиться