Skip to main content
A newer release of this product is available.

Create a local UNIX user configuration for an SVM

Contributors

POST /name-services/unix-users

Introduced In: 9.9

Creates the local UNIX user configuration for an SVM.

Important notes

  • The default limit for local UNIX users is 32768.

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

full_name

string

User's full name.

id

integer

UNIX user ID of the specified user.

name

string

UNIX user name to be added to the local database.

primary_gid

integer

Primary group ID to which the user belongs.

skip_name_validation

boolean

Indicates whether or not the validation for the specified UNIX user name is disabled.

svm

svm

Example request
{
  "_links": {
    "self": {
      "href": "/api/resourcelink"
    }
  },
  "full_name": "string",
  "name": "string",
  "svm": {
    "_links": {
      "self": {
        "href": "/api/resourcelink"
      }
    },
    "name": "svm1",
    "uuid": "02c9e252-41be-11e9-81d5-00a0986138f7"
  }
}

Response

Status: 201, Created
Name Type Description

_links

_links

num_records

integer

Number of UNIX user records.

records

array[unix_user]

Example response
{
  "_links": {
    "next": {
      "href": "/api/resourcelink"
    },
    "self": {
      "href": "/api/resourcelink"
    }
  },
  "records": [
    {
      "_links": {
        "self": {
          "href": "/api/resourcelink"
        }
      },
      "full_name": "string",
      "name": "string",
      "svm": {
        "_links": {
          "self": {
            "href": "/api/resourcelink"
          }
        },
        "name": "svm1",
        "uuid": "02c9e252-41be-11e9-81d5-00a0986138f7"
      }
    }
  ]
}

Error

Status: Default

ONTAP Error Response Codes

Error Code Description

2621706

The specified SVM UUID is incorrect for the specified SVM name

23724066

The specified UNIX user name is too long. Maximum supported length is 64 characters.

3277051

The specified UNIX user name contains invalid characters. Valid characters are 0-9, A-Z, a-z, ".", "_" and "-".

23724128

The specified UNIX user full-name contains the invalid character ':'.

23724089

The specified UNIX user full-name is too long. Maximum supported length is 256 characters.

23724055

Internal error. Failed to create the UNIX user for the SVM. Verify that the cluster is healthy, then try the command again.

23724090

Configuring individual entries is not supported because file-only configuration is enabled.

3277025

Failed to create the UNIX user for the SVM because the system limit has been reached.

Name Type Description

error

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

svm

Name Type Description

_links

_links

name

string

The name of the SVM.

uuid

string

The unique identifier of the SVM.

unix_user

Name Type Description

_links

_links

full_name

string

User's full name.

id

integer

UNIX user ID of the specified user.

name

string

UNIX user name to be added to the local database.

primary_gid

integer

Primary group ID to which the user belongs.

skip_name_validation

boolean

Indicates whether or not the validation for the specified UNIX user name is disabled.

svm

svm

Name Type Description

next

href

self

href

error_arguments

Name Type Description

code

string

Argument code

message

string

Message argument

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.