Health Monitors

This section contains different types of health monitors you can use in your declarations. Some include multiple monitors, so you can include the monitor(s) that best suit your needs.

Use the index under Current Page on the left to locate specific examples.

1: Using an LDAP monitor in a declaration

This example shows how you use an LDAP monitor in a declaration. This example shows 4 different LDAP monitors that you can use in your declarations. See the Schema Reference for usage options and additional features.

  • Partition (tenant) named Sample_monitor_01.
  • A pool named monitorLDAP_pool with one member.
  • Four LDAP monitors, named monitorLDAPdefault, monitorLDAPsimple, monitorLDAPnonDefault1, and monitorLDAPnonDefault2.
{
    "class": "ADC",
    "schemaVersion": "3.6.0",
    "id": "TEST_MONITOR_LDAP",
    "remark": "Test LDAP Monitor",
    "Sample_monitor_01": {
      "class": "Tenant",
      "TEST_Monitor_LDAP": {
        "class": "Application",
        "template": "generic",
        "monitorLDAP_simple": {
          "class": "Monitor",
          "monitorType": "ldap"
        },
        "monitorLDAP_default": {
          "class": "Monitor",
          "monitorType": "ldap",
          "targetAddress": "",
          "targetPort": 0,
          "interval": 5,
          "upInterval": 0,
          "timeUntilUp": 0,
          "timeout": 16,
          "security": "none",
          "mandatoryAttributes": false,
          "chaseReferrals": true
        },
        "monitorLDAP_nonDefault1": {
          "class": "Monitor",
          "monitorType": "ldap",
          "targetAddress": "192.0.2.17",
          "targetPort": 389,
          "interval": 10,
          "upInterval": 15,
          "timeUntilUp": 20,
          "timeout": 46,
          "security": "ssl",
          "mandatoryAttributes": true,
          "chaseReferrals": false,
          "username": "Adm-nM+nkey",
          "passphrase": {
            "ciphertext": "ZjVmNQ==",
            "protected": "eyJhbGciOiJkaXIiLCJlbmMiOiJub25lIn0",
            "ignoreChanges": true
          },
          "base": "dc=bigip-test,dc=org",
          "filter": "objectClass=employee"
        },
        "monitorLDAP_nonDefault2": {
          "class": "Monitor",
          "monitorType": "ldap",
          "targetAddress": "192.0.2.18",
          "targetPort": 389,
          "username": "B*zzL!ghtyear",
          "passphrase": {
            "ciphertext": "ZjVmNQ==",
            "protected": "eyJhbGciOiJkaXIiLCJlbmMiOiJub25lIn0",
            "ignoreChanges": true
          },
          "base": "dc=bigip-test,dc=net",
          "filter": "objectClass=person",
          "security": "tls"
        },
        "monitorLDAP_pool": {
          "class": "Pool",
          "members": [
            {
              "servicePort": 443,
              "serverAddresses": [
                "192.0.2.19"
              ],
              "minimumMonitors": 1,
              "monitors": [
                { "use": "monitorLDAP_nonDefault1" },
                { "use": "monitorLDAP_nonDefault2" }
              ]
            }
          ]
        }
      }
    }
  }
  

Back to top

2: Using a DNS monitor in a declaration

This example shows how you use a DNS monitor in a declaration. This example shows two monitors, a simple DNS monitor and a DNS monitor with all available properties that you can use in your declarations. See the Schema Reference for usage options and information.

  • Partition (tenant) named Sample_monitor_02.
  • A pool named monitorDNS_pool with one member.
  • Two monitors attached to the pool: monitorDNS_simple and monitorDNS_AllProperties.
{
    "class": "ADC",
    "schemaVersion": "3.6.0",
    "id": "TEST_MONITOR_DNS",
    "remark": "Test DNS Monitor",
    "Sample_monitor_02": {
      "class": "Tenant",
      "TEST_Monitor_DNS": {
        "class": "Application",
        "template": "generic",
        "monitorDNS_simple": {
          "class": "Monitor",
          "monitorType": "dns",
          "queryName": "apple.test"
        },
        "monitorDNS_AllProperties": {
          "class": "Monitor",
          "monitorType": "dns",
          "queryName": "radish.test",
          "acceptRCODE": "no-error",
          "adaptive": true,
          "adaptiveDivergenceType": "absolute",
          "adaptiveDivergenceMilliseconds": 200,
          "adaptiveLimitMilliseconds": 5000,
          "adaptiveWindow": 1500,
          "answerContains": "query-type",
          "queryType": "aaaa",
          "receive": "fdf5:4153:3300::a",
          "reverse": false,
          "interval": 60,
          "timeUntilUp": 1200,
          "timeout": 600,
          "upInterval": 2400,
          "transparent": false,
          "targetAddress": "fdf5:4153:3300::b",
          "targetPort": 53
        },
        "monitorDNS_pool": {
          "class": "Pool",
          "members": [
            {
              "servicePort": 443,
              "serverAddresses": [
                "fdf5:4153:3300::c"
            ],
              "minimumMonitors": 1,
              "monitors": [
                { "use": "monitorDNS_AllProperties" },
                { "use": "monitorDNS_simple" }
              ]
            }
          ]
        }
      }
    }
  }
  

Back to top

3: Using an external monitor in a declaration

This example shows how you can create an external monitor in a declaration. An external monitor allows you to use a custom script for monitoring. In this example, we reference a script located in an external location. You could also reference a script file already present on the BIG-IP.

This declaration creates the following objects on the BIG-IP:

  • Partition (tenant) named Sample_monitor_03.
  • A pool named externalMonitorPool.
  • An external monitor named mNewExternalMonitorFile, that uses a script hosted in an external location.
{
  "class": "ADC",
  "schemaVersion": "3.6.0",
  "id": "MONITOR_EXTERNAL",
  "remark": "external monitor",
  "Sample_monitor_03": {
    "class": "Tenant",
    "Monitors": {
      "class": "Application",
      "label": "simple external monitor",
      "template": "generic",
      "mNewExternalMonitorFile": {
        "class": "Monitor",
        "monitorType": "external",
        "interval": 5,
        "upInterval": 0,
        "timeUntilUp": 0,
        "timeout": 16,
        "expand": false,
        "script": {
          "url": "https://example.com/monitor.sh"
        }
      },
      "monitorExternal_pool": {
        "class": "Pool",
        "members": [
          {
            "servicePort": 443,
            "serverAddresses": [
              "192.0.2.19"
            ],
            "minimumMonitors": 1,
            "monitors": [
              { "use": "mNewExternalMonitorFile" }
            ]
          }
        ]
      }
    }
  }
}

Back to top

4: Using a RADIUS monitor in a declaration

This example shows how you use a RADIUS monitor in a declaration. This example shows 3 different RADIUS monitors that you can use in your declarations. See Monitor_FTP in the Schema Reference for usage options and additional features.

  • Partition (tenant) named Sample_monitor_04.
  • A pool named monitorRADIUS_pool with one member.
  • Three example RADIUS monitors, named monitorRADIUSdefault, monitorRADIUS_nondefault1, monitorRADIUS_nondefault2.
{
    "class": "ADC",
    "schemaVersion": "3.7.0",
    "id": "TEST_MONITOR_RADIUS",
    "remark": "Test RADIUS Monitor",
    "Sample_monitor_04": {
      "class": "Tenant",
      "TEST_Monitor_RADIUS": {
        "class": "Application",
        "template": "generic",
        "monitorRADIUS_simple": {
          "class": "Monitor",
          "monitorType": "radius"
        },
        "monitorRADIUS_default": {
          "class": "Monitor",
          "monitorType": "radius",
          "targetAddress": "",
          "targetPort": 0,
          "interval": 5,
          "upInterval": 0,
          "timeUntilUp": 0,
          "timeout": 16
        },
        "monitorRADIUS_nonDefault1": {
          "class": "Monitor",
          "monitorType": "radius",
          "targetAddress": "192.0.2.17",
          "targetPort": 1812,
          "interval": 10,
          "upInterval": 15,
          "timeUntilUp": 20,
          "timeout": 46,
          "username": "Adm-nM+nkey",
          "passphrase": {
            "ciphertext": "ZjVmNQ==",
            "protected": "eyJhbGciOiJkaXIiLCJlbmMiOiJub25lIn0",
            "ignoreChanges": true
          },
          "secret": {
            "ciphertext": "ZjVmNQ==",
            "protected": "eyJhbGciOiJkaXIiLCJlbmMiOiJub25lIn0",
            "ignoreChanges": true
          },
          "nasIpAddress": "198.0.2.20"
        },
        "monitorRADIUS_nonDefault2": {
          "class": "Monitor",
          "monitorType": "radius",
          "targetAddress": "192.0.2.18",
          "targetPort": 1645,
          "username": "B*zzL!ghtyear",
          "passphrase": {
            "ciphertext": "ZjVmNQ==",
            "protected": "eyJhbGciOiJkaXIiLCJlbmMiOiJub25lIn0",
            "ignoreChanges": true
          },
          "secret": {
            "ciphertext": "ZjVmNQ==",
            "protected": "eyJhbGciOiJkaXIiLCJlbmMiOiJub25lIn0",
            "ignoreChanges": true
          },
          "nasIpAddress": "192.0.2.20"
        },
        "monitorRADIUS_pool": {
          "class": "Pool",
          "members": [
            {
              "servicePort": 443,
              "serverAddresses": [
                "192.0.2.19"
              ],
              "minimumMonitors": 1,
              "monitors": [
                { "use": "monitorRADIUS_nonDefault1" },
                { "use": "monitorRADIUS_nonDefault2" }
              ]
            }
          ]
        }
      }
    }
  }
  

Back to top

4: Using an FTP monitor in a declaration

This example shows how you use an FTP monitor in a declaration. This declaration only includes the monitor, and no pool or virtual service, but simply shows how to create an FTP monitor with AS3. See the Schema Reference for usage options and additional features.

  • Partition (tenant) named TEST_FTPMonitor.
  • An FTP monitor named sampleFTPmonitor.
{
    "class": "ADC",
    "schemaVersion": "3.10.0",
    "id": "Monitor",
    "TEST_FTPMonitor": {
        "class": "Tenant",
        "Application": {
            "class": "Application",
            "template": "generic",
            "sampleFTPmonitor": {
                "class": "Monitor",
                "monitorType": "ftp",
                "mode": "port",
                "username": "testUser",
                "passphrase": {
                    "ciphertext": "ZjVmNQ==",
                    "protected": "eyJhbGciOiJkaXIiLCJlbmMiOiJub25lIn0",
                    "ignoreChanges": true
                },
                "filename": "testpath/test/"
            }
        }
    }
}

Back to top