locked
Query on witness server RRS feed

  • Question

  • Hi All,

    We have configured DB mirroring on our PROD environment with witness server. Now we have to restart (reboot) Witness server. So can we reboot witness server directly or is there any alter db command/or steps we have to execute before reboot?

    Wednesday, March 30, 2016 11:25 AM

Answers

      • After connecting to the principal server instance, in Object Explorer, click the server name to expand the server tree.

      • Expand Databases, and select the principal database of the session to which you are adding or replacing a witness.

      • Right-click the database, select Tasks, and then click Mirror. This opens the Mirroring page of the Database Properties dialog box.

      • Click Configure Security.

      • If the Configure Database Mirroring Security Wizard welcome screen appears, click Next.

      • In the Include Witness Server dialog box, click Yes, and then click Next.

      • In the Choose Servers to Configure dialog box, the Witness server instance check box is automatically checked. Click Next.

      • On the Principal Server Instance dialog box, keep the existing port and endpoint. Click Next.

      • On the Witness Server Instance dialog box, click Connect.

      • In the Connect to Server dialog box, specify the witness server instance in the Server name field, and use Windows Authentication (the default). Click Connect.

      • Once a connection is established, the listener port and database mirroring endpoint of the witness server instance are displayed on the Witness Server Instance dialog box. Click Next.

      • The Service Accounts dialog box contains fields for the domain service accounts of the principal, mirror, and witness server instances.

        • If the server instances all use the same service account, leave the fields blank.  

      • If the witness server instance uses a different service account from either of the partners, fill in the PrincipalMirror, and Witness fields with the account name:

        DOMAINNAME\username

        The domain name must be in upper case.

      Click Next.

    1. On the Complete the Wizard summary screen, optionally, verify the witness configuration, and then click Finish.

    2. On finishing, the wizard returns you to the Database Properties dialog box where the server network address of the witness now appears inWitness field. Also, High-safety mode with automatic failover (synchronous), which is required with a witness, is automatically selected.

      To enable the witness and change the session to high-safety mode with automatic failover, Click OK.

    Wednesday, March 30, 2016 12:35 PM

All replies

  • Hi,  

    Best Practice to restart witness server is to remove witness server from mirror and then adding it again after restarting.

    ALTER DATABASE DBName SET WITNESS OFF

    Turning off the witness changes the operating mode in accordance with the transaction-safety setting:
    If transaction safety is set to FULL (the default), the session uses high-safety, synchronous mode without automatic failover.
    If transaction safety is set to OFF, the session operates asynchronously (in high-performance mode) without requiring quorum. Whenever transaction safety is turned off, we strongly recommend also turning the witness off.

    Wednesday, March 30, 2016 11:39 AM
  • Thank You. How to set witness server after restart?
    Wednesday, March 30, 2016 12:27 PM
      • After connecting to the principal server instance, in Object Explorer, click the server name to expand the server tree.

      • Expand Databases, and select the principal database of the session to which you are adding or replacing a witness.

      • Right-click the database, select Tasks, and then click Mirror. This opens the Mirroring page of the Database Properties dialog box.

      • Click Configure Security.

      • If the Configure Database Mirroring Security Wizard welcome screen appears, click Next.

      • In the Include Witness Server dialog box, click Yes, and then click Next.

      • In the Choose Servers to Configure dialog box, the Witness server instance check box is automatically checked. Click Next.

      • On the Principal Server Instance dialog box, keep the existing port and endpoint. Click Next.

      • On the Witness Server Instance dialog box, click Connect.

      • In the Connect to Server dialog box, specify the witness server instance in the Server name field, and use Windows Authentication (the default). Click Connect.

      • Once a connection is established, the listener port and database mirroring endpoint of the witness server instance are displayed on the Witness Server Instance dialog box. Click Next.

      • The Service Accounts dialog box contains fields for the domain service accounts of the principal, mirror, and witness server instances.

        • If the server instances all use the same service account, leave the fields blank.  

      • If the witness server instance uses a different service account from either of the partners, fill in the PrincipalMirror, and Witness fields with the account name:

        DOMAINNAME\username

        The domain name must be in upper case.

      Click Next.

    1. On the Complete the Wizard summary screen, optionally, verify the witness configuration, and then click Finish.

    2. On finishing, the wizard returns you to the Database Properties dialog box where the server network address of the witness now appears inWitness field. Also, High-safety mode with automatic failover (synchronous), which is required with a witness, is automatically selected.

      To enable the witness and change the session to high-safety mode with automatic failover, Click OK.

    Wednesday, March 30, 2016 12:35 PM