Replication Links - List By Server

Gets a list of replication links.

GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/replicationLinks?api-version=2021-11-01

URI Parameters

Name In Required Type Description
resourceGroupName
path True

string

The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.

serverName
path True

string

The name of the server.

subscriptionId
path True

string

The subscription ID that identifies an Azure subscription.

api-version
query True

string

The API version to use for the request.

Responses

Name Type Description
200 OK

ReplicationLinkListResult

Successfully retrieved the list of replication links.

Other Status Codes

*** Error Responses: ***

  • 400 ReplicationLinksReplicationLinkNameIsInvalid - Replication link name should be a valid guid.

  • 400 ReplicationLinksDeleteIsNotSupported - This action is not yet available, please use 2014-04-01 for this action.

  • 404 ResourceNotFound - The requested resource was not found.

  • 404 SubscriptionDoesNotHaveServer - The requested server was not found

  • 404 ServerNotInSubscriptionResourceGroup - Specified server does not exist in the specified resource group and subscription.

Examples

Sample Request

GET https://management.azure.com/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default/providers/Microsoft.Sql/servers/sourcesvr/replicationLinks?api-version=2021-11-01

Sample Response

{
  "value": [
    {
      "properties": {
        "partnerServer": "testsvr",
        "partnerDatabase": "tetha-db",
        "partnerLocation": "Japan East",
        "role": "Primary",
        "partnerRole": "Secondary",
        "replicationMode": "ASYNC",
        "startTime": "2018-06-21T08:11:46.907Z",
        "percentComplete": 100,
        "replicationState": "CATCH_UP",
        "isTerminationAllowed": true,
        "linkType": "GEO"
      },
      "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/sourcesvr/databases/tetha-db/replicationLinks/fb92de60-eb87-4a58-b250-3362d0cfdf26",
      "name": "fb92de60-eb87-4a58-b250-3362d0cfdf26"
    },
    {
      "properties": {
        "partnerServer": "targetsvr",
        "partnerDatabase": "tetha-db",
        "partnerLocation": "Japan East",
        "role": "Primary",
        "partnerRole": "Secondary",
        "replicationMode": "ASYNC",
        "startTime": "2018-06-21T08:11:34.423Z",
        "percentComplete": 100,
        "replicationState": "CATCH_UP",
        "isTerminationAllowed": true,
        "linkType": "GEO"
      },
      "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/sourcesvr/databases/tetha-db/replicationLinks/6ad1eefc-18a2-4fcb-94f3-4b654ba788d7",
      "name": "6ad1eefc-18a2-4fcb-94f3-4b654ba788d7"
    },
    {
      "properties": {
        "partnerServer": "testsvr",
        "partnerDatabase": "gamma-db",
        "partnerLocation": "Japan East",
        "role": "Primary",
        "partnerRole": "Secondary",
        "replicationMode": "ASYNC",
        "startTime": "2018-06-21T08:12:43.783Z",
        "percentComplete": 100,
        "replicationState": "CATCH_UP",
        "isTerminationAllowed": true,
        "linkType": "GEO"
      },
      "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/Default-SQL-Onebox/providers/Microsoft.Sql/servers/sourcesvr/databases/gamma-db/replicationLinks/4891ca10-ebd0-47d7-9182-c722651780fb",
      "name": "4891ca10-ebd0-47d7-9182-c722651780fb"
    }
  ]
}

Definitions

Name Description
ReplicationLink

A replication link.

ReplicationLinkListResult

A list of replication links.

ReplicationLinkType

Link type (GEO, NAMED, STANDBY).

ReplicationRole

Local replication role.

ReplicationState

Replication state (PENDING, SEEDING, CATCHUP, SUSPENDED).

A replication link.

Name Type Description
id

string

Resource ID.

name

string

Resource name.

properties.isTerminationAllowed

boolean

Whether the user is currently allowed to terminate the link.

properties.linkType

ReplicationLinkType

Link type (GEO, NAMED, STANDBY).

properties.partnerDatabase

string

Resource partner database.

properties.partnerLocation

string

Resource partner location.

properties.partnerRole

ReplicationRole

Partner replication role.

properties.partnerServer

string

Resource partner server.

properties.percentComplete

integer

Seeding completion percentage for the link.

properties.replicationMode

string

Replication mode.

properties.replicationState

ReplicationState

Replication state (PENDING, SEEDING, CATCHUP, SUSPENDED).

properties.role

ReplicationRole

Local replication role.

properties.startTime

string

Time at which the link was created.

type

string

Resource type.

ReplicationLinkListResult

A list of replication links.

Name Type Description
nextLink

string

Link to retrieve next page of results.

value

ReplicationLink[]

Array of results.

ReplicationLinkType

Link type (GEO, NAMED, STANDBY).

Name Type Description
GEO

string

NAMED

string

STANDBY

string

ReplicationRole

Local replication role.

Name Type Description
Copy

string

NonReadableSecondary

string

Primary

string

Secondary

string

Source

string

ReplicationState

Replication state (PENDING, SEEDING, CATCHUP, SUSPENDED).

Name Type Description
CATCH_UP

string

PENDING

string

SEEDING

string

SUSPENDED

string