{"id":23802,"date":"2021-01-22T13:30:10","date_gmt":"2021-01-22T12:30:10","guid":{"rendered":"https:\/\/www.sms77.io\/docs\/drittanbieter\/nagios\/"},"modified":"2021-12-10T11:00:51","modified_gmt":"2021-12-10T10:00:51","slug":"nagios","status":"publish","type":"docs","link":"https:\/\/www.seven.io\/de\/docs\/drittanbieter\/nagios\/","title":{"rendered":"Nagios"},"content":{"rendered":"<p><script async defer src=\"https:\/\/buttons.github.io\/buttons.js\"><\/script><br \/>\n<span id='github_buttons' style='display: flex'><br \/>\n<a class=\"github-button\" href=\"https:\/\/github.com\/sms77io\/nagios\" data-icon=\"octicon-star\" aria-label=\"sms77io\/nagios auf GitHub favorisieren\" rel=\"noopener\"><\/a><br \/>\n<a class=\"github-button\" href=\"https:\/\/github.com\/sms77io\/nagios\/fork\" data-icon=\"octicon-repo-forked\" aria-label=\"sms77io\/nagios auf GitHub abzweigen\" rel=\"noopener\"><\/a><br \/>\n<a class=\"github-button\" href=\"https:\/\/github.com\/sms77io\/nagios\/subscription\" data-icon=\"octicon-eye\" aria-label=\"sms77io\/nagios auf GitHub verfolgen\" rel=\"noopener\"><\/a><br \/>\n<\/span><br \/>\n<script>\nconst fragment = document.createDocumentFragment();\nfragment.appendChild(document.getElementById('github_buttons'));\nconst dest = document.querySelector(\"article > header.entry-header\");\ndest.style.display = 'flex';\ndest.style['justify-content'] = 'space-between';\ndest.style['margin-right'] = '20px';\ndest.style['margin-bottom'] = '-100px';\ndest.appendChild(fragment);\n<\/script><\/p>\n<h2>Was ist Nagios?<\/h2>\n<p><a href=\"https:\/\/staging.seven.io\/de\/loesungen\/integrationen\/nagios\/\" rel=\"noopener\">Nagios<\/a> ist ein Monitoringsystem f\u00fcr komplexe Netzwerke.<\/p>\n<h3>Funktionalit\u00e4t<\/h3>\n<h4>SMS-Versand<\/h4>\n<p>Lassen Sie Nagios Alarmierungen via SMS versenden, indem Sie sms77 einbinden.<\/p>\n<h3>Installation<\/h3>\n<ol>\n<li>Stellen Sie sicher Python 2+ auf dem System installiert ist.<\/li>\n<li>Kopieren Sie\u00a0<a href=\"https:\/\/github.com\/sms77io\/nagios\/blob\/master\/sms77.py\" rel=\"noopener\">sms77.py<\/a>\u00a0in das Nagios Plugin-Verzeichnis, meist in: \/usr\/local\/nagios\/libexec.<\/li>\n<\/ol>\n<h3><a id=\"user-content-usage\" class=\"anchor\" href=\"https:\/\/github.com\/sms77io\/nagios#usage\" aria-hidden=\"true\" rel=\"noopener\"><\/a>Nutzung<\/h3>\n<p>Passen Sie \/usr\/local\/nagios\/etc\/objects\/contacts.cfg an:<\/p>\n<pre><code>define contact {\r\n    #...\r\n    pager                         +491234567890\r\n    host_notification_commands    notify-host-by-sms\r\n    service_notification_commands notify-service-by-sms\r\n}\r\n<\/code><\/pre>\n<p>Anh\u00e4ngen an \/usr\/local\/nagios\/etc\/objects\/commands.cfg:<\/p>\n<pre><code># Results in a SMS like:\r\n# RECOVERY: SMS on 127.0.0.1@localhost, State: OK, Output: 100, Date: 01-15-2021 12:30:28\r\ndefine command {\r\n command_name notify-service-by-sms\r\n command_line $USER1$\/sms77.py MY_SMS77_API_KEY $CONTACTPAGER$ \"$NOTIFICATIONTYPE$:$SERVICEDESC$ on $HOSTADDRESS$@$HOSTNAME$, State $SERVICESTATE$, Output: $SERVICEOUTPUT$, Date: $SHORTDATETIME$\" --from=Nagios\r\n}\r\n\r\n# Results in a SMS like:\r\n# CUSTOM on 127.0.0.1@localhost, State: OK, Output: 100, Date: 01-15-2021 12:30:28\r\ndefine command {\r\n command_name notify-host-by-sms\r\n command_line $USER1$\/sms77.py MY_SMS77_API_KEY $CONTACTPAGER$ \"$NOTIFICATIONTYPE$ on $HOSTADDRESS$@$HOSTNAME$, State: $HOSTSTATE$, Output: $HOSTOUTPUT$, Date: $SHORTDATETIME$\" --from=Nagios\r\n}\r\n<\/code><\/pre>\n<p>Optional einen kurzen Test \u00fcber einen lokalen Dienst durchf\u00fchren.\u00a0Anh\u00e4ngen in \/usr\/local\/nagios\/etc\/objects\/localhost.cfg:<\/p>\n<pre><code>define service {\r\n use                   local-service\r\n host_name             localhost\r\n service_description   SMS\r\n check_command         notify-host-by-sms\r\n}\r\n<\/code><\/pre>\n<p>Nutzen Sie folgende Optionen:<\/p>\n<pre><code>sms77.py \r\n[-h] \r\n[--debug]\r\n[--delay DELAY]\r\n[--details]\r\n[--flash]\r\n[--foreign_id FOREIGN_ID] \r\n[--from FROM] \r\n[--json] \r\n[--label LABEL] \r\n[--no_reload] \r\n[--performance_tracking] \r\n[--return_msg_id] \r\n[--ttl TTL] \r\n[--udh UDH] \r\n[--unicode]\r\n[--utf8]\r\napi_key to text<\/code><\/pre>\n<h4 id=\"via-composer\"><span style=\"font-size: 28px; letter-spacing: 0em;\">Support<\/span><\/h4>\n<p>Bitte <a href=\"mailto:support@sms77.io\">schicken Sie uns eine Mail<\/a>, wenn Sie Fragen zum SMS-Versand in Nagios haben.<\/p>\n","protected":false},"featured_media":0,"parent":17825,"menu_order":37,"comment_status":"open","ping_status":"closed","template":"","doc_tag":[],"class_list":["post-23802","docs","type-docs","status-publish","hentry"],"comment_count":0,"_links":{"self":[{"href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/docs\/23802","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/types\/docs"}],"replies":[{"embeddable":true,"href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/comments?post=23802"}],"version-history":[{"count":10,"href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/docs\/23802\/revisions"}],"predecessor-version":[{"id":28789,"href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/docs\/23802\/revisions\/28789"}],"up":[{"embeddable":true,"href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/docs\/17825"}],"next":[{"title":"Nextcloud","link":"https:\/\/www.seven.io\/de\/docs\/drittanbieter\/nextcloud\/","href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/docs\/20698"}],"prev":[{"title":"n8n","link":"https:\/\/www.seven.io\/de\/docs\/drittanbieter\/n8n\/","href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/docs\/20672"}],"wp:attachment":[{"href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/media?parent=23802"}],"wp:term":[{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/www.seven.io\/de\/wp-json\/wp\/v2\/doc_tag?post=23802"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}