5.6. Check types

Each check within Rackspace Cloud Monitoring has a designated check type. The check type instructs the monitoring system how to check the monitored resource.

Check types for commonly encountered web protocols, such as HTTP (remote.http), IMAP (remote.imap-banner) , SMTP (remote.stmp), and DNS (remote.dns) are provided. Monitoring commonly encountered infrastructure servers like MySQL (remote.mysql-banner) and PostgreSQL (remote.postgresql-banner) are also available. Monitoring custom server uptime can be accomplished with the remote.tcp banner check to check for a protocol-defined banner at the beginning of a connection. Gathering metrics from server software to create alerts against can be accomplished using the remote.http check type and the 'extract' attribute to define the format.

In addition to the standard Cloud Monitoring check types, you can also use agent check types if the Monitoring Agent is installed on the server you are monitoring.

For a list of available check types, see Appendix B, Available check types and fields.

Checks generate metrics that alarms will alert based upon. The metrics generated often depend on the parameters for the check, using the extract attribute on the remote.http check for example. However, the default metrics are always present. Use the Test check operation to determine the exact metrics available.

The following table summarizes the attributes for Check Type resources.

Table 5.3. Attributes
NameDescriptionValidation
category The category the check is in.
  • String

type The name of the supported check type.
  • String

fields Check type fields.
  • Optional

  • Array [Optional]

supported_platforms Platforms on which an agent check type is supported. This is advisory information only - the check may still work on other platforms, or report that check execution failed at runtime
  • Optional

  • Array [String]

Use the check types API operations to view check type resources

[Note]Note

Users cannot create, update, or delete check types.

MethodURIDescription
GET/check_types

Lists all available check types.

GET/check_types/{checkTypeId}

Retrieve information for a single check type.

 5.6.1. List check types

 
MethodURIDescription
GET/check_types

Lists all available check types.

This operation can be paginated. For information, see Paginated collections

This table shows the possible response codes for this operation:

Response CodeNameDescription
200OK

The request completed.

401Unauthorized

The system received a request from a user that is not authenticated.

403Forbidden

The system received a request that the user is not authorized to make.

500Internal Server Error

An unexpected condition was encountered.

503Service Unavailable

The system is experiencing heavy load or another system failure.

 5.6.1.1. Request

This table shows the header parameters for the list check types request:

NameTypeDescription

X-Auth-Token

​String

(Required)

A valid authentication token with administrative access.

This operation does not accept a request body.

 5.6.1.2. Response

 

Example 5.35. List check types: XML response

<?xml version="1.0" encoding="utf-8"?>
<container>
  <values>
    <check_type id="remote.dns">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 53)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>query</name>
          <description>DNS Query</description>
          <optional>false</optional>
        </field>
        <field>
          <name>record_type</name>
          <description>DNS Record Type</description>
          <optional>false</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.ssh">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 22)</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.smtp">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 25)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>ehlo</name>
          <description>EHLO parameter</description>
          <optional>true</optional>
        </field>
        <field>
          <name>from</name>
          <description>From parameter</description>
          <optional>true</optional>
        </field>
        <field>
          <name>to</name>
          <description>To parameter (if blank, a "quit" is issued before sending a to line, and the connection is terminated)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>payload</name>
          <description>Specifies the payload</description>
          <optional>true</optional>
        </field>
        <field>
          <name>starttls</name>
          <description>Should the connection be upgraded to TLS/SSL</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.http">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>url</name>
          <description>Target URL</description>
          <optional>false</optional>
        </field>
        <field>
          <name>body</name>
          <description>Body match regular expression (body is limited to 100k)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>headers</name>
          <description>Arbitrary headers which are sent with the request.</description>
          <optional>true</optional>
        </field>
        <field>
          <name>body_matches</name>
          <description>Body match regular expressions (body is limited to 100k, matches are truncated to 80 characters)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>method</name>
          <description>HTTP method (default: GET)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>auth_user</name>
          <description>Optional auth user</description>
          <optional>true</optional>
        </field>
        <field>
          <name>auth_password</name>
          <description>Optional auth password</description>
          <optional>true</optional>
        </field>
        <field>
          <name>follow_redirects</name>
          <description>Follow redirects (default: true)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>payload</name>
          <description>Specify a request body (limited to 1024 characters). If following a redirect, payload will only be sent to first location</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.tcp">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number</description>
          <optional>false</optional>
        </field>
        <field>
          <name>banner_match</name>
          <description>Banner match regex.</description>
          <optional>true</optional>
        </field>
        <field>
          <name>send_body</name>
          <description>Send a body. If a banner is provided the body is sent after the banner is verified.</description>
          <optional>true</optional>
        </field>
        <field>
          <name>body_match</name>
          <description>Body match regex. Key/Values are captured when matches are specified within the regex. Note: Maximum body size 1024 bytes.</description>
          <optional>true</optional>
        </field>
        <field>
          <name>ssl</name>
          <description>Enable SSL</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.ping">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>count</name>
          <description>Number of pings to send within a single check</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.ftp-banner">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 21)</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.imap-banner">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 143)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>ssl</name>
          <description>Enable SSL</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.pop3-banner">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 110)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>ssl</name>
          <description>Enable SSL</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.smtp-banner">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 25)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>ssl</name>
          <description>Enable SSL</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.postgresql-banner">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 5432)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>ssl</name>
          <description>Enable SSL</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.telnet-banner">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 23)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>banner_match</name>
          <description>Banner to check</description>
          <optional>true</optional>
        </field>
        <field>
          <name>ssl</name>
          <description>Enable SSL</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.mysql-banner">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 3306)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>ssl</name>
          <description>Enable SSL</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
    <check_type id="remote.mssql-banner">
      <category>remote</category>
      <type>remote</type>
      <fields>
        <field>
          <name>port</name>
          <description>Port number (default: 1433)</description>
          <optional>true</optional>
        </field>
        <field>
          <name>ssl</name>
          <description>Enable SSL</description>
          <optional>true</optional>
        </field>
      </fields>
    </check_type>
  </values>
  <metadata>
    <count>14</count>
    <limit>50</limit>
    <marker/>
    <next_marker/>
    <next_href/>
  </metadata>
</container>

 

Example 5.36. List check types: JSON response

{
    "values": [
        {
            "id": "remote.dns",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 53)",
                    "optional": true
                },
                {
                    "name": "query",
                    "description": "DNS Query",
                    "optional": false
                },
                {
                    "name": "record_type",
                    "description": "DNS Record Type",
                    "optional": false
                }
            ]
        },
        {
            "id": "remote.ssh",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 22)",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.smtp",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 25)",
                    "optional": true
                },
                {
                    "name": "ehlo",
                    "description": "EHLO parameter",
                    "optional": true
                },
                {
                    "name": "from",
                    "description": "From parameter",
                    "optional": true
                },
                {
                    "name": "to",
                    "description": "To parameter (if blank, a \"quit\" is issued before sending a to line, and the connection is terminated)",
                    "optional": true
                },
                {
                    "name": "payload",
                    "description": "Specifies the payload",
                    "optional": true
                },
                {
                    "name": "starttls",
                    "description": "Should the connection be upgraded to TLS/SSL",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.http",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "url",
                    "description": "Target URL",
                    "optional": false
                },
                {
                    "name": "body",
                    "description": "Body match regular expression (body is limited to 100k)",
                    "optional": true
                },
                {
                    "name": "headers",
                    "description": "Arbitrary headers which are sent with the request.",
                    "optional": true
                },
                {
                    "name": "body_matches",
                    "description": "Body match regular expressions (body is limited to 100k, matches are truncated to 80 characters)",
                    "optional": true
                },
                {
                    "name": "method",
                    "description": "HTTP method (default: GET)",
                    "optional": true
                },
                {
                    "name": "auth_user",
                    "description": "Optional auth user",
                    "optional": true
                },
                {
                    "name": "auth_password",
                    "description": "Optional auth password",
                    "optional": true
                },
                {
                    "name": "follow_redirects",
                    "description": "Follow redirects (default: true)",
                    "optional": true
                },
                {
                    "name": "payload",
                    "description": "Specify a request body (limited to 1024 characters). If following a redirect, payload will only be sent to first location",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.tcp",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number",
                    "optional": false
                },
                {
                    "name": "banner_match",
                    "description": "Banner match regex.",
                    "optional": true
                },
                {
                    "name": "send_body",
                    "description": "Send a body. If a banner is provided the body is sent after the banner is verified.",
                    "optional": true
                },
                {
                    "name": "body_match",
                    "description": "Body match regex. Key/Values are captured when matches are specified within the regex. Note: Maximum body size 1024 bytes.",
                    "optional": true
                },
                {
                    "name": "ssl",
                    "description": "Enable SSL",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.ping",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "count",
                    "description": "Number of pings to send within a single check",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.ftp-banner",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 21)",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.imap-banner",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 143)",
                    "optional": true
                },
                {
                    "name": "ssl",
                    "description": "Enable SSL",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.pop3-banner",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 110)",
                    "optional": true
                },
                {
                    "name": "ssl",
                    "description": "Enable SSL",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.smtp-banner",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 25)",
                    "optional": true
                },
                {
                    "name": "ssl",
                    "description": "Enable SSL",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.postgresql-banner",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 5432)",
                    "optional": true
                },
                {
                    "name": "ssl",
                    "description": "Enable SSL",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.telnet-banner",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 23)",
                    "optional": true
                },
                {
                    "name": "banner_match",
                    "description": "Banner to check",
                    "optional": true
                },
                {
                    "name": "ssl",
                    "description": "Enable SSL",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.mysql-banner",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 3306)",
                    "optional": true
                },
                {
                    "name": "ssl",
                    "description": "Enable SSL",
                    "optional": true
                }
            ]
        },
        {
            "id": "remote.mssql-banner",
            "category": "remote",
            "type": "remote",
            "fields": [
                {
                    "name": "port",
                    "description": "Port number (default: 1433)",
                    "optional": true
                },
                {
                    "name": "ssl",
                    "description": "Enable SSL",
                    "optional": true
                }
            ]
        }
    ],
    "metadata": {
        "count": 14,
        "limit": 50,
        "marker": null,
        "next_marker": null,
        "next_href": null
    }
}

 5.6.2. Get check type by ID

 
MethodURIDescription
GET/check_types/{checkTypeId}

Retrieve information for a single check type.

This table shows the possible response codes for this operation:

Response CodeNameDescription
200OK

The request completed.

401Unauthorized

The system received a request from a user that is not authenticated.

403Forbidden

The system received a request that the user is not authorized to make.

500Internal Server Error

An unexpected condition was encountered.

503Service Unavailable

The system is experiencing heavy load or another system failure.

 5.6.2.1. Request

This table shows the header parameters for the get check type by id request:

NameTypeDescription

X-Auth-Token

​String

(Required)

A valid authentication token with administrative access.

This operation does not accept a request body.

 5.6.2.2. Response

 

Example 5.37. Get check type by ID: XML response

<?xml version="1.0" encoding="utf-8"?>
<check_type id="remote.dns">
  <category>remote</category>
  <type>remote</type>
  <fields>
    <field>
      <name>port</name>
      <description>Port number (default: 53)</description>
      <optional>true</optional>
    </field>
    <field>
      <name>query</name>
      <description>DNS Query</description>
      <optional>false</optional>
    </field>
    <field>
      <name>record_type</name>
      <description>DNS Record Type</description>
      <optional>false</optional>
    </field>
  </fields>
</check_type>

 

Example 5.38. Get check type by ID: JSON response

{
    "id": "remote.dns",
    "category": "remote",
    "type": "remote",
    "fields": [
        {
            "name": "port",
            "description": "Port number (default: 53)",
            "optional": true
        },
        {
            "name": "query",
            "description": "DNS Query",
            "optional": false
        },
        {
            "name": "record_type",
            "description": "DNS Record Type",
            "optional": false
        }
    ]
}



loading table of contents...