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

Support AutoSupport endpoint overview

Contributors

Overview

AutoSupport is the NetApp call home mechanism. AutoSupport sends configuration details, status details, and error reporting details to NetApp.

This endpoint supports both GET and PATCH calls. GET is used to retrieve AutoSupport configuration details for the cluster and PATCH is used to modify the AutoSupport configuration of the cluster. You can also use GET calls to check AutoSupport connectivity.


Examples

Configuring 'to' addresses

The following example configures AutoSupport to send emails to 'to' addresses.

# The API:
PATCH /support/autosupport

# The call:
curl -X PATCH "https://<mgmt-ip>/api/support/autosupport" -H "accept: application/hal+json" -H "Content-Type: application/json" -d "{ \"to\": [ \"abc@netapp.com\", \"xyz@netapp.com\" ]}"

# The response:
200 OK
{}

Configuring 'SMTP' transport

The following example configures AutoSupport to use 'SMTP' transport. The default transport is 'HTTPS'.

# The API:
PATCH /support/autosupport

# The call:
curl -X PATCH "https://<mgmt-ip>/api/support/autosupport" -H "accept: application/hal+json" -H "Content-Type: application/json" -d "{ \"transport\": \"smtp\"}"

# The response:
200 OK
{}

Retrieving the AutoSupport configuration

The following example retrieves AutoSupport configuration for the cluster.

# The API:
GET /support/autosupport

# The call:
curl -X GET "https://<mgmt-ip>/api/support/autosupport" -H "accept: application/hal+json"

# The response:
200 OK
{
"enabled": true,
"mail_hosts": [
  "mailhost"
],
"from": "Postmaster",
"to": [
  "abc@netapp.com",
  "xyz@netapp.com"
],
"contact_support": true,
"transport": "smtp",
"proxy_url": "",
"is_minimal": false,
"_links": {
  "self": {
    "href": "/api/support/autosupport"
  }
}
}

Retrieving AutoSupport connectivity issues

The following example retrieves AutoSupport connectivity issues for the cluster. The fields=issues parameter must be specified, for the response to return connectivity issues. The corrective_action section might contain commands which needs to be executed on the ONTAP CLI.

Note that the connectivity check can take up to 10 seconds to complete.

# The API:
GET /support/autosupport

# The call:
curl -X GET "https://<mgmt-ip>/api/support/autosupport?fields=issues" -H "accept: application/hal+json"

# The response:
200 OK
{
"issues": [
  {
    "node": {
      "name": "node3",
      "uuid": "0ecfd0a6-f1b3-11e8-9d9f-005056bbaadc",
      "_links": {
        "self": {
          "href": "/api/cluster/nodes/0ecfd0a6-f1b3-11e8-9d9f-005056bbaadc"
        }
      }
    },
    "issue": {
      "message": "SMTP connectivity check failed for destination: mailhost. Error: Could not resolve host - 'mailhost'",
      "code": "53149746"
    },
    "corrective_action": {
      "message": "Check the hostname of the SMTP server",
      "code": "53149746"
    }
  },
  {
    "node": {
      "name": "node3",
      "uuid": "0ecfd0a6-f1b3-11e8-9d9f-005056bbaadc",
      "_links": {
        "self": {
          "href": "/api/cluster/nodes/0ecfd0a6-f1b3-11e8-9d9f-005056bbaadc"
        }
      }
    },
    "issue": {
      "message": "AutoSupport OnDemand is disabled when \"-transport\" is not set to \"https\".",
      "code": "53149740"
    },
    "corrective_action": {
      "message": "Run \"system node autosupport modify -transport https -node <node name>\" to set \"-transport\" to \"https\".",
      "code": "53149740"
    }
  }
],
"_links": {
  "self": {
    "href": "/api/support/autosupport"
  }
}
}

Retrieving AutoSupport configuration and connectivity issues

The following example retrieves AutoSupport configuration and connectivity issues on the cluster. Use fields=*,issues parameter to return both configuration and connectivity issues.

# The API:
GET /support/autosupport

# The call:
curl -X GET "https://<mgmt-ip>/api/support/autosupport?fields=*%2Cissues" -H "accept: application/hal+json"

# The response:
200 OK
{
"enabled": true,
"mail_hosts": [
  "mailhost"
],
"from": "Postmaster",
"to": [
  "abc@netapp.com",
  "xyz@netapp.com"
],
"contact_support": true,
"transport": "smtp",
"proxy_url": "",
"is_minimal": false,
"issues": [
  {
    "node": {
      "name": "node3",
      "uuid": "0ecfd0a6-f1b3-11e8-9d9f-005056bbaadc",
      "_links": {
        "self": {
          "href": "/api/cluster/nodes/0ecfd0a6-f1b3-11e8-9d9f-005056bbaadc"
        }
      }
    },
    "issue": {
      "message": "SMTP connectivity check failed for destination: mailhost. Error: Could not resolve host - 'mailhost'",
      "code": "53149746"
    },
    "corrective_action": {
      "message": "Check the hostname of the SMTP server",
      "code": "53149746"
    }
  },
  {
    "node": {
      "name": "node3",
      "uuid": "0ecfd0a6-f1b3-11e8-9d9f-005056bbaadc",
      "_links": {
        "self": {
          "href": "/api/cluster/nodes/0ecfd0a6-f1b3-11e8-9d9f-005056bbaadc"
        }
      }
    },
    "issue": {
      "message": "AutoSupport OnDemand is disabled when \"-transport\" is not set to \"https\".",
      "code": "53149740"
    },
    "corrective_action": {
      "message": "Run \"system node autosupport modify -transport https -node <node name>\" to set \"-transport\" to \"https\".",
      "code": "53149740"
    }
  }
],
"_links": {
  "self": {
    "href": "/api/support/autosupport"
  }
}
}