Configuring MSCS Server Failover in Active-Passive mode

How to configure CML Active-Passive Failover using MS Cluster Services (MSCS)

Description of the environment:

images/download/attachments/21955715/active-passive.png

Caveats:

  • SafeQ is installed on two (or more) servers with identical settings.

  • Both servers (e.g. hardware computers) are running all the time.

  • Both servers are pointing to one SQL server (DB).

  • Such environment requires independent license for each cluster node.

  • In case of failure, user has to wait to system restart (up to 5 minutes).

  • Some pull accounting logs can be lost or duplicated in case of server failure.

  • All SafeQ services are part of MSCS as a resources. In case of node failure, MSCS fail-over the resource to other node. All SafeQ services are always running only on one server at the time.

Expected behavior:

  • In case of a node failure, other node takes over all SafeQ services and users are still able to perform all the operations.

Limitations:

  • Active sessions (print, scan, copy) will be interrupted during the crash of one of the servers. User will have to log in and perform the operation again.

  • It is necessary to always use the virtual IP address of the cluster to administrate SafeQ using the web interface

Environment requirements

  • MS Windows 2008 R2/2012 servers (Enterprise).

  • Functional, properly configured and validated Microsoft cluster.

  • Two independent SafeQ server licenses.

  • Supported external MSSQL server.

  • One dedicated IP address must be available for YSoft SafeQ services clustering. This IP address must be reachable from the customer's LAN (MFPs and hardware terminals). This IP address cannot be the same as MS Cluster virtual IP address.

  • High-availability storage is required for the job spooler to avoid single point of failure.

  • Service account for running YSoft SafeQ server services. It is recommended to use domain account with administrative rights for the SafeQ servers.This account will be used for accessing network folders used for scans and shared spooler folder.

  • External SQL server should be clustered to avoid single point of failure.

  • Technician performing the installation must have full access to SafeQ databases on the MSSQL server and must have advanced knowledge of SQL.

Install YSoft SafeQ 

First Server

1

Follow standard procedures to install SafeQ to the first server which is part of the MS Cluster.

    • During installation select the IP address of public network adapter (not the one used for heartbeat in MS cluster).

    • Use external MSSQL server.

    2

    Activate SafeQ with your first license.

    3

    Set up all configuration as required (e.g. mailserver, ldap connection...).

    4

    Stop all SafeQ services.


    Second Server

    1

    Run the Y Soft SafeQ server installation package.

    2

    Follow the installation wizard and when asked to select the IP address of SafeQ server, select the IP address of public network adapter (not the one used for heartbeat in MS cluster). Also place a checkbox next to „I want to customize my SafeQ installation“ and press „Next“.

    3

    Select your installation directory and press „Next“.

    4

    Select „Use an existing external database server“ and press „Next“.

    5

    Fill in the connection details for external MSSQL server the same way as for the first server (i.e. the same database names) and press „Test/Next“. Confirm popup dialogs by „OK“.

    6

    Untick checkbox at „Start SafeQ services after the installation is finished“ and modify rest of the options per your needs. Then press „Install“.

    7

    Finish the installation.

    images/s/-3eliqb/8502/404359a7d2ab19c9c7c58d12013124a386b28257/_/images/icons/emoticons/lightbulb_on.svg NOTE: SafeQ on the second node is currently not running and it is not configured.

    Unify YSoft SafeQ configuration and configure usage of reserved IP address for clustering

    images/s/-3eliqb/8502/404359a7d2ab19c9c7c58d12013124a386b28257/_/images/icons/emoticons/lightbulb_on.svg NOTE: In this step you will be filling in the virtual IP address that is reserved for clustering of YSoft SafeQ services. The IP address must be reachable by all workstations/MFPs that will be used with YSoft SafeQ. The same virtual IP address will be later specified in the Failover Cluster manager.

    I.  IP ADDRESS IN THE SAFEQ DATABASE

      Connect to the SafeQ database (by default SQDB5) via MS Management studio and modify the following:

    1. in table cluster_server set ip_address to the virtual IP address of SafeQ server

    2. in table cluster_server set description to  safeqserver

    3. in table smartq_servers set ip to the virtual IP address of SafeQ server

    4. in table smartq_servers set name to  safeqserver

    5. in table smartq_servers set code to  safeqserver-TEST

    II. CONFIGURATION IN <SAFEQ>\CONF\STARTUP.CONF

      Make sure that this configuration is identical on both SafeQ servers:

    1. set localGUID as follows:
      localGUID = safeq

    2. set SafeQserver as follows:
      smartQ-server-name = safeqserver

    3. replace IP address at parameter smartQ-server-ip by the virtual IP reserved for clustering of SafeQ services (same IP address as configured in the database).

    4. replace path at parameter spoolDir by the path that can be accessed by both SafeQ servers. This path will be used as a spooler for the jobs.

    III. CONFIGURATION IN <SAFEQ>\terminalserver\TerminalServer.exe.config

      Make sure that this configuration is identical on both SafeQ servers:

    1. replace IP address at parameter networkAddress by the virtual IP reserved for clustering of SafeQ services (same IP address as configured in the database).

    VI. CONFIGURATION IN <SAFEQ>\tomcat\conf\server.xml

      Make sure that this configuration is identical on both SafeQ servers:

    1. replace IP address at parameter address by the virtual IP reserved for clustering of SafeQ services (same IP address as configured in the database). Replace only values different than "localhost". Afterwards, there should be 3 occurrences replaced.

    Configure YSoft SafeQ in Microsoft Cluster Services

    1

    Open Failover Cluster Manager (cluadmin.msc)

    2

    Create a new resource for „YSoft SafeQ CML“:

      • Right-click the cluster name, select "Configure a service or application", select "Generic Service" and click next.

      • Select „YSoft SafeQ CML“ and click next.

      • Specify the virtual name „SafeQ-cluster“ and the virtual IP address that will be used by all the SafeQ services. The same IP address has been used in SafeQ configuration files.

      • Finish the wizard with no additional changes

    images/download/attachments/21955715/image2012-9-11_19_1_51.png

    3

    Add following SafeQ services to the the created resource:

      • YSoft SafeQ CML DBS

      • YSoft SafeQ LDAP Replicator Service

      • YSoft SafeQ Terminal Server

      • YSoft SafeQ Web Interface

    images/s/-3eliqb/8502/404359a7d2ab19c9c7c58d12013124a386b28257/_/images/icons/emoticons/lightbulb_on.svg NOTE: The procedure must be performed for every mentioned service.

      • Failover Cluster Manager -> in the left menu right-click the resource „SafeQ-cluster“ -> „Add a resource -> select „Generic Service“

      • Select one of the mentioned services, click next and finish the wizard with no additional changes

    images/download/attachments/21955715/image2012-9-11_19_23_39.png

     

    4

    Add dependency on the created resource for the following services:

      • YSoft SafeQ CML DBS

      • YSoft SafeQ LDAP Replicator Service

      • YSoft SafeQ Terminal Server

      • YSoft SafeQ Web Interface

    images/s/-3eliqb/8502/404359a7d2ab19c9c7c58d12013124a386b28257/_/images/icons/emoticons/lightbulb_on.svg NOTE: The procedure must be performed for every mentioned service

      • Failover Cluster Manager -> left-click your resource „SafeQ-cluster“

      • double-click the service where dependency should be added (e.g. start with „YSoft SafeQ CML DBS“)

      • on tab „Dependencies“ double-click the first empty row and then select resource „Name: SafeQ-cluster“ -> press „Apply“ and „OK

    images/download/attachments/21955715/image2012-9-11_19_27_3.png

    5

    Take resource „SafeQ-cluster“ offline (under „Services and applications“ right-click your resource and select „Take this service or application offline“). Then bring it online again.

    All your services shall be now online as shown here.

    images/download/attachments/21955715/image2012-9-11_19_31_51.png

     

    Finalizing the configuration

    1

    Set SafeQ services to run under the SafeQ service account.

    images/s/-3eliqb/8502/404359a7d2ab19c9c7c58d12013124a386b28257/_/images/icons/emoticons/lightbulb_on.svg NOTE: This step must be performed on both SafeQ servers

      • run „services.msc“ and go to the properties of all SafeQ services -> on tab „Log On“ select „This account“ and fill in details about the account which is local administrator and which has permissions to read/write to the shared spooler directory and to the destination for your scanned documents.

    2

    Activate SafeQ license on the second server with SafeQ

      • If the resource „SafeQ-cluster“ is not held by the second server, move it to the second SafeQ server via Failover Cluster Manager (cluadmin.msc). To move the resource it is necessary to go to  "services and applications" -> right-click „SafeQ-cluster“ -> select “Move this service or application to another node” -> select second node -> confirm the dialogue.

      • Log in to the SafeQ web interface via the clustered IP address.

      • Activate SafeQ using the second license.

    Test the basic failover functionality

    MOVING RESOURCE SAFEQ-CLUSTER BETWEEN THE SERVERS:

    • Try to move „SafeQ-cluster“ resource from one node to another. Go to "services and applications" -> right-click „SafeQ-cluster“ -> select “Move this service or application to another node” -> select second node -> confirm the dialogue.

    Expected result: resource is properly moved and all services are shown as on-line

    TEST PRINTING WITH FAILOVER

    • Move resource „SafeQ-cluster“ to the first SafeQ server. Then send a print job via the virtual IP address of the resource and port 515.

    • Move resource „SafeQ-cluster“ to the second SafeQ server and release the print job via the secure queue.

    Expected result: job is printed

    TEST Terminal SERVER FUNCTIONALITY WITH FAILOVER

    • Move resource „SafeQ-cluster“ to the first SafeQ server and wait till the Terminal Server is shown as Running on the SafeQ web interface. Then log in to the web interface via virtual IP address of the resource and  reinstall the embedded terminal. Verify that you can authenticate on the embedded terminal.

    • Move resource „SafeQ-cluster“ to the second server, wait till the Terminal Server is shown as Running on the SafeQ web interface and try to authenticate via the embedded terminal

    Expected result: authentication succeeds