{"id":1367,"date":"2019-01-16T23:06:56","date_gmt":"2019-01-16T23:06:56","guid":{"rendered":"https:\/\/draculaservers.com\/tutorials\/?p=1367"},"modified":"2021-11-14T20:34:35","modified_gmt":"2021-11-14T20:34:35","slug":"install-nagios-ubuntu","status":"publish","type":"post","link":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/","title":{"rendered":"How to Install Nagios 4 on Ubuntu 18.04 for Server Monitoring"},"content":{"rendered":"<h2 id=\"prerequisites\">Prerequisites<\/h2>\n<p>To follow this tutorial we assume the following:<\/p>\n<ul>\n<li>You&#8217;re using a machine running Ubuntu or Debian. This tutorial is for Ubuntu 18.04, but it should work on Ubuntu 16.4, 14.04 and Debian systems.<\/li>\n<li>You&#8217;re acting as a <code>non-root sudo user<\/code>. If you don&#8217;t have one set up, you can follow our tutorial on creating a sudo user on Ubuntu 18.04<\/li>\n<\/ul>\n<div class=\"container custom-content-block\" style=\"background-color: #282a36; border-radius: 3px; padding: 20px 25px 35px 25px !important; margin-top: 60px; margin-bottom: 60px;\">\r\n<div class=\"row\">\r\n<div class=\"col-lg-12\">\r\n<p style=\"color: #74fa7a; font-weight: bold !important; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important;\">Get a High RAM VPS at Entry-level Pricing<\/p>\r\n\r\n<\/div>\r\n<div class=\"col-lg-12\">\r\n<p style=\"color: #ffffff; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important;\">Starting with 2GB RAM at $6.99\/month<\/p>\r\n\r\n<\/div>\r\n<div class=\"col-lg-12\">\r\n<p style=\"color: #60709f; font-size: 1em; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important;\">Take your pick from our KVM VPS that offer a generous amount of RAM at an affordable price. We've got 5 plans for you to choose from, our cheapest featuring 2GB RAM at $6.99\/mo.<\/p>\r\n\r\n<div style=\"font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important; font-size: 14px; color: #74fa7a;\"><span style=\"color: #ffffff;\">[Main Features]<\/span>\r\n- SSD Drives\r\n- KVM Virtualization\r\n- 1Gbps Shared Uplink\r\n- Location: Chicago, IL<\/div>\r\n<\/div>\r\n<div class=\"col-lg-12\">\r\n<p style=\"color: #ffffff; font-weight: bold !important; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important;\">Pick one of our KVM plans<\/p>\r\n\r\n<\/div>\r\n<div class=\"col-lg-12\"><a class=\"btn btn-primary btn-lg\" style=\"background-color: #58689e; color: #ffffff; box-shadow: 0 2px 2px 0 #3F51B5, 0 3px 1px -2px #3F51B5, 0 1px 5px 0 #3F51B5; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important; font-weight: bold !important;\" role=\"button\" href=\"https:\/\/draculaservers.com\/kvm.php#choose-plan\" target=\"_blank\" rel=\"noopener\" aria-pressed=\"true\">Get started now<\/a><\/div>\r\n<\/div>\r\n<\/div>\n\n<h2 id=\"step-1-install-php-apache\">Step 1 \u2013 Install PHP &amp; Apache<\/h2>\n<p>We&#8217;ll first update our package index and install PHP and Apache.<\/p>\n<pre><code>$ sudo apt-get update\n$ sudo apt-get install wget build-essential unzip openssl libssl-dev\n$ sudo apt-get install apache2 php libapache2-mod-php php-gd libgd-dev <\/code><\/pre>\n<h2 id=\"step-2-create-a-user-and-group-for-nagios\">Step 2 \u2013 Create a User and Group for Nagios<\/h2>\n<p>Next, create a new user for Nagios, and assign them a password:<\/p>\n<pre><code>$ sudo adduser nagios_user<\/code><\/pre>\n<p>Now we&#8217;ll create a group for Nagios, which we&#8217;ll call <code>nagcmd<\/code> and we&#8217;ll add the user we just created to this group.<\/p>\n<pre><code>$ sudo groupadd nagcmd\n$ sudo usermod -a -G nagcmd nagios_user<\/code><\/pre>\n<p>We&#8217;ll also add the user to the Apache group.<\/p>\n<pre><code>$ sudo usermod -a -G nagcmd www-data<\/code><\/pre>\n<h2 id=\"step-3-install-nagios-binaries\">Step 3 \u2013 Install Nagios Binaries<\/h2>\n<p>To install Nagios, we&#8217;ll first have to download the latest Nagios release. To do this, retrieve the <code>tar.gz<\/code> download link from the <a href=\"https:\/\/github.com\/NagiosEnterprises\/nagioscore\/releases\" target=\"_blank\" rel=\"noopener\">Github Releases<\/a> page. The latest one at the time of writing is <code>nagios-4.4.3.tar.gz<\/code>.<\/p>\n<p>We&#8217;ll first change our directory into <code>\/opt<\/code>, download the release, and extract the archive.<\/p>\n<pre><code>$ cd \/opt\n$ sudo wget https:\/\/github.com\/NagiosEnterprises\/nagioscore\/releases\/download\/nagios-4.4.3\/nagios-4.4.3.tar.gz\n$ tar xzf nagios-4.4.3.tar.gz<\/code><\/pre>\n<p>After extracting the archive, navigate into the source directory and install Nagios along with some additional requirements using the <code>make<\/code> command:<\/p>\n<pre><code>cd nagios-4.4.3\nsudo .\/configure --with-command-group=nagcmd\nsudo make all\nsudo make install\nsudo make install-init\nsudo make install-daemoninit\nsudo make install-config\nsudo make install-commandmode\nsudo make install-exfoliation<\/code><\/pre>\n<p>Now we&#8217;ll need to copy <strong>event handlers<\/strong> scripts to the <code>libexec<\/code> directory. These provide multiple event triggers for the Nagios Web Interface.<\/p>\n<pre><code>$ sudo cp -R contrib\/eventhandlers\/ \/usr\/local\/nagios\/libexec\/\n$ sudo chown -R nagios:nagios \/usr\/local\/nagios\/libexec\/eventhandlers<\/code><\/pre>\n<h2 id=\"step-4-set-up-apache-with-an-authentication-gateway\">Step 4 \u2013 Set Up Apache with an Authentication Gateway<\/h2>\n<p>We&#8217;ll now set up Apache Virtual Hosts for Nagios, and to secure our web interface, we&#8217;ll set up an authentication gateway to prevent unauthorized access.<\/p>\n<p>To do this, we&#8217;ll create an Apache configuration file for Nagios:<\/p>\n<pre><code>$ sudo nano \/etc\/apache2\/conf-available\/nagios.conf<\/code><\/pre>\n<p>And paste the following content into the file.<\/p>\n<pre><code>ScriptAlias \/nagios\/cgi-bin \"\/usr\/local\/nagios\/sbin\"\n\n&lt;directory \"=\"\" usr=\"\" local=\"\" nagios=\"\" sbin\"=\"\"&gt;\n   Options ExecCGI\n   AllowOverride None\n   Order allow,deny\n   Allow from all\n   AuthName \"Restricted Area\"\n   AuthType Basic\n   AuthUserFile \/usr\/local\/nagios\/etc\/htpasswd.users\n   Require valid-user\n\n\nAlias \/nagios \"\/usr\/local\/nagios\/share\"\n\n&lt;directory \"=\"\" usr=\"\" local=\"\" nagios=\"\" share\"=\"\"&gt;\n   Options None\n   AllowOverride None\n   Order allow,deny\n   Allow from all\n   AuthName \"Restricted Area\"\n   AuthType Basic\n   AuthUserFile \/usr\/local\/nagios\/etc\/htpasswd.users\n   Require valid-user\n<\/code><\/pre>\n<p>Save and close the file when you&#8217;re done.<\/p>\n<p>Now we can set up the authentication gateway. We&#8217;ll use the user <code>nagiosadmin<\/code>. This is the default user that we can use to authenticate, and to use a different one would require further configuration.<\/p>\n<pre><code>$ sudo htpasswd -c \/usr\/local\/nagios\/etc\/htpasswd.users nagiosadmin<\/code><\/pre>\n<p>Now enable the Apache configuration and restart it so the changes take effect:<\/p>\n<pre><code>$ sudo a2enconf nagios\n$ sudo a2enmod cgi rewrite\n$ sudo service apache2 restart<\/code><\/pre>\n<h2 id=\"step-5-install-nagios-plugins\">Step 5 \u2013 Install Nagios Plugins<\/h2>\n<p>Once Nagios is installed and configured, we can download and install the latest <code>nagios-plugins<\/code>. To do this, retrieve the latest <code>nagios-plugins<\/code> release link from <a href=\"http:\/\/nagios-plugins.org\/download\/\" target=\"_blank\" rel=\"noopener\">here<\/a>. The latest version at the time of writing is <code>nagios-plugins-2.2.1.tar.gz<\/code>. After which, change the directory into <code>\/opt<\/code>, download it, extract it, and navigate into it&#8217;s folder.<\/p>\n<pre><code>$ cd \/opt\n$ wget http:\/\/www.nagios-plugins.org\/download\/nagios-plugins-2.2.1.tar.gz\n$ tar xzf nagios-plugins-2.2.1.tar.gz\n$ cd nagios-plugins-2.2.1<\/code><\/pre>\n<p>Now we compile and install <code>nagios-plugins<\/code>:<\/p>\n<pre><code>$ sudo .\/configure --with-nagios-user=nagios --with-nagios-group=nagios --with-openssl\n$ sudo make\n$ sudo make install<\/code><\/pre>\n<h2 id=\"step-6-verify-start-nagios\">Step 6 \u2013 Verify &amp; Start Nagios<\/h2>\n<p>After installing and configuring Nagios, we can verify if Nagios has been successfully installed, start it, and configure it to start on system boot.<\/p>\n<p>Verify the installation:<\/p>\n<pre><code>$ \/usr\/local\/nagios\/bin\/nagios -v \/usr\/local\/nagios\/etc\/nagios.cfg<\/code><\/pre>\n<p><strong>Example Output<\/strong><\/p>\n<pre><code>Nagios Core 4.4.3\nCopyright (c) 2009-present Nagios Core Development Team and Community Contributors\nCopyright (c) 1999-2009 Ethan Galstad\nLast Modified: 2019-01-15\nLicense: GPL\n\nWebsite: https:\/\/www.nagios.org\nReading configuration data...\n   Read main config file okay...\n   Read object config files okay...\n\nRunning pre-flight check on configuration data...\n\nChecking objects...\n\tChecked 8 services.\n\tChecked 1 hosts.\n\tChecked 1 host groups.\n\tChecked 0 service groups.\n\tChecked 1 contacts.\n\tChecked 1 contact groups.\n\tChecked 24 commands.\n\tChecked 5 time periods.\n\tChecked 0 host escalations.\n\tChecked 0 service escalations.\nChecking for circular paths...\n\tChecked 1 hosts\n\tChecked 0 service dependencies\n\tChecked 0 host dependencies\n\tChecked 5 timeperiods\nChecking global event handlers...\nChecking obsessive compulsive processor commands...\nChecking misc settings...\n\nTotal Warnings: 0\nTotal Errors:   0\n\nThings look okay - No serious problems were detected during the pre-flight check<\/code><\/pre>\n<p>Start Nagios:<\/p>\n<pre><code>$ service nagios start<\/code><\/pre>\n<p>Configure to start on system boot:<\/p>\n<pre><code>$ sudo systemctl enable nagios<\/code><\/pre>\n<h2 id=\"step-7-access-the-nagios-web-interface\">Step 7 \u2013 Access the Nagios Web Interface<\/h2>\n<p>Now you can access the Nagios Web Interface by visiting your hostname or IP address in your browser followed by <code>\/nagios<\/code>:<\/p>\n<pre><code>https:\/\/your_server_IP_or_domain\/nagios<\/code><\/pre>\n<p>And login using <code>nagiosadmin<\/code> and the assigned password.<\/p>\n<p><a href=\"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_apache_authentication_gateway.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1460\" height=\"491\" class=\"aligncenter size-full wp-image-1369\" src=\"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_apache_authentication_gateway.png\" alt=\"nagios_apache_authentication_gateway\" srcset=\"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_apache_authentication_gateway.png 1460w, https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_apache_authentication_gateway-300x101.png 300w, https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_apache_authentication_gateway-1024x344.png 1024w, https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_apache_authentication_gateway-768x258.png 768w\" sizes=\"auto, (max-width: 1460px) 100vw, 1460px\" \/><\/a><\/p>\n<p>And you should be greeted by the Nagios dashboard.<\/p>\n<p><a href=\"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_start_page.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1682\" height=\"945\" class=\"aligncenter size-full wp-image-1370\" src=\"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_start_page.png\" alt=\"nagios_start_page\" srcset=\"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_start_page.png 1682w, https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_start_page-300x169.png 300w, https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_start_page-1024x575.png 1024w, https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_start_page-768x431.png 768w, https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/nagios_start_page-1536x863.png 1536w\" sizes=\"auto, (max-width: 1682px) 100vw, 1682px\" \/><\/a><\/p>\n<h2 id=\"conclusion\">Conclusion<\/h2>\n<p>Well done. You now should have installed and configured Nagios for server monitoring.<\/p>\n<p>If you have any questions or find any issues with this guide, then please feel free to contact us via the comments or our social media channels and we&#8217;ll get back to you as soon as possible.<\/p>\n<div class=\"container custom-content-block\" style=\"background-color: #282a36; border-radius: 3px; padding: 20px 25px 35px 25px !important; margin-top: 60px; margin-bottom: 60px;\">\r\n<div class=\"row\">\r\n<div class=\"col-lg-12\">\r\n<p style=\"color: #74fa7a; font-weight: bold !important; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important;\">Get a High RAM VPS at Entry-level Pricing<\/p>\r\n\r\n<\/div>\r\n<div class=\"col-lg-12\">\r\n<p style=\"color: #ffffff; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important;\">Starting with 2GB RAM at $6.99\/month<\/p>\r\n\r\n<\/div>\r\n<div class=\"col-lg-12\">\r\n<p style=\"color: #60709f; font-size: 1em; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important;\">Take your pick from our KVM VPS that offer a generous amount of RAM at an affordable price. We've got 5 plans for you to choose from, our cheapest featuring 2GB RAM at $6.99\/mo.<\/p>\r\n\r\n<div style=\"font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important; font-size: 14px; color: #74fa7a;\"><span style=\"color: #ffffff;\">[Main Features]<\/span>\r\n- SSD Drives\r\n- KVM Virtualization\r\n- 1Gbps Shared Uplink\r\n- Location: Chicago, IL<\/div>\r\n<\/div>\r\n<div class=\"col-lg-12\">\r\n<p style=\"color: #ffffff; font-weight: bold !important; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important;\">Pick one of our KVM plans<\/p>\r\n\r\n<\/div>\r\n<div class=\"col-lg-12\"><a class=\"btn btn-primary btn-lg\" style=\"background-color: #58689e; color: #ffffff; box-shadow: 0 2px 2px 0 #3F51B5, 0 3px 1px -2px #3F51B5, 0 1px 5px 0 #3F51B5; font-family: Droid Sans Mono,'DroidSansMonoRegular','Courier New',monospace !important; font-weight: bold !important;\" role=\"button\" href=\"https:\/\/draculaservers.com\/kvm.php#choose-plan\" target=\"_blank\" rel=\"noopener\" aria-pressed=\"true\">Get started now<\/a><\/div>\r\n<\/div>\r\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Prerequisites To follow this tutorial we assume the following: You&#8217;re using a machine running Ubuntu or Debian. This tutorial is for Ubuntu 18.04, but it should work on Ubuntu 16.4, 14.04 and Debian systems. You&#8217;re acting as a non-root sudo user. If you don&#8217;t have one set up, you can follow our tutorial on creating [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":1368,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[64,22],"tags":[83,84],"class_list":["post-1367","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-open-source","category-ubuntu","tag-nagios","tag-server-monitoring"],"blocksy_meta":{"styles_descriptor":{"styles":{"desktop":"","tablet":"","mobile":""},"google_fonts":[],"version":6}},"featured_image_urls_v2":{"full":["https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png",1024,512,false],"thumbnail":["https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring-150x150.png",150,150,true],"medium":["https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring-300x150.png",300,150,true],"medium_large":["https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring-768x384.png",768,384,true],"large":["https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png",1024,512,false],"1536x1536":["https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png",1024,512,false],"2048x2048":["https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png",1024,512,false],"pk-small":["https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring-80x80.png",80,80,true],"pk-thumbnail":["https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring-300x225.png",300,225,true]},"post_excerpt_stackable_v2":"<p>Prerequisites To follow this tutorial we assume the following: You&#8217;re using a machine running Ubuntu or Debian. This tutorial is for Ubuntu 18.04, but it should work on Ubuntu 16.4, 14.04 and Debian systems. You&#8217;re acting as a non-root sudo user. If you don&#8217;t have one set up, you can follow our tutorial on creating a sudo user on Ubuntu 18.04 Get a High RAM VPS at Entry-level Pricing Starting with 2GB RAM at $6.99\/month Take your pick from our KVM VPS that offer a generous amount of RAM at an affordable price. We&#8217;ve got 5 plans for you to&hellip;<\/p>\n","category_list_v2":"<a href=\"https:\/\/draculaservers.com\/tutorials\/category\/open-source\/\" rel=\"category tag\">Open-source<\/a>, <a href=\"https:\/\/draculaservers.com\/tutorials\/category\/ubuntu\/\" rel=\"category tag\">Ubuntu<\/a>","author_info_v2":{"name":"Vlad","url":"https:\/\/draculaservers.com\/tutorials\/author\/vlad\/"},"comments_num_v2":"0 comments","yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How to Install &amp; Configure Nagios 4 on Ubuntu 18.04 for Server Monitoring<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Install &amp; Configure Nagios 4 on Ubuntu 18.04 for Server Monitoring\" \/>\n<meta property=\"og:description\" content=\"Prerequisites To follow this tutorial we assume the following: You&#8217;re using a machine running Ubuntu or Debian. This tutorial is for Ubuntu 18.04, but it should work on Ubuntu 16.4, 14.04 and Debian systems. You&#8217;re acting as a non-root sudo user. If you don&#8217;t have one set up, you can follow our tutorial on creating [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/\" \/>\n<meta property=\"og:site_name\" content=\"Dracula Servers Tutorials\" \/>\n<meta property=\"article:published_time\" content=\"2019-01-16T23:06:56+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-11-14T20:34:35+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1024\" \/>\n\t<meta property=\"og:image:height\" content=\"512\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Vlad\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Vlad\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/\"},\"author\":{\"name\":\"Vlad\",\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/#\\\/schema\\\/person\\\/931f7fa8b2126ace6edfb82775e0ec0e\"},\"headline\":\"How to Install Nagios 4 on Ubuntu 18.04 for Server Monitoring\",\"datePublished\":\"2019-01-16T23:06:56+00:00\",\"dateModified\":\"2021-11-14T20:34:35+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/\"},\"wordCount\":536,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/wp-content\\\/uploads\\\/2019\\\/01\\\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png\",\"keywords\":[\"Nagios\",\"Server Monitoring\"],\"articleSection\":[\"Open-source\",\"Ubuntu\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/\",\"url\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/\",\"name\":\"How to Install & Configure Nagios 4 on Ubuntu 18.04 for Server Monitoring\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/wp-content\\\/uploads\\\/2019\\\/01\\\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png\",\"datePublished\":\"2019-01-16T23:06:56+00:00\",\"dateModified\":\"2021-11-14T20:34:35+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/#primaryimage\",\"url\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/wp-content\\\/uploads\\\/2019\\\/01\\\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png\",\"contentUrl\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/wp-content\\\/uploads\\\/2019\\\/01\\\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png\",\"width\":1024,\"height\":512,\"caption\":\"install_nagios_ubuntu\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/install-nagios-ubuntu\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Install Nagios 4 on Ubuntu 18.04 for Server Monitoring\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/#website\",\"url\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/\",\"name\":\"Dracula Servers Tutorials\",\"description\":\"Dedicated Servers\",\"publisher\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/#organization\",\"name\":\"Dracula Servers\",\"url\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/wp-content\\\/uploads\\\/2016\\\/06\\\/dracula_full_logo_smaller.png\",\"contentUrl\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/wp-content\\\/uploads\\\/2016\\\/06\\\/dracula_full_logo_smaller.png\",\"width\":1625,\"height\":200,\"caption\":\"Dracula Servers\"},\"image\":{\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/draculaservers.com\\\/tutorials\\\/#\\\/schema\\\/person\\\/931f7fa8b2126ace6edfb82775e0ec0e\",\"name\":\"Vlad\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/499c7a24aa9727703300a291f8f69dfd1b01b8d6a19a4ae4fbe669b4b12b8cbe?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/499c7a24aa9727703300a291f8f69dfd1b01b8d6a19a4ae4fbe669b4b12b8cbe?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/499c7a24aa9727703300a291f8f69dfd1b01b8d6a19a4ae4fbe669b4b12b8cbe?s=96&d=mm&r=g\",\"caption\":\"Vlad\"},\"description\":\"Tech Support\",\"sameAs\":[\"https:\\\/\\\/draculaservers.com\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Install & Configure Nagios 4 on Ubuntu 18.04 for Server Monitoring","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/","og_locale":"en_US","og_type":"article","og_title":"How to Install & Configure Nagios 4 on Ubuntu 18.04 for Server Monitoring","og_description":"Prerequisites To follow this tutorial we assume the following: You&#8217;re using a machine running Ubuntu or Debian. This tutorial is for Ubuntu 18.04, but it should work on Ubuntu 16.4, 14.04 and Debian systems. You&#8217;re acting as a non-root sudo user. If you don&#8217;t have one set up, you can follow our tutorial on creating [&hellip;]","og_url":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/","og_site_name":"Dracula Servers Tutorials","article_published_time":"2019-01-16T23:06:56+00:00","article_modified_time":"2021-11-14T20:34:35+00:00","og_image":[{"width":1024,"height":512,"url":"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png","type":"image\/png"}],"author":"Vlad","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Vlad","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/#article","isPartOf":{"@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/"},"author":{"name":"Vlad","@id":"https:\/\/draculaservers.com\/tutorials\/#\/schema\/person\/931f7fa8b2126ace6edfb82775e0ec0e"},"headline":"How to Install Nagios 4 on Ubuntu 18.04 for Server Monitoring","datePublished":"2019-01-16T23:06:56+00:00","dateModified":"2021-11-14T20:34:35+00:00","mainEntityOfPage":{"@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/"},"wordCount":536,"commentCount":0,"publisher":{"@id":"https:\/\/draculaservers.com\/tutorials\/#organization"},"image":{"@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/#primaryimage"},"thumbnailUrl":"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png","keywords":["Nagios","Server Monitoring"],"articleSection":["Open-source","Ubuntu"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/","url":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/","name":"How to Install & Configure Nagios 4 on Ubuntu 18.04 for Server Monitoring","isPartOf":{"@id":"https:\/\/draculaservers.com\/tutorials\/#website"},"primaryImageOfPage":{"@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/#primaryimage"},"image":{"@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/#primaryimage"},"thumbnailUrl":"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png","datePublished":"2019-01-16T23:06:56+00:00","dateModified":"2021-11-14T20:34:35+00:00","breadcrumb":{"@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/#primaryimage","url":"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png","contentUrl":"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2019\/01\/How-to-Install-Nagios-4-on-Ubuntu-18.04-for-Server-Monitoring.png","width":1024,"height":512,"caption":"install_nagios_ubuntu"},{"@type":"BreadcrumbList","@id":"https:\/\/draculaservers.com\/tutorials\/install-nagios-ubuntu\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/draculaservers.com\/tutorials\/"},{"@type":"ListItem","position":2,"name":"How to Install Nagios 4 on Ubuntu 18.04 for Server Monitoring"}]},{"@type":"WebSite","@id":"https:\/\/draculaservers.com\/tutorials\/#website","url":"https:\/\/draculaservers.com\/tutorials\/","name":"Dracula Servers Tutorials","description":"Dedicated Servers","publisher":{"@id":"https:\/\/draculaservers.com\/tutorials\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/draculaservers.com\/tutorials\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/draculaservers.com\/tutorials\/#organization","name":"Dracula Servers","url":"https:\/\/draculaservers.com\/tutorials\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/draculaservers.com\/tutorials\/#\/schema\/logo\/image\/","url":"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2016\/06\/dracula_full_logo_smaller.png","contentUrl":"https:\/\/draculaservers.com\/tutorials\/wp-content\/uploads\/2016\/06\/dracula_full_logo_smaller.png","width":1625,"height":200,"caption":"Dracula Servers"},"image":{"@id":"https:\/\/draculaservers.com\/tutorials\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/draculaservers.com\/tutorials\/#\/schema\/person\/931f7fa8b2126ace6edfb82775e0ec0e","name":"Vlad","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/499c7a24aa9727703300a291f8f69dfd1b01b8d6a19a4ae4fbe669b4b12b8cbe?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/499c7a24aa9727703300a291f8f69dfd1b01b8d6a19a4ae4fbe669b4b12b8cbe?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/499c7a24aa9727703300a291f8f69dfd1b01b8d6a19a4ae4fbe669b4b12b8cbe?s=96&d=mm&r=g","caption":"Vlad"},"description":"Tech Support","sameAs":["https:\/\/draculaservers.com"]}]}},"_links":{"self":[{"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/posts\/1367","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/comments?post=1367"}],"version-history":[{"count":1,"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/posts\/1367\/revisions"}],"predecessor-version":[{"id":2143,"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/posts\/1367\/revisions\/2143"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/media\/1368"}],"wp:attachment":[{"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/media?parent=1367"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/categories?post=1367"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/draculaservers.com\/tutorials\/wp-json\/wp\/v2\/tags?post=1367"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}