Adding an SD secondary to a cluster

About this task

Let's take a standalone OneDB server and turn it into a cluster. First let's add an SD secondary server. (This scenario assumes that the shared disk file system has already been set up and the DBA account is used.)

Procedure

  1. Prepare the SQLHOSTS file.
    Make sure the SQHOSTS file at both the primary and SDS node has entries for the other server:
    g_mach11  group     -         -          i=10
     myprim    ontlitcp  primhost  prim_port  g=g_mach11
     sds1      ontlitcp  sds1host  sds1_port  g=g_mach11
    Note:

    Note that the use of groups here is optional. However, we include it to prepare for an example below.

  2. Set the primary as the owner of the shared disk.
    On the primary, run:
    onmode -d set SDS primary myprim
  3. Configure the SD secondary.
      • Make sure these match the ONCONFIG of the primary: ROOTNAME, ROOTPATH, ROOTOFFSET, ROOTSIZE, PHYSDBS, PHYSFILE, LOGFILES, and LOGSIZE.
    1. Set SDS_ENABLE to 1.
    2. Configure SDS_PAGING and SDS_TEMPDBS.
    For example:
    SDS_ENABLE          1
    SDS_PAGING          /onedb/sds/dbspaces/page_1,/onedb/sds/dbspaces/page_2
    SDS_TEMPDBS         sdstmpdbs1,/onedb/sds/dbspaces/sdstmpdbs1,2,0,16000
    UPDATABLE_SECONDARY 1
    TEMPTAB_NOLOG       1       
    
  4. Start the SD secondary using:
    oninit

    The SD secondary is now up and running! You can check the cluster status using the onstat -g sds command at both the primary and secondary servers. Here's what our cluster looks like:

    Figure 1: The cluster: Primary and one SD secondary