Creating a copy group

Business Continuity Manager Web API Reference Guide

Version
9.9.1
Audience
anonymous
Part Number
MK-96HC137-03

The following is an example of the operation to create a copy group by using Figure 1.

Loading copy groups (YKLOAD)

In this operation example, the copy group definition file has already been loaded in Loading the TrueCopy copy group definition file (YKLOAD) of Defining a copy group. However, if you restart the BCM Web API server after loading, load the copy groups again.

Checking the status of TrueCopy copy group (YKQUERY)

First, check the status of the TrueCopy copy group CGTC01.

Request line
PUT https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body

For the cliname key value, specify YKQUERY. For the operands key values, specify the parameters of YKQUERY.

{"cliname":"YKQUERY", "operands":"GROUP(CGTC01) " }
Response body

Check the number of copy pairs for each state output to the simplexCt key value, etc., in the copyGroup key.

{"servletKey":"USERID-38-aabcaaaf", "ver":"0100",
"appData":{"bcmVer":"099100", "vendor":"Hitachi Vantara, Ltd.", "rc":0, "bcmMsg":[], 
"action":"submit", "cliname":"YKQUERY", 
"operands": "GROUP(CGTC01) DAD(LOCAL)",
"prefix":"USERID.PREFIX", 
"copyGroup":{
"ID":"CGTC01", "description":"TC copy group", "copyType":"TC", 
"primaryDADID":"LOCAL","secondaryDADID":"MID", "pairCt":3, 
"primarySCHSET":"0","secondarySCHSET":"0","groupCt":"1", "simplexCt":3, 
"pendingCt":0, "duplexCt":0, "transitionCt":0, "suspendOpCt":0, 
"suspendCuCt":0,"suspendVSCt":0, "swappingCt":0, "reversedCt":0, 
"suspendErCt":0,"invalidCt":0, "revrsyncCt":0, "holdCt":0, "holdErCt":0, 
"chkJnlCt":0, "holdTrnsCt":0,"noDeltaCt":0, "conslostCt":0, "priOnlineCt":0, 
"secOnlineCt":0, "CTDelta":"000 00:00:00","matchingPerCent":0}, 
"reused":false, "timeout":false}
Note:
The status of this copy group affects the procedures in Creating copy pairs for a TrueCopy copy group (YKMAKE), which are performed next.
  • To run YKMAKE SELECT(ALL), all copy pairs in the copy group must be in the SIMLEX status.
  • To run YKMAKE SELECT(COND), copy pairs in the copy group must be in the SIMLEX, PENDING, or DUPLEX status.

If true is output to the timeout key, as in the following, this indicates that the CLI command is still running.

{"servletKey":"USERID-38-aabcaaaf","ver":"0100","reused":false, "timeout":true}

Run the following API request at intervals until false is output to the timeout key.

Request line
GET https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body
None

Checking the status of Universal Replicator copy group (YKQUERY)

Next, check the status of the Universal Replicator copy group CGUR01.

Request line
PUT https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body

For the cliname key value, specify YKQUERY. For the operands key values, specify the parameters of YKQUERY.

{"cliname":"YKQUERY", "operands":"GROUP(CGUR01) " }
Response body

Check the number of copy pairs for each state output to the simplexCt key, etc., in the copyGroup key.

{"servletKey":"USERID-38-aabcaaaf", "ver":"0100",
"appData":{"bcmVer":"099100", "vendor":"Hitachi Vantara, Ltd.", "rc":0, "bcmMsg":[], 
"action":"submit", "cliname":"YKQUERY", 
"operands": "GROUP(CGUR01) DAD(LOCAL)",
"prefix":"USERID.PREFIX", 
"copyGroup":{
"ID":"CGUR01", "description":"UR copy group", "copyType":"UR", 
"primaryDADID":"MID","secondaryDADID":"REMOTE", "pairCt":3, 
"primarySCHSET":"0","secondarySCHSET":"0","groupCt":"1", "simplexCt":3, 
"pendingCt":0, "duplexCt":0, "transitionCt":0, "suspendOpCt":0, 
"suspendCuCt":0,"suspendVSCt":0, "swappingCt":0, "reversedCt":0, 
"suspendErCt":0,"invalidCt":0, "revrsyncCt":0, "holdCt":0, "holdErCt":0, 
"chkJnlCt":0, "holdTrnsCt":0,"noDeltaCt":0, "conslostCt":0, "priOnlineCt":0, 
"secOnlineCt":0, "CTDelta":"000 00:00:00","matchingPerCent":0}, 
"reused":false, "timeout":false}
Note:
The status of this copy group affects the procedures in Creating copy pairs for the Universal Replicator copy group (YKMAKE), which are performed next.
  • To run YKMAKE SELECT(ALL), all copy pairs in the copy group must be in the SIMLEX status.
  • To run YKMAKE SELECT(COND), copy pairs in the copy group must be in the SIMLEX, PENDING, or DUPLEX status.

If true is output to the timeout key, as in the following, this indicates that the CLI command is still running.

{"servletKey":"USERID-38-aabcaaaf","ver":"0100","reused":false, "timeout":true}

Run the following API request at intervals until false is output to the timeout key.

Request line
GET https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body
None

Creating copy pairs for a TrueCopy copy group (YKMAKE)

First, create copy pairs for the TrueCopy copy group CGTC01.

Request line
PUT https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body

For the cliname key value, specify YKMAKE. For the operands key values, specify the parameters of YKMAKE.

Tip:

To specify the SELECT(COND) parameter, YKQUERY must have been run on the same BCM Web API server beforehand. (In this example, YKQUERY was run immediately beforehand.)

{"cliname":"YKMAKE", "operands":"GROUP(CGTC01) SELECT(COND) " }
Response body
{"servletKey":"USERID-38-aabcaaaf","ver":"0100",
"appData":{"bcmVer":"099100", "vendor":"Hitachi Vantara, Ltd.", "rc":0, "bcmMsg":[], "action":"submit", "cliname":"YKMAKE", "operands":" GROUP(CGTC01) PREFIX(USERID.PREFIX) "}, "reused":false, "timeout":false}

Confirming that the creation of copy pairs for the TrueCopy copy group is complete (YKEWAIT)

Confirm that the creation of copy pairs for the TrueCopy copy group CGTC01 is complete.

Request line
PUT https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body

For the cliname key value, specify YKEWAIT. For the operands key values, specify the parameters of YKEWAIT.

{"cliname":"YKEWAIT", "operands":"GROUP(CGTC01) GOTO(DUPLEX) TIMEOUT(1440)" }
Response body
{"servletKey":"USERID-38-aabcaaaf", "ver":"0100",
"appData":{"bcmVer":"099100", "vendor":"Hitachi Vantara, Ltd.", "rc":0, "bcmMsg":[], "action":"submit", 
"cliname":" YKEWAIT", 
"operands":" GROUP(CGTC01) PREFIX(USERID.PREFIX) TIMEOUT(1440)", "prefix":"USERID.PREFIX",
"copyGroup":{
"ID":" CGTC01", "description":"TC copy group","copyType":"TC", "primaryDADID":"LOCAL",
"secondaryDADID":"MID", "pairCt":3, "primarySCHSET":"0","secondarySCHSET":"0",
"simplexCt":0, "pendingCt":0, "duplexCt":3, "transitionCt":0, "suspendOpCt":0, 
"suspendCuCt":0,"suspendVSCt":0, "swappingCt":0, "reversedCt":0, "suspendErCt":0,
"invalidCt":0, "revrsyncCt":0, "holdCt":0, "holdErCt":0, "chkJnlCt":0, "holdTrnsCt":0,
"noDeltaCt":0, "conslostCt":0, "priOnlineCt":0, "secOnlineCt":0
} }
}, "reused":false, "timeout":false}

If 4 is returned for the rc key value (a timeout occurs beyond the TIMEOUT parameter value), run this API request again.

If true is output to the timeout key, as in the following, this indicates that the CLI command is still running.

{"servletKey":"USERID-38-aabcaaaf","ver":"0100",
"reused":false, "timeout":true}

Run the following API request at intervals until false is output to the timeout key.

Request line
GET https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body
None

If false is returned for the timeout key, check whether the value of the rc key is 0 (the transition to DUPLEX status is complete). If it is other than 0, you can output copy pairs that are not in DUPLEX or PENDING status by running the following API request. (This enables you to find copy pairs that are in error.)

Request line
PUT https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body
{"cliname":"YKGETGRP", "operands":"GROUP(CGTC01) PREFIX(USERID.PREFIX) XSTATE(DUPLEX,PENDING)" }

Creating copy pairs for the Universal Replicator copy group (YKMAKE)

Next, create copy pairs for the Universal Replicator copy group CGUR01.

Request line
PUT https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body

For the cliname key value, specify YKMAKE. For the operands key values, specify the parameters of YKMAKE.

Tip:

To specify the SELECT(COND) parameter, YKQUERY must have been run on the same BCM Web API server beforehand. (In this example, YKQUERY was run immediately beforehand.)

{"cliname":"YKMAKE", "operands":"GROUP(CGUR01) SELECT(COND) " }
Response body
{"servletKey":"USERID-38-aabcaaaf","ver":"0100",
"appData":{"bcmVer":"099100", "vendor":"Hitachi Vantara, Ltd.", "rc":0, "bcmMsg":[], "action":"submit", "cliname":"YKMAKE", "operands":" GROUP(CGUR01) PREFIX(USERID.PREFIX) "}, "reused":false, "timeout":false}

Confirming that the creation of copy pairs for the Universal Replicator copy group is complete (YKEWAIT)

Confirm that the creation of copy pairs for the Universal Replicator copy group CGUR01 is complete.

Example of a request line
PUT https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body

For the cliname key value, specify YKEWAIT. For the operands key values, specify the parameters of YKEWAIT.

{"cliname":"YKEWAIT", "operands":"GROUP(CGUR01) GOTO(DUPLEX) TIMEOUT(1440)" }
Response body
{"servletKey":"USERID-38-aabcaaaf", "ver":"0100",
"appData":{"bcmVer":"099100", "vendor":"Hitachi Vantara, Ltd.", "rc":0, "bcmMsg":[], "action":"submit", 
"cliname":" YKEWAIT", 
"operands":" GROUP(CGUR01) PREFIX(USERID.PREFIX) TIMEOUT(1440)", "prefix":"USERID.PREFIX",
"copyGroup":{
"ID":" CGUR01", "description":"UR copy group","copyType":"UR", "primaryDADID":"MID",
"secondaryDADID":"REMOTE", "pairCt":3, "primarySCHSET":"0","secondarySCHSET":"0",
"groupCt":"1", "simplexCt":0, "pendingCt":0, "duplexCt":3, "transitionCt":0, "suspendOpCt":0, 
"suspendCuCt":0,"suspendVSCt":0, "swappingCt":0, "reversedCt":0, "suspendErCt":0,
"invalidCt":0, "revrsyncCt":0, "holdCt":0, "holdErCt":0, "chkJnlCt":0, "holdTrnsCt":0,
"noDeltaCt":0, "conslostCt":0, "priOnlineCt":0, "secOnlineCt":0
} }
}, "reused":false, "timeout":false}

If 4 is returned for the rc key value (a timeout occurs beyond the TIMEOUT parameter value), run this API request again.

If true is output to the timeout key, as in the following, this indicates that the CLI command is still running.

{"servletKey":"USERID-38-aabcaaaf","ver":"0100",
"reused":false, "timeout":true}
Run the following API request at intervals until false is output to the timeout key.
Request line
GET https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body
None

If false is returned for the timeout key, check whether the value of the rc key is 0 (the transition to DUPLEX status is complete). If it is other than 0, you can output copy pairs that are not in DUPLEX or PENDING status by running the following API request. (This enables you to find copy pairs that are in error.)

Request line
PUT https://IP-address-of-the-z/OSMF-server/zosmf/tsoApp/app/USERID-38-aabcaaaf/YKAPI
Request body
{"cliname":"YKGETGRP", "operands":"GROUP(CGUR01) PREFIX(USERID.PREFIX) XSTATE(DUPLEX,PENDING)" }
Response body
{"servletKey":"USERID-38-aabcaaaf","ver":"0100",
"appData":{"bcmVer":"099100", "vendor":"Hitachi Vantara, Ltd.", "rc":0, "bcmMsg":[], "action":"submit", 
"cliname":" YKGETGRP", 
"operands":" GROUP(CGUR01) PREFIX(USERID.PREFIX)", "prefix":"USERID.PREFIX",
"copyGroup":{
"ID":" CGUR01", "description":"UR copy group","copyType":"UR", "primaryDADID":"MID",
"secondaryDADID":"REMOTE", "pairCt":3, "primarySCHSET":"0","secondarySCHSET":"0",
"groupCt":"1", "simplexCt":0, "pendingCt":1, "duplexCt":1, "transitionCt":0, "suspendOpCt":0, 
"suspendCuCt":1,"suspendVSCt":0, "swappingCt":0, "reversedCt":0, "suspendErCt":0,
"invalidCt":0, "revrsyncCt":0, "holdCt":0, "holdErCt":0, "chkJnlCt":0, "holdTrnsCt":0,
"noDeltaCt":0, "conslostCt":0, "priOnlineCt":0, "secOnlineCt":0, "priSoftFenceCt":0,
"secSoftFenceCt":0, "priSPIDFenceCt":0, "secSPIDFenceCt":0, "CTDelta":"000 00:00:00",
"matchingPerCent":"",  "InitPace":"NORMAL", "protectMode":"PROTECT", "mirrorID":"1",
"errorLevel":"GROUP", "CTTimeMode":"ASIS", "pathID":"00", "exctgEnable":"false"
},"CTGroup":[ {
   "groupIndex":1, "CTGroupID":"11", "subCTGroupID":"21", "pairCt":"3",
   "simplexCt":0, "pendingCt":1, "duplexCt":1, "transitionCt":0, "suspendOpCt":0,
 "suspendCuCt":1,"suspendVSCt":0, "swappingCt":0, "reversedCt":0, "suspendErCt":0,
 "invalidCt":0, "revrsyncCt":0, "holdCt":0, "holdErCt":0, "chkJnlCt":0, "holdTrnsCt":0,
 "noDeltaCt":0, "conslostCt":0, "priOnlineCt":0, "secOnlineCt":0, "priSoftFenceCt":0,
 "secSoftFenceCt":0, "priSPIDFenceCt":0, "secSPIDFenceCt":0, "CTDelta":"000 00:00:00",
 "matchingPerCent":60,
"pair":[
{ "pairIndex":1, "state":"DUPLEX",
"matchingPerCent":100, "reversed":"N",
"pri":{ "devn":"2230", "serialNum":"22222", "CUNum":"22", "SSID":"2211", "CCA":"30",
"IFType":"4040","model":"VSPG1000",
"hostStatus":"OFFLINE", "fenceStatus":"UNFENCE" },
        "sec":{ "devn":"3330", "serialNum":"33333", "CUNum":"33", "SSID":"3311", "CCA":"30",
              "IFType":"4040","model":"VSPG1000",
  "hostStatus":"OFFLINE", "fenceStatus":"UNFENCE" }  },
{ "pairIndex":2, "state":"PENDING",
 "matchingPerCent":80, "reversed":"N",
"pri":{ "devn":"2231", "serialNum":"22222", "CUNum":"22", "SSID":"2211", "CCA":"31",
"IFType":"4040","model":"VSPG1000",
hostStatus":"OFFLINE", "fenceStatus":"UNFENCE" },
        "sec":{ "devn":"3331", "serialNum":"33333", "CUNum":"33", "SSID":"3311", "CCA":"31",
              "IFType":"4040","model":"VSPG1000",
              "hostStatus":"OFFLINE", "fenceStatus":"UNFENCE" }  },
{ "pairIndex":3, "state":"SUSPCU",
"matchingPerCent":0, "reversed":"N",
"pri":{ "devn":"2232", "serialNum":"22222", "CUNum":"22", "SSID":"2211", "CCA":"32",
"IFType":"4040","model":"VSPG1000",
"hostStatus":"OFFLINE", "fenceStatus":"UNFENCE" },
        "sec":{ "devn":"3332", "serialNum":"33333", "CUNum":"33", "SSID":"3311", "CCA":"32",
             "IFType":"4040","model":"VSPG1000",
 "hostStatus":"OFFLINE", "fenceStatus":"UNFENCE" }  },
] } ] } }
}, "reused":false, "timeout":false}