{
  "checks": [
    {
      "name": "Nginx connections active",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "ssh_script",
      "parameters": {
        "script_id": "0c67571c-a9cf-5702-89b6-6d3ee4c66ef3",
        "value_unit": "conns",
        "extract_value": "^(\\d+)"
      },
      "sort_order": 0,
      "value_type": "gauge",
      "description": "",
      "check_config": {
        "script_id": "0c67571c-a9cf-5702-89b6-6d3ee4c66ef3",
        "value_unit": "conns",
        "extract_value": "^(\\d+)"
      },
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": 5000,
      "threshold_warn": 2000,
      "interval_seconds": 60,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    },
    {
      "name": "Ping",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "ping",
      "parameters": {},
      "sort_order": 0,
      "value_type": "duration",
      "description": "",
      "check_config": {},
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": null,
      "threshold_warn": null,
      "interval_seconds": 60,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    },
    {
      "name": "HTTP Port",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "port",
      "parameters": {
        "port": 80
      },
      "sort_order": 1,
      "value_type": "status",
      "description": "",
      "check_config": {
        "port": 80
      },
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": null,
      "threshold_warn": null,
      "interval_seconds": 60,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    },
    {
      "name": "Nginx requests/sec",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "ssh_script",
      "parameters": {
        "script_id": "58b0cfb9-ae6a-5e66-af20-173c871b052a",
        "value_unit": "req/s",
        "extract_value": "^(\\d+)"
      },
      "sort_order": 1,
      "value_type": "info",
      "description": "",
      "check_config": {
        "script_id": "58b0cfb9-ae6a-5e66-af20-173c871b052a",
        "value_unit": "req/s",
        "extract_value": "^(\\d+)"
      },
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": null,
      "threshold_warn": null,
      "interval_seconds": 60,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    },
    {
      "name": "Nginx 5xx errors (last 5min)",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "ssh_script",
      "parameters": {
        "script_id": "521c3ccd-6214-5c96-8367-8a5c850d0c8f",
        "value_unit": "errors",
        "extract_value": "^(\\d+)"
      },
      "sort_order": 2,
      "value_type": "gauge",
      "description": "",
      "check_config": {
        "script_id": "521c3ccd-6214-5c96-8367-8a5c850d0c8f",
        "value_unit": "errors",
        "extract_value": "^(\\d+)"
      },
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": 50,
      "threshold_warn": 10,
      "interval_seconds": 300,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    },
    {
      "name": "HTTPS Port",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "port",
      "parameters": {
        "port": 443
      },
      "sort_order": 2,
      "value_type": "status",
      "description": "",
      "check_config": {
        "port": 443
      },
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": null,
      "threshold_warn": null,
      "interval_seconds": 60,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    },
    {
      "name": "Nginx waiting connections (slow)",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "ssh_script",
      "parameters": {
        "script_id": "d69ae34d-45bf-55a0-b732-3a22fe334791",
        "value_unit": "conns",
        "extract_value": "^(\\d+)"
      },
      "sort_order": 3,
      "value_type": "gauge",
      "description": "",
      "check_config": {
        "script_id": "d69ae34d-45bf-55a0-b732-3a22fe334791",
        "value_unit": "conns",
        "extract_value": "^(\\d+)"
      },
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": 3000,
      "threshold_warn": 1000,
      "interval_seconds": 60,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    },
    {
      "name": "HTTP Check",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "http",
      "parameters": {
        "url": "http://{host}"
      },
      "sort_order": 3,
      "value_type": "duration",
      "description": "",
      "check_config": {
        "url": "http://{host}"
      },
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": 10000,
      "threshold_warn": 3000,
      "interval_seconds": 60,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    },
    {
      "name": "Nginx service running",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "ssh_script",
      "parameters": {
        "script_id": "390682f2-ff7f-52d4-a291-b5a5a6941289",
        "value_unit": "up",
        "match_regex": "^0$",
        "extract_value": "^(\\d+)",
        "fail_if_match": true
      },
      "sort_order": 4,
      "value_type": "gauge",
      "description": "",
      "check_config": {
        "script_id": "390682f2-ff7f-52d4-a291-b5a5a6941289",
        "value_unit": "up",
        "match_regex": "^0$",
        "extract_value": "^(\\d+)",
        "fail_if_match": true
      },
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": null,
      "threshold_warn": null,
      "interval_seconds": 60,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    },
    {
      "name": "Nginx Service",
      "auto_add": true,
      "check_mode": "passive",
      "check_type": "ssh_script",
      "parameters": {
        "script_id": "4e189fa1-8852-59fa-84ea-f95f92cff1fb",
        "match_regex": "^active$"
      },
      "sort_order": 4,
      "value_type": "gauge",
      "description": "",
      "check_config": {
        "script_id": "4e189fa1-8852-59fa-84ea-f95f92cff1fb",
        "match_regex": "^active$"
      },
      "is_telemetry": false,
      "interpretation": null,
      "threshold_crit": null,
      "threshold_warn": null,
      "interval_seconds": 120,
      "threshold_direction": "upper",
      "confirmation_attempts": 1,
      "confirmation_interval_seconds": 10
    }
  ],
  "profile": {
    "icon": "server",
    "name": "Nginx Web Server",
    "tags": [
      "nginx",
      "web",
      "linux",
      "ssh"
    ],
    "vendor": "generic",
    "category": "server",
    "os_family": "linux",
    "description": "Linux + Nginx: Ports, HTTP Check, Service.",
    "ip_required": true,
    "port_layout": null,
    "visual_type": null,
    "snmp_enabled": false,
    "agent_capable": false,
    "requires_snmp": true,
    "description_md": "Linux + Nginx: Ports, HTTP Check, Service.",
    "requires_agent": false,
    "sysoid_patterns": null,
    "sysdescr_patterns": null,
    "requires_collector": true
  },
  "scripts": [
    {
      "name": "Nginx connections active",
      "script_id": "0c67571c-a9cf-5702-89b6-6d3ee4c66ef3",
      "is_builtin": true,
      "description": "Auto-registered builtin SSH script.",
      "interpreter": "bash",
      "script_body": "curl -sf http://localhost/nginx_status 2>/dev/null | awk '/^Active/{print $3; exit}' || echo 0",
      "expected_output": "nagios"
    },
    {
      "name": "Nginx requests/sec",
      "script_id": "58b0cfb9-ae6a-5e66-af20-173c871b052a",
      "is_builtin": true,
      "description": "Auto-registered builtin SSH script.",
      "interpreter": "bash",
      "script_body": "curl -sf http://localhost/nginx_status 2>/dev/null | awk 'NR==3{print int($3/60); exit}' || echo 0",
      "expected_output": "nagios"
    },
    {
      "name": "Nginx 5xx errors (last 5min)",
      "script_id": "521c3ccd-6214-5c96-8367-8a5c850d0c8f",
      "is_builtin": true,
      "description": "Auto-registered builtin SSH script.",
      "interpreter": "bash",
      "script_body": "awk -v t=\\\"$(date -d '5min ago' '+%d/%b/%Y:%H:%M')\\\" '$4 >= \\\"[\\\"t && $9 ~ /^5/{c++} END{print c+0}' /var/log/nginx/access.log 2>/dev/null || echo 0",
      "expected_output": "nagios"
    },
    {
      "name": "Nginx waiting connections (slow)",
      "script_id": "d69ae34d-45bf-55a0-b732-3a22fe334791",
      "is_builtin": true,
      "description": "Auto-registered builtin SSH script.",
      "interpreter": "bash",
      "script_body": "curl -sf http://localhost/nginx_status 2>/dev/null | awk '/Reading|Writing|Waiting/{for(i=1;i<=NF;i++) if($i==\\\"Waiting:\\\") print $(i+1); exit}' || echo 0",
      "expected_output": "nagios"
    },
    {
      "name": "Nginx service running",
      "script_id": "390682f2-ff7f-52d4-a291-b5a5a6941289",
      "is_builtin": true,
      "description": "Auto-registered builtin SSH script.",
      "interpreter": "bash",
      "script_body": "systemctl is-active nginx 2>/dev/null | grep -c '^active$' || echo 0",
      "expected_output": "nagios"
    },
    {
      "name": "Nginx Service",
      "script_id": "4e189fa1-8852-59fa-84ea-f95f92cff1fb",
      "is_builtin": true,
      "description": "Auto-registered from builtin profile-check 'Nginx Service'.",
      "interpreter": "bash",
      "script_body": "systemctl is-active nginx",
      "expected_output": "nagios"
    }
  ],
  "schema_version": 1
}