Create dSource
Create Session
curl -s -X POST -k --data @- http://$DELPHIX_ENGINE_IP/resources/json/delphix/session \
-c ~/cookies.txt -H "Content-Type: application/json" <<EOF
{
"type": "APISession",
"version": {
"type": "APIVersion",
"major": $API_MAJOR,
"minor": $API_MINOR,
"micro": $API_MICRO
}
}
EOF
Authenticate
curl -s -X POST -k --data @- http://$DELPHIX_ENGINE_IP/resources/json/delphix/login \
-b ~/cookies.txt -c ~/cookies.txt -H "Content-Type: application/json" <<EOF
{
"type": "LoginRequest",
"username": "$DELPHIX_ADMIN_USER",
"password": "$DELPHIX_ADMIN_PASSWORD"
}
EOF
Create dSource
result=$(curl -s -X POST -k --data @- http://$DELPHIX_ENGINE_IP/resources/json/delphix/database/link -b ~/cookies.txt -H "Content-Type: application/json" <<EOF
{
"type": "LinkParameters",
"name": "$DELPHIX_DSOURCE_NAME",
"group": "$DELPHIX_GROUP_REF",
"linkData": {
"type": "AppDataStagedLinkData",
"config": "$DELPHIX_SRCCFG_REF",
"environmentUser": "$DELPHIX_STG_ENVUSER_REF",
"sourcingPolicy": {"logsyncEnabled": false, "type": "SourcingPolicy"},
"syncParameters": {
"parameters": {
"resync": true
},
"type": "AppDataSyncParameters"
},
"operations": {"preSync": [], "postSync": [], "type": "LinkedSourceOperations"},
"parameters":{
"dSourceType":"Full",
"mountPath":"$DELPHIX_DSOURCE_MOUNTPOINT",
"dbmultitenant":true,
"instanceName":"$DELPHIX_DSOURCE_NAME",
"dbid":"$DBID_OF_SOURCE_DATABASE",
"pdbName":"",
"restorefromtape":false,
"tapeparams":"",
"catalog_conn":"",
"send_params":"",
"dbrmanbkploc":"$BACKUP_LOC_DIR",
"dbctrlbkppiece":"$BACKUP_LOC_DIR/$CONTROLFILE_BACKUPPIECE",
"pitr":false,
"restoreTime":"",
"pitr_snapshots":false,
"tdeEnabled":false,
"walletpwd":"",
"tbsnames":"",
"channels":2,
"minimizeloggroups":false,
"config_settings_prov":[
{
"propertyName": "sga_max_size",
"value": "2500M"
},
{
"propertyName": "sga_target",
"value": "2500M"
},
{
"propertyName": "processes",
"value": "1000"
}
],
"custom_env_variables": [
{
"propertyName": "ORACLE_UNQNAME",
"value": "$DBNAME"
}
]
},
"stagingEnvironment": "$DELPHIX_STG_ENV_REF",
"stagingEnvironmentUser": "$DELPHIX_STG_ENVUSER_REF",
"stagingMountBase": ""
}
}
EOF
)
Note: - Update all UNIX variables in above snippet code as per your environment. - Above are list of parameters and its values will change as per dsource type. - Please refer dSource Parameters for list of parameter applicable for any given dSource Type.