Skip to main content

Create an SVM peer permission

Contributors

POST /svm/peer-permissions

Introduced In: 9.6

Creates an SVM peer permission.

Required properties

  • svm.name or svm.uuid - SVM name

  • cluster_peer.uuid or cluster_peer.name - Peer cluster name or peer cluster UUID

  • applications - Peering applications

  • vserver peer permission create

Examples

The following examples show how to create SVM peer permissions.

  1. Creates an SVM peer permission entry with the local SVM and cluster peer names

 POST "/api/svm/peer-permissions" '{"cluster_peer":{"name":"cluster2"}, "svm":{"name":"VS1"}, "applications":["snapmirror"]}'
  1. Creates an SVM peer permission entry with the local SVM and cluster peer UUID

 POST "/api/svm/peer-permissions" '{"cluster_peer":{"uuid":"d3268a74-ee76-11e8-a9bb-005056ac6dc9"}, "svm":{"uuid":"8f467b93-f2f1-11e8-9027-005056ac81fc"}, "applications":["snapmirror"]}'
  1. Creates an SVM peer permission entry with all SVMs and the cluster peer name

 POST "/api/svm/peer-permissions" '{"cluster_peer":{"name":"cluster2"}, "svm":{"name":"*"}, "applications":["snapmirror"]}'

Parameters

Name Type In Required Description

return_records

boolean

query

False

The default is false. If set to true, the records are returned.

  • Default value:

Request Body

Name Type Description

_links

_links

applications

array[string]

A list of applications for an SVM peer relationship.

cluster_peer

cluster_peer

Peer cluster details

svm

svm

Local SVM permitted for peer relationship. To create peer permissions for all SVMs, specify the SVM name as "*".

Example request
{
  "_links": {
    "self": {
      "href": "/api/resourcelink"
    }
  },
  "applications": [
    "snapmirror",
    "flexcache"
  ],
  "cluster_peer": {
    "_links": {
      "self": {
        "href": "/api/resourcelink"
      }
    },
    "name": "cluster2",
    "uuid": "ebe27c49-1adf-4496-8335-ab862aebebf2"
  },
  "svm": {
    "_links": {
      "self": {
        "href": "/api/resourcelink"
      }
    },
    "name": "svm1",
    "uuid": "02c9e252-41be-11e9-81d5-00a0986138f7"
  }
}

Response

Status: 201, Created
Name Type Description

_links

_links

applications

array[string]

A list of applications for an SVM peer relationship.

cluster_peer

cluster_peer

Peer cluster details

svm

svm

Local SVM permitted for peer relationship. To create peer permissions for all SVMs, specify the SVM name as "*".

Example response
{
  "_links": {
    "self": {
      "href": "/api/resourcelink"
    }
  },
  "applications": [
    "snapmirror",
    "flexcache"
  ],
  "cluster_peer": {
    "_links": {
      "self": {
        "href": "/api/resourcelink"
      }
    },
    "name": "cluster2",
    "uuid": "ebe27c49-1adf-4496-8335-ab862aebebf2"
  },
  "svm": {
    "_links": {
      "self": {
        "href": "/api/resourcelink"
      }
    },
    "name": "svm1",
    "uuid": "02c9e252-41be-11e9-81d5-00a0986138f7"
  }
}

Headers

Name Description Type

Location

Useful for tracking the resource location

string

Error

Status: Default

ONTAP Error Response Codes

Error codes Description

26345572

{field} is a required field.

26345573

Failed to find the SVM or volume UUID with name.

26345574

Failed to find the SVM or volume name with UUID.

26345575

The specified peer cluster name and peer cluster UUID do not match.

9896057

SVM peer permission already exists.

Name Type Description

error

returned_error

Example error
{
  "error": {
    "arguments": [
      {
        "code": "string",
        "message": "string"
      }
    ],
    "code": "4",
    "message": "entry doesn't exist",
    "target": "uuid"
  }
}

Definitions

See Definitions

href

Name Type Description

href

string

Name Type Description

self

href

cluster_peer

Peer cluster details

Name Type Description

_links

_links

name

string

uuid

string

svm

Local SVM permitted for peer relationship. To create peer permissions for all SVMs, specify the SVM name as "*".

Name Type Description

_links

_links

name

string

The name of the SVM. This field cannot be specified in a PATCH method.

uuid

string

The unique identifier of the SVM. This field cannot be specified in a PATCH method.

svm_peer_permission

Manage SVM peer permissions.

Name Type Description

_links

_links

applications

array[string]

A list of applications for an SVM peer relationship.

cluster_peer

cluster_peer

Peer cluster details

svm

svm

Local SVM permitted for peer relationship. To create peer permissions for all SVMs, specify the SVM name as "*".

error_arguments

Name Type Description

code

string

Argument code

message

string

Message argument

returned_error

Name Type Description

arguments

array[error_arguments]

Message arguments

code

string

Error code

message

string

Error message

target

string

The target parameter that caused the error.