Technology Blogs by Members
Explore a vibrant mix of technical expertise, industry insights, and tech buzz in member blogs covering SAP products, technology, and events. Get in the mix!
Showing results for 
Search instead for 
Did you mean: 
Active Contributor
This blog post/Article is for all level of SAP Basis System Administrators who wants to setup simple Disaster Site (DR) solution (Active-Passive) for their SAP Systems running with SAP ASE 16.0 (Sybase) Database with guided steps.

This blog post will focus on “How to Setup/Implement”, “How to reconfigure”, “How to Uninstall” DR Site based on SAP ASE (Sybase) Database.

The process described here will setup simple DR site for clustered SAP ASE 16.0 (Sybase) database on Windows 2012 OS platform with/without Fail-over Cluster.


  1. Process / Setup Overview

  2. Preparation & Prerequisites

  3. Installation Steps

  4. Post-Installation Steps

  5. Other Tasks


Process / Setup Overview

At the end of DR Site setup as described in this article, the Primary & DR Site system landscape will look like the following:

In the above image, the SAP ASE 16.0 Database, RMA Agent, SRS are part of the Microsoft Windows OS Fail-over Cluster in Final Setup.

Let's try to understand who will be the major payers and how they will play their role in the whole setup. This is very important part because execution with proper understanding is called good quality of genuine SAP Consultant.

Components playing major role in whole Setup:

Source Database (also called a primary database): A database that is the source of data and transactions that modify data in the target database.

Replication Management Agent (RMA) (also called replication agent): A database (depending on the source database)-specific agent that supports data and transaction replication from a source database to a replication server.

Sybase Replication Server Process (SRS): The server receives replicated data and transactions from the source database via the replication agent and controls its transition to the target database.

Target Database (also called companion/standby/DR site’s database): A database that is the target of data and transactions that are modified in the source database.

MS Failover Cluster Manager (optional): This will be required to provide High Availability to the installed Sybase Replication Components like RMA, SRS

How the setup will work?
Let’s take brief overview without going much in detail.

  • During the initial load and replication, the replication agent (RMA) reads the transaction log of the source database and generates the Log Transfer Language (LTL) output, which is a notation (using a language) that the replication server (SRS) uses to process identified and collected data throughout the replication channel from the source to the target database.

  • The primary replication server (SRS) receives the LTL from a replication agent and sends the replicated data to the companion replication server (Standby/DR Site) (when a split between primary replication server and replicate replication server is used). Otherwise, the sending does not take place because the data is operated by the single replication server instance). The companion replication server converts the received data from the LTL to the native format and language used by the target database. It sends the replicate data to the target database for processing, which closes the replication process (if it is committed in the target database).

  • For data consistency reasons (no loss of data) each replication server uses a database called the Replication Server System Database (RSSD) to store replication data and metadata. This information can be used by a replication agent to provide advanced replication features such as transfer of database data logic (procedures).

Preparation / Prerequisites :

  • System Environment used on Primary Site and DR site:

    SAP Solution/Application:
    SAP NW 7.4 ABAP
    Database: SAP ASE (Sybase)
    OS: Windows Server 2012 R2 Datacenter 64bit
    HA: MS Failover Cluster Manager v 6.3
    SID: POM / ECM

  • SAP Media used in the Setup:
    Database Installation media of SAP ASE Database
    (Media Number : 51053868_2)

  • Installation Guide : HADR Users Guide for SAP ASE

  • Prerequisites:

    • Primary Site is running well with consistent SAP ASE (Sybase) database with or without HA on Windows Server OS

    • DR Site is installed on OS (same as Primary site environemnt) with same SAP software components like SAP Application Servers, SAP Kernel, SAP ASE (Sybase) Database, Failover Cluster Manager by way of performing Fresh SAP system installation or System Copy procedure

    • Basic Knowledge of MS Failover cluster manager will be required, if

    • The script/response file templates referred here are available with completeness in SAP’s official document “ASE HADR Users Guide for SAP ASE release” (so called “official guide” in this blog). The response file / scrips will need to be prepared properly with correct directory path, hostname and other required input with great ownership and responsibility.

    • The following Port communication will need to be enable between Primary Database and Companion (DR Site) Database hosts either at Virtual Hosts level or at Physical Hosts level: 4909, 6996 to 7000

    • The following Port communication will need to be disable between Message Server, Application Servers and Database of Primary and Companion (DR Site) sites either at Virtual Hosts level or at Physical Hosts level. This will avoid cross talk communication during Failover testing.     

      • From:
        Message Server Port, Dispatcher ports of Application Server (Primary/DR site)

      • To:Database server ports (4901, 4902) (DR site / Primary site)

    • Prepare hosts.allow file at location %SYBROOT% location (e.g. D:\sybase\POM) with following input format on both Sybase Database Servers to enable smooth communication of Sybase Backup Server with remote Sybase Database.<local sybase backup server> <remote sybase backup server>

    • The password of users sapsa, sa at Sybase Database level and users syb<sid> at OS level should be known and user account sapsa, syb<sid> should be accessible


  • Installation Steps :

    Step-1:  Install Data Movement Component

    Location: Database Host of Primary and DR Site
    Installation User:

    As mentioned in official guide, prepare setup response file and Install Data Movement Component without silent installation along with SAP ASE Cockpit feature. The input USER_INSTALL_DIR is very important in this small step.

    If SAP ASE Cockpit component is already got installed on database host before then you can ignore its installation. In other case, do not forget to complete the installation with configuration part of SAP ASE cockpit. Refer SAP Note 2272320 for complete installation information and configuration of SAP ASE Cockpit, but you can do it at the end with great free time

    Step-2: Install DR Agent Service (RMA)

    Location: Database Host of Primary and DR Site
    Installation User:

    One can create Batch script with following commands to Install DR Agent Service (RMA) manually on Host-1.  Provide correct SID of Database.

    set SID=POM
    call %SYBASE%\DM\SYBASE.bat
    %SYBASE%\SCC-3_2\plugins\DR\bin\amd64\drservice.exe -install %SID%
    call %SYBASE_OLD%\SYBASE.bat
    sc config SybaseDRAgent_%SID% obj= .\%USERNAME% password= Password123
    for /f "tokens=*" %%i in ('sc sdshow SYBSQL_%SID%') do set sddl=%%i
    sc sdset  SybaseDRAgent_%SID% %sddl%
    net start SybaseDRAgent_%SID%

    As result, the following Windows Service will be created :

    Copy this batch script file to Host-2, Failover Cluster to Host-2 and Install DR Agent Service (RMA), same as above. This step is necessary if you want to include RMA agent service in Failover Cluster.

    Step-3: Apply SAP Note 2754218 ( if it is required) and Restart RAM Service

    Location: Database Host of Primary and DR Site
    Installation User:

    • As per SAP Note 2754218, change .../RMA-16_0/config/bootstrap.prop with Cluster IP of Database Server and Restart RMA Agent Service

      This action step is very important step; otherwise, setuphadr script will end
      with errors in database materialization part for <SID> database.

    • Unlock sa user
      isql -Usapsso –P<password> -SPOM -X -w9999
      sp_locklogin sa, unlock

        Steps-4: Prepare Response file ( for setuphadr script & Execute setuphadr script

          Location: Database Host of Primary and DR Site
Installation User:

    • Prepare Response file (rs) for setuphadr script as per the guided response file templates of official guide. Be careful with respect to the inputs of Primary and Companion Server.

    • Very Important Parameters to change before execution of setuphadr script for Primary Site database:

      PRIM.backup_server_dump_directory=<any big disk space where the database
      backup can be exported>

    • The next step will be to execute setuphadr script with the prepared response file. As a result of executing the setuphadr script on Database Host of Primary and DR Site the RMA agent, Replication Server Environment will be setup automatically along with Database Materialization (if it is opted).

      • Run setuphadr script with above generated Response file on Primary Site. The execution output should be without error. If there is error, repeat the execution of setuphadr script.

    • Run setuphadr script with above generated Response file on Companion/Standby/DR site with following changed parameter:
      backup_server_dump_directory= any big disk space where the database backup can be exported>

    • The execution output should be without error. If there is error, repeat the execution of setuphadr script till you get the clean result.

The following execution output is with AUTO Database Materialization option in which the Database backup will be executed automatically on Primary Database Host and it will be copied and restored automatically on DR Site as per the internal steps of setuphadr script.

    • Check sap_status path. The output should be like the following. If the output is not as the following information, then re-execute the setuphadr script first on Primary Database Host and then on companion/DR site database host as mentioned above. The opened port communication plays important role in having valid result in ‘sap_status path’



  • Post-Installation Steps:

    Steps-5:  Post Installation Steps:Location: Database Host of Primary and DR Site     

    Installation User: <domain>\syb<sid> , <domain>\<sid>adm

    • On Host-1 Restart Replication Server as a Service on Windows

    • Export Registry Key of Replication Server from Host-1 and Import to Host-2

      • Registry key to export: HKEY_LOCAL_MACHINE -> SOFTWARE -> SYBASE -> <SID>_REP_<SiteName>

    • Failover Cluster to another Host-2 - > Create & Restart Replication Server as a Service on Windows on Host-2 -> Check sap_status path 

    • Configure Replication Server with sap_tune_rs

    • Lock sa user
      isql -Usapsso –P<password> -SPOM -X -w9999
      sp_locklogin sa, lock

    • Add the DR_admin Entry to SecureStore under <sid>adm user

    • Include DR Agent Service (RMA), Replication Server Service in Failover Cluster like the following reference screen. Test FailOver/Failback in Failover Cluster Manager.

    • Check sap_status path , Test HADR Configuration , Save the Response file, scripts for future use

    • Setup & Access SAP ASE Cockpit and Monitor Primary & DR Site databases
      (refer sap note 2272320)

  • Other Tasks: (on demand… but do not ignore):

    • Perform Planned & Unplanned Fail over/Fail Back Testing (every 6 months) as per SAP Note 2165143

    • Perform Re-materialization / to Re-sync Sybase Database using SAP Note 2089569

      High level Steps Overview to Uninstall DR Site Configuration:

      1. Remove Replication Server Service, RMA Agent Servie from Failover Cluster & Restart them if they were part of Failover Cluster Manager

      2. Execute command sap_teardown under <domain>/syb<sid> OS level user
        The command should be finished without any kind of single error.

      3. check sap_status path and check that it should not return anything in configuration. If you see the configuration settings, then re-execute the command sap_teardown same as above 

      High level Steps Overview to Re-configure/ Re-Install DR Site:

      • Perform the steps as mentioned in Uninstallation part of this Blog

      • Perform the required steps as mentioned in Installation part of this Blog


Generally, the people will find the relevant technical setup guide or sap notes for the same topic but it does not give more confidence to the administrator when it is question of setup the complete DR site for SAP ASE (Sybase) database.

The intention of publishing this article/post/blog was to share technical knowledge to setup simple DR site for SAP Systems running SAP ASE (Sybase) Database with possible high level overview steps to give more confidence to the Technical System Administrators (SAP Basis Consultants).


SAP HADR Users Guide:

SAP Note 2272320 - How to install SAP ASE Cockpit on Windows Platform - SAP ASE
Labels in this area