<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>nagios Archives - Linux Windows and android Tutorials</title>
	<atom:link href="https://www.osradar.com/tag/nagios/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.osradar.com</link>
	<description>tutorials and news and Seurity</description>
	<lastBuildDate>Sat, 01 Feb 2020 23:32:41 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=5.8.12</generator>
	<item>
		<title>How to install Nagios agent on Ubuntu 18.04?</title>
		<link>https://www.osradar.com/install-nagios-agent-ubuntu-linux-mint/</link>
					<comments>https://www.osradar.com/install-nagios-agent-ubuntu-linux-mint/#comments</comments>
		
		<dc:creator><![CDATA[angeloma]]></dc:creator>
		<pubDate>Fri, 07 Feb 2020 23:25:00 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[bionic]]></category>
		<category><![CDATA[How to]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[linux mint]]></category>
		<category><![CDATA[monitoring]]></category>
		<category><![CDATA[nagios]]></category>
		<category><![CDATA[nagios agent]]></category>
		<category><![CDATA[Tutorial]]></category>
		<category><![CDATA[ubuntu]]></category>
		<guid isPermaLink="false">https://www.osradar.com/?p=17943</guid>

					<description><![CDATA[<p>We continue with some articles on Nagios. Well, once we have installed the server and the plugins come to another step. In this post, I&#8217;ll show you how to install Nagios agent on Ubuntu 18.04 / Linux Mint 19. So, we have already talked a lot about Nagios and its potential. But for everything to [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/install-nagios-agent-ubuntu-linux-mint/">How to install Nagios agent on Ubuntu 18.04?</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>We continue with some articles on Nagios. Well, once we have <a href="https://www.osradar.com/install-nagios-debian/" target="_blank" rel="noopener noreferrer">installed the server</a> and the <a href="https://www.osradar.com/install-the-nagios-plugins-debian-10/" target="_blank" rel="noopener noreferrer">plugins</a> come to another step. In this post, I&#8217;ll show you how to install Nagios agent on Ubuntu 18.04 / Linux Mint 19.</p>
<p>So, we have already talked a lot about Nagios and its potential. But for everything to be complete, we need to install the agent in a client operating system so that the server can monitor it.</p>
<p>So that&#8217;s what we&#8217;re going to do.</p>
<h2>Install Nagios agent on Ubuntu 18.04</h2>
<h3>1.- Working on the client machine</h3>
<p>The Nagios agent is NRPE (Nagios Remote Plugin Executor) which according to the <a href="https://en.wikipedia.org/wiki/Nagios" target="_blank" rel="noopener noreferrer">Nagios wiki</a> is the following</p>
<blockquote>
<p>&#8220;it is a Nagios agent that allows remote system monitoring using scripts that are hosted on the remote systems.It allows for monitoring of resources such as disk usage, system load or the number of users currently logged in.&#8221;</p>
</blockquote>
<p>The big advantage is that this agent is available in the official Ubuntu repositories and you don&#8217;t have to do much to install it.</p>
<p>So, open a terminal in the client operating system. Not on the server. And run the following:</p>
<pre>:~$ sudo apt-get install nagios-nrpe-server nagios-plugins</pre>
<figure id="attachment_17981" aria-describedby="caption-attachment-17981" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17981" src="https://www.osradar.com/wp-content/uploads/2020/02/1.png" alt="1.- Install Nagios agent on Ubuntu 18.04 / Linux Mint 19" width="1365" height="443" srcset="https://www.osradar.com/wp-content/uploads/2020/02/1.png 1365w, https://www.osradar.com/wp-content/uploads/2020/02/1-300x97.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/1-1024x332.png 1024w, https://www.osradar.com/wp-content/uploads/2020/02/1-768x249.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/1-696x226.png 696w, https://www.osradar.com/wp-content/uploads/2020/02/1-1068x347.png 1068w, https://www.osradar.com/wp-content/uploads/2020/02/1-1294x420.png 1294w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-17981" class="wp-caption-text">1.- Install Nagios agent on Ubuntu 18.04 / Linux Mint 19</figcaption></figure>
<p>When the installation is finished, a configuration file must be modified to tell the client where the Nagios server is.</p>
<pre>:~$ sudo nano /etc/nagios/nrpe.cfg</pre>
<p>In the <code>allowed_hosts</code> directive add the IP address of the computer where Nagios is installed. However, you can specify multiple IP addresses if there are multiple Nagios servers.</p>
<pre>allowed_hosts=127.0.0.1, 192.168.250.32</pre>
<p>In my case, this is the file.</p>
<figure id="attachment_17982" aria-describedby="caption-attachment-17982" style="width: 991px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17982" src="https://www.osradar.com/wp-content/uploads/2020/02/2.png" alt="2.- Configuring the plugin" width="991" height="562" srcset="https://www.osradar.com/wp-content/uploads/2020/02/2.png 991w, https://www.osradar.com/wp-content/uploads/2020/02/2-300x170.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/2-768x436.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/2-696x395.png 696w, https://www.osradar.com/wp-content/uploads/2020/02/2-741x420.png 741w" sizes="(max-width: 991px) 100vw, 991px" /><figcaption id="caption-attachment-17982" class="wp-caption-text">2.- Configuring the plugin</figcaption></figure>
<p>Then save the changes and close the file.</p>
<p>For all these changes to take effect, the Nagios client service has to be restarted.</p>
<pre>:~$ sudo systemctl restart nagios-nrpe-server</pre>
<p>Finally, we check if the agent is working with the following command:</p>
<pre>:~$ /usr/lib/nagios/plugins/check_load -w 15,10,5 -c 30,25,20</pre>
<p>If you get a screen output like this:</p>
<pre>OK - load average: 0.74, 0.62, 0.68|load1=0.740;15.000;30.000;0; load5=0.620;10.000;25.000;0; load15=0.680;5.000;20.000;0;</pre>
<p>It means that everything is fine.</p>
<h3>2.- Working on the server</h3>
<p>It is now necessary to install NRPE on the server. This is so that you can establish communication with the client.</p>
<p>So, on the server open a terminal and run the following:</p>
<pre>:~$ sudo apt install nagios-nrpe-plugin</pre>
<figure id="attachment_17983" aria-describedby="caption-attachment-17983" style="width: 1023px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17983" src="https://www.osradar.com/wp-content/uploads/2020/02/3.png" alt="3.- Installing the Nagios agent on the server" width="1023" height="193" srcset="https://www.osradar.com/wp-content/uploads/2020/02/3.png 1023w, https://www.osradar.com/wp-content/uploads/2020/02/3-300x57.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/3-768x145.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/3-696x131.png 696w" sizes="(max-width: 1023px) 100vw, 1023px" /><figcaption id="caption-attachment-17983" class="wp-caption-text">3.- Installing the Nagios agent on the server</figcaption></figure>
<p>Now that it is installed, some configuration files need to be modified. The first one is the Nagios configuration file where we have to enable the server folder.</p>
<pre>:~$ sudo nano /usr/local/nagios/etc/nagios.cfg</pre>
<p>You do it by decomposing the next line:</p>
<pre>cfg_dir=/usr/local/nagios/etc/servers</pre>
<figure id="attachment_17984" aria-describedby="caption-attachment-17984" style="width: 1008px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17984" src="https://www.osradar.com/wp-content/uploads/2020/02/4.png" alt="4.- Configuring the Nagios agent on the server" width="1008" height="390" srcset="https://www.osradar.com/wp-content/uploads/2020/02/4.png 1008w, https://www.osradar.com/wp-content/uploads/2020/02/4-300x116.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/4-768x297.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/4-696x269.png 696w" sizes="(max-width: 1008px) 100vw, 1008px" /><figcaption id="caption-attachment-17984" class="wp-caption-text">4.- Configuring the Nagios agent on the server</figcaption></figure>
<p>Again, save the changes and close the file. Then create the folder in question.</p>
<pre>:~$ sudo mkdir /usr/local/nagios/etc/servers</pre>
<p>After that, another file has to be modified to add a command that the Nagios server has to run to communicate with the client.</p>
<pre>:~$ sudo nano /usr/local/nagios/etc/objects/commands.cfg</pre>
<p>At the end of the file, add the following:</p>
<pre>define command {<br />    command_name check_nrpe<br />    command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -c $ARG1$<br />}</pre>
<figure id="attachment_17985" aria-describedby="caption-attachment-17985" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17985" src="https://www.osradar.com/wp-content/uploads/2020/02/5.png" alt="5.- Adding a command to monitoring the client" width="1365" height="481" srcset="https://www.osradar.com/wp-content/uploads/2020/02/5.png 1365w, https://www.osradar.com/wp-content/uploads/2020/02/5-300x106.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/5-1024x361.png 1024w, https://www.osradar.com/wp-content/uploads/2020/02/5-768x271.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/5-696x245.png 696w, https://www.osradar.com/wp-content/uploads/2020/02/5-1068x376.png 1068w, https://www.osradar.com/wp-content/uploads/2020/02/5-1192x420.png 1192w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-17985" class="wp-caption-text">5.- Adding a command to monitoring the client</figcaption></figure>
<p>Again, save the changes and close the file.</p>
<p>Now we have to create a new configuration file for the client that we are going to add.</p>
<pre>:~$ sudo nano /usr/local/nagios/etc/servers/client.cfg</pre>
<p>And add the following:</p>
<pre>define host{<br />use                             linux-server<br />host_name                       laptop.osradar<br />alias                           Ubuntu 18<br />address                         192.168.250.6<br />}<br /><br />define service{<br />        use                     generic-service<br />        host_name               laptop.osradar<br />        service_description     CPU Load<br />        check_command           check_nrpe!check_load<br />        }<br /><br />define service{<br />        use                     generic-service<br />        host_name               laptop.osradar<br />        service_description     Total Processes<br />        check_command           check_nrpe!check_total_procs<br />        }<br /><br />define service{<br />        use                     generic-service<br />        host_name               laptop.osradar<br />        service_description     Current Users<br />        check_command           check_nrpe!check_users<br />        }<br /><br />define service{<br />        use                     generic-service<br />        host_name               laptop.osradar<br />        service_description     SSH Monitoring<br />        check_command           check_nrpe!check_ssh<br />        }<br />define service{<br />        use                     generic-service<br />        host_name               laptop.osradar<br />        service_description     FTP Monitoring<br />        check_command           check_nrpe!check_ftp<br />        }</pre>
<p>Nagios is very flexible because in this file you can add or remove the services you want.</p>
<p>Also, you have to modify some parameters like the hostname of the client machine and the IP address. This is enough.</p>
<figure id="attachment_17986" aria-describedby="caption-attachment-17986" style="width: 1145px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17986" src="https://www.osradar.com/wp-content/uploads/2020/02/6.png" alt="6.- Creating a new file for the host" width="1145" height="649" srcset="https://www.osradar.com/wp-content/uploads/2020/02/6.png 1145w, https://www.osradar.com/wp-content/uploads/2020/02/6-300x170.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/6-1024x580.png 1024w, https://www.osradar.com/wp-content/uploads/2020/02/6-768x435.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/6-696x395.png 696w, https://www.osradar.com/wp-content/uploads/2020/02/6-1068x605.png 1068w, https://www.osradar.com/wp-content/uploads/2020/02/6-741x420.png 741w" sizes="(max-width: 1145px) 100vw, 1145px" /><figcaption id="caption-attachment-17986" class="wp-caption-text">6.- Creating a new file for the host</figcaption></figure>
<p>Then, it is convenient to check if the configuration file has a syntax error. To do this, run the following command:</p>
<pre>:~$ sudo /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg</pre>
<figure id="attachment_17987" aria-describedby="caption-attachment-17987" style="width: 1064px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17987" src="https://www.osradar.com/wp-content/uploads/2020/02/7.png" alt="7.- Cheecking the nagios configuration file" width="1064" height="695" srcset="https://www.osradar.com/wp-content/uploads/2020/02/7.png 1064w, https://www.osradar.com/wp-content/uploads/2020/02/7-300x196.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/7-1024x669.png 1024w, https://www.osradar.com/wp-content/uploads/2020/02/7-768x502.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/7-696x455.png 696w, https://www.osradar.com/wp-content/uploads/2020/02/7-643x420.png 643w" sizes="(max-width: 1064px) 100vw, 1064px" /><figcaption id="caption-attachment-17987" class="wp-caption-text">7.- Cheecking the nagios configuration file</figcaption></figure>
<p>Then test to see if the server can communicate with the client:</p>
<pre>:~$ cd /usr/lib/nagios/plugins/<br />:~$ ./check_nrpe -H 192.168.250.6</pre>
<figure id="attachment_17988" aria-describedby="caption-attachment-17988" style="width: 934px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17988" src="https://www.osradar.com/wp-content/uploads/2020/02/8.png" alt="8.- Checking the plugin" width="934" height="146" srcset="https://www.osradar.com/wp-content/uploads/2020/02/8.png 934w, https://www.osradar.com/wp-content/uploads/2020/02/8-300x47.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/8-768x120.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/8-696x109.png 696w" sizes="(max-width: 934px) 100vw, 934px" /><figcaption id="caption-attachment-17988" class="wp-caption-text">8.- Checking the plugin</figcaption></figure>
<p>Replace the IP address with the address of the computer that will be the client.</p>
<p>To avoid running problems with the plugin, copy it to the location where the rest of them are.</p>
<pre>:~$ sudo cp check_nrpe /usr/local/nagios/libexec</pre>
<p>And finally, restart the service.</p>
<pre>:~$ sudo systemctl restart nagios</pre>
<p>And that is it.</p>
<h3>3.- Testing the Nagios client on Ubuntu 18.04</h3>
<p>Now open your web browser and access Nagios. You will see the following:</p>
<figure id="attachment_17989" aria-describedby="caption-attachment-17989" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17989" src="https://www.osradar.com/wp-content/uploads/2020/02/9.png" alt="9.- Nagios agent working" width="1365" height="671" srcset="https://www.osradar.com/wp-content/uploads/2020/02/9.png 1365w, https://www.osradar.com/wp-content/uploads/2020/02/9-300x147.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/9-1024x503.png 1024w, https://www.osradar.com/wp-content/uploads/2020/02/9-768x378.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/9-324x160.png 324w, https://www.osradar.com/wp-content/uploads/2020/02/9-533x261.png 533w, https://www.osradar.com/wp-content/uploads/2020/02/9-696x342.png 696w, https://www.osradar.com/wp-content/uploads/2020/02/9-1068x525.png 1068w, https://www.osradar.com/wp-content/uploads/2020/02/9-854x420.png 854w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-17989" class="wp-caption-text">9.- Nagios agent working</figcaption></figure>
<p>And check the host information:</p>
<figure id="attachment_17990" aria-describedby="caption-attachment-17990" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17990" src="https://www.osradar.com/wp-content/uploads/2020/02/10.png" alt="10.- Nagios server and agent working" width="1365" height="670" srcset="https://www.osradar.com/wp-content/uploads/2020/02/10.png 1365w, https://www.osradar.com/wp-content/uploads/2020/02/10-300x147.png 300w, https://www.osradar.com/wp-content/uploads/2020/02/10-1024x503.png 1024w, https://www.osradar.com/wp-content/uploads/2020/02/10-768x377.png 768w, https://www.osradar.com/wp-content/uploads/2020/02/10-324x160.png 324w, https://www.osradar.com/wp-content/uploads/2020/02/10-533x261.png 533w, https://www.osradar.com/wp-content/uploads/2020/02/10-696x342.png 696w, https://www.osradar.com/wp-content/uploads/2020/02/10-1068x524.png 1068w, https://www.osradar.com/wp-content/uploads/2020/02/10-856x420.png 856w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-17990" class="wp-caption-text">10.- Nagios server and agent working</figcaption></figure>
<p>So everything&#8217;s fine.</p>
<h2>Conclusion</h2>
<p>To monitor with Nagios it is necessary to install the agent in each of the computers you want. In this post, you have learned how to install it in Ubuntu 18.04 / Linux Mint 19.3.</p>
<p>Please share this post and join our <a href="https://t.me/osradar" target="_blank" rel="noopener noreferrer">Telegram channel</a>.</p>


<p></p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/install-nagios-agent-ubuntu-linux-mint/">How to install Nagios agent on Ubuntu 18.04?</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.osradar.com/install-nagios-agent-ubuntu-linux-mint/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title>How to install the Nagios plugins on Debian 10?</title>
		<link>https://www.osradar.com/install-the-nagios-plugins-debian-10/</link>
					<comments>https://www.osradar.com/install-the-nagios-plugins-debian-10/#comments</comments>
		
		<dc:creator><![CDATA[angeloma]]></dc:creator>
		<pubDate>Thu, 06 Feb 2020 00:11:00 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Servers]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Buster]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[How to]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[monitoring]]></category>
		<category><![CDATA[nagios]]></category>
		<category><![CDATA[Nagios Plugins]]></category>
		<guid isPermaLink="false">https://www.osradar.com/?p=17868</guid>

					<description><![CDATA[<p>In this post, I will show you how to install the Nagios Plugins on Debian 10. Nagios is perhaps the most complete solution for network and equipment monitoring on Linux. It has everything you need to do the job properly. However, once it is installed it lacks the plugins that give the application real utility. [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/install-the-nagios-plugins-debian-10/">How to install the Nagios plugins on Debian 10?</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p><strong>In this post, I will show you how to install the Nagios Plugins on Debian 10.</strong></p>
<p>Nagios is perhaps the most complete solution for network and equipment monitoring on Linux. It has everything you need to do the job properly. However, once it is installed it lacks the plugins that give the application real utility.</p>
<p>With these plugins, you will be able to monitor many events in the server as well as in the rest of the computers in the network.</p>
<p>So let&#8217;s go for it.</p>
<h3>1) Install Nagios on Debian 10</h3>
<p>Obviously, the first step is to install Nagios on Debian 10. In addition, some packages have to be installed for the compilation of other packages.</p>
<p>So you can read our post about Nagios on Debian 10.</p>
<p><a href="https://www.osradar.com/install-nagios-debian/" target="_blank" rel="noopener noreferrer">How to install Nagios on Debian 10?</a></p>
<p>Then, after the installation, we can continue.</p>
<h3>2) Installing the Nagios plugins on Debian 10</h3>
<p>Now we have to download the source code. To do this we will use the <a href="https://www.osradar.com/the-wget-command/" target="_blank" rel="noopener noreferrer">wget</a> command.</p>
<p>Navigate to the <em>/tmp/</em> folder and from there download the file.</p>
<pre>:~$ cd /tmp/
:~$ wget -c https://nagios-plugins.org/download/nagios-plugins-2.3.1.tar.gz

--2020-01-31 07:25:23--  https://nagios-plugins.org/download/nagios-plugins-2.3.1.tar.gz
Resolving nagios-plugins.org (nagios-plugins.org)... 72.14.186.43
Connecting to nagios-plugins.org (nagios-plugins.org)|72.14.186.43|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2833267 (2.7M) [application/x-gzip]
Saving to: 'nagios-plugins-2.3.1.tar.gz'

nagios-plugins-2.3.1.tar.gz                100%[=====================================================================================&gt;]   2.70M   714KB/s    in 4.9s    

2020-01-31 07:25:30 (569 KB/s) - 'nagios-plugins-2.3.1.tar.gz' saved [2833267/2833267]</pre>
<p><figure id="attachment_17933" aria-describedby="caption-attachment-17933" style="width: 1362px" class="wp-caption alignnone"><img loading="lazy" class="wp-image-17933 size-full" src="https://www.osradar.com/wp-content/uploads/2020/01/1-24.png" alt="1.- Download the source code" width="1362" height="255" srcset="https://www.osradar.com/wp-content/uploads/2020/01/1-24.png 1362w, https://www.osradar.com/wp-content/uploads/2020/01/1-24-300x56.png 300w, https://www.osradar.com/wp-content/uploads/2020/01/1-24-1024x192.png 1024w, https://www.osradar.com/wp-content/uploads/2020/01/1-24-768x144.png 768w, https://www.osradar.com/wp-content/uploads/2020/01/1-24-696x130.png 696w, https://www.osradar.com/wp-content/uploads/2020/01/1-24-1068x200.png 1068w" sizes="(max-width: 1362px) 100vw, 1362px" /><figcaption id="caption-attachment-17933" class="wp-caption-text">1.- Download the source code</figcaption></figure></p>
<p>At the time of writing this post, the latest version of the Nagios plugins is 2.3.1. So to get the latest version, first check what it is and replace the version number.</p>
<p>When the download is complete, decompress the downloaded file.</p>
<pre>:~$ tar xzf nagios-plugins-2.3.1.tar.gz</pre>
<p>Now navigate to the generated folder and prepare to compile the package.</p>
<pre>:~$ ./configure --with-nagios-user=nagios --with-nagios-group=nagios
configure: creating ./config.status
config.status: creating gl/Makefile
config.status: creating nagios-plugins.spec
config.status: creating tools/build_perl_modules
config.status: creating Makefile
config.status: creating tap/Makefile
config.status: creating lib/Makefile
config.status: creating plugins/Makefile
config.status: creating lib/tests/Makefile
config.status: creating plugins-root/Makefile
config.status: creating plugins-scripts/Makefile
config.status: creating plugins-scripts/utils.pm
config.status: creating plugins-scripts/utils.sh
config.status: creating perlmods/Makefile
config.status: creating test.pl
config.status: creating pkg/solaris/pkginfo
config.status: creating po/Makefile.in
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands
config.status: executing libtool commands
config.status: executing po-directories commands
config.status: creating po/POTFILES
config.status: creating po/Makefile</pre>
<p><figure id="attachment_17932" aria-describedby="caption-attachment-17932" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17932" src="https://www.osradar.com/wp-content/uploads/2020/01/2-22.png" alt="2.- configuring the package" width="1365" height="443" srcset="https://www.osradar.com/wp-content/uploads/2020/01/2-22.png 1365w, https://www.osradar.com/wp-content/uploads/2020/01/2-22-300x97.png 300w, https://www.osradar.com/wp-content/uploads/2020/01/2-22-1024x332.png 1024w, https://www.osradar.com/wp-content/uploads/2020/01/2-22-768x249.png 768w, https://www.osradar.com/wp-content/uploads/2020/01/2-22-696x226.png 696w, https://www.osradar.com/wp-content/uploads/2020/01/2-22-1068x347.png 1068w, https://www.osradar.com/wp-content/uploads/2020/01/2-22-1294x420.png 1294w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-17932" class="wp-caption-text">2.- configuring the package</figcaption></figure></p>
<p>Now use the make command to create the package.</p>
<pre>:~$ make</pre>
<p><figure id="attachment_17934" aria-describedby="caption-attachment-17934" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17934" src="https://www.osradar.com/wp-content/uploads/2020/01/3-21.png" alt="3.-Building the Nagios plugins package" width="1365" height="716" srcset="https://www.osradar.com/wp-content/uploads/2020/01/3-21.png 1365w, https://www.osradar.com/wp-content/uploads/2020/01/3-21-300x157.png 300w, https://www.osradar.com/wp-content/uploads/2020/01/3-21-1024x537.png 1024w, https://www.osradar.com/wp-content/uploads/2020/01/3-21-768x403.png 768w, https://www.osradar.com/wp-content/uploads/2020/01/3-21-696x365.png 696w, https://www.osradar.com/wp-content/uploads/2020/01/3-21-1068x560.png 1068w, https://www.osradar.com/wp-content/uploads/2020/01/3-21-801x420.png 801w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-17934" class="wp-caption-text">3.-Building the Nagios plugins package</figcaption></figure></p>
<p>Then, perform the installation with the following command:</p>
<pre>:~$ sudo make install
ck_ifoperstatus check_mailq check_file_age check_ssl_validity utils.sh utils.pm '/usr/local/nagios/libexec'
make[2]: Nothing to be done for 'install-data-am'.
make[2]: Leaving directory '/tmp/nagios-plugins-2.3.1/plugins-scripts'
make[1]: Leaving directory '/tmp/nagios-plugins-2.3.1/plugins-scripts'
Making install in plugins-root
make[1]: Entering directory '/tmp/nagios-plugins-2.3.1/plugins-root'
make[2]: Entering directory '/tmp/nagios-plugins-2.3.1/plugins-root'
 /usr/bin/install -c -o nagios -g nagios check_dhcp /usr/local/nagios/libexec/check_dhcp
 chown root /usr/local/nagios/libexec/check_dhcp
 chmod ug=rx,u+s /usr/local/nagios/libexec/check_dhcp
 /usr/bin/install -c -o nagios -g nagios check_icmp /usr/local/nagios/libexec/check_icmp
 chown root /usr/local/nagios/libexec/check_icmp
 chmod ug=rx,u+s /usr/local/nagios/libexec/check_icmp
make[2]: Nothing to be done for 'install-data-am'.
make[2]: Leaving directory '/tmp/nagios-plugins-2.3.1/plugins-root'
make[1]: Leaving directory '/tmp/nagios-plugins-2.3.1/plugins-root'
Making install in po
make[1]: Entering directory '/tmp/nagios-plugins-2.3.1/po'
/usr/bin/mkdir -p /usr/local/nagios/share
installing fr.gmo as /usr/local/nagios/share/locale/fr/LC_MESSAGES/nagios-plugins.mo
installing de.gmo as /usr/local/nagios/share/locale/de/LC_MESSAGES/nagios-plugins.mo
if test "nagios-plugins" = "gettext-tools"; then \
  /usr/bin/mkdir -p /usr/local/nagios/share/gettext/po; \
  for file in Makefile.in.in remove-potcdate.sin    Makevars.template; do \
    /usr/bin/install -c -o nagios -g nagios -m 644 ./$file \
		    /usr/local/nagios/share/gettext/po/$file; \
  done; \
  for file in Makevars; do \
    rm -f /usr/local/nagios/share/gettext/po/$file; \
  done; \
else \
  : ; \
fi
make[1]: Leaving directory '/tmp/nagios-plugins-2.3.1/po'
make[1]: Entering directory '/tmp/nagios-plugins-2.3.1'
make[2]: Entering directory '/tmp/nagios-plugins-2.3.1'
make[2]: Nothing to be done for 'install-exec-am'.
make[2]: Nothing to be done for 'install-data-am'.
make[2]: Leaving directory '/tmp/nagios-plugins-2.3.1'
make[1]: Leaving directory '/tmp/nagios-plugins-2.3.1'</pre>
<p><figure id="attachment_17935" aria-describedby="caption-attachment-17935" style="width: 1201px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17935" src="https://www.osradar.com/wp-content/uploads/2020/01/4-20.png" alt="4.- Install the Nagios plugins on Debian 10" width="1201" height="716" srcset="https://www.osradar.com/wp-content/uploads/2020/01/4-20.png 1201w, https://www.osradar.com/wp-content/uploads/2020/01/4-20-300x179.png 300w, https://www.osradar.com/wp-content/uploads/2020/01/4-20-1024x610.png 1024w, https://www.osradar.com/wp-content/uploads/2020/01/4-20-768x458.png 768w, https://www.osradar.com/wp-content/uploads/2020/01/4-20-696x415.png 696w, https://www.osradar.com/wp-content/uploads/2020/01/4-20-1068x637.png 1068w, https://www.osradar.com/wp-content/uploads/2020/01/4-20-704x420.png 704w" sizes="(max-width: 1201px) 100vw, 1201px" /><figcaption id="caption-attachment-17935" class="wp-caption-text">4.- Install the Nagios plugins on Debian 10</figcaption></figure></p>
<p>At this point, everything should have gone smoothly. The plugins are installed in the <em>/usr/local/nagios/libexec/</em> folder so use the ls command to check if they were installed.</p>
<pre>:~$ ls /usr/local/nagios/libexec/</pre>
<p><figure id="attachment_17936" aria-describedby="caption-attachment-17936" style="width: 1307px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17936" src="https://www.osradar.com/wp-content/uploads/2020/01/5-17.png" alt="5.- Nagios plugins installed" width="1307" height="192" srcset="https://www.osradar.com/wp-content/uploads/2020/01/5-17.png 1307w, https://www.osradar.com/wp-content/uploads/2020/01/5-17-300x44.png 300w, https://www.osradar.com/wp-content/uploads/2020/01/5-17-1024x150.png 1024w, https://www.osradar.com/wp-content/uploads/2020/01/5-17-768x113.png 768w, https://www.osradar.com/wp-content/uploads/2020/01/5-17-696x102.png 696w, https://www.osradar.com/wp-content/uploads/2020/01/5-17-1068x157.png 1068w" sizes="(max-width: 1307px) 100vw, 1307px" /><figcaption id="caption-attachment-17936" class="wp-caption-text">5.- Nagios plugins installed</figcaption></figure></p>
<p>As you can see in the image, they were installed correctly.</p>
<p>Now restart the Nagios service to load the plugins.</p>
<pre>:~$ sudo systemctl restart nagios</pre>
<p>Now let&#8217;s see the results.</p>
<h3>3) Nagios plugins working</h3>
<p>After restarting the Nagios service, open your web browser and log in to Nagios with your username and password.</p>
<p>Now in the Hosts section, you will see the localhost information.</p>
<p><figure id="attachment_17937" aria-describedby="caption-attachment-17937" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="wp-image-17937 size-full" src="https://www.osradar.com/wp-content/uploads/2020/01/6-15.png" alt="6.- Using Nagios " width="1365" height="669" srcset="https://www.osradar.com/wp-content/uploads/2020/01/6-15.png 1365w, https://www.osradar.com/wp-content/uploads/2020/01/6-15-300x147.png 300w, https://www.osradar.com/wp-content/uploads/2020/01/6-15-1024x502.png 1024w, https://www.osradar.com/wp-content/uploads/2020/01/6-15-768x376.png 768w, https://www.osradar.com/wp-content/uploads/2020/01/6-15-324x160.png 324w, https://www.osradar.com/wp-content/uploads/2020/01/6-15-533x261.png 533w, https://www.osradar.com/wp-content/uploads/2020/01/6-15-696x341.png 696w, https://www.osradar.com/wp-content/uploads/2020/01/6-15-1068x523.png 1068w, https://www.osradar.com/wp-content/uploads/2020/01/6-15-857x420.png 857w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-17937" class="wp-caption-text">6.- Using Nagios</figcaption></figure></p>
<p>Also the information about the services, then, the plugins were loaded correctly.</p>
<p><figure id="attachment_17938" aria-describedby="caption-attachment-17938" style="width: 1365px" class="wp-caption alignnone"><img loading="lazy" class="size-full wp-image-17938" src="https://www.osradar.com/wp-content/uploads/2020/01/7-11.png" alt="7.- Using Nagios" width="1365" height="672" srcset="https://www.osradar.com/wp-content/uploads/2020/01/7-11.png 1365w, https://www.osradar.com/wp-content/uploads/2020/01/7-11-300x148.png 300w, https://www.osradar.com/wp-content/uploads/2020/01/7-11-1024x504.png 1024w, https://www.osradar.com/wp-content/uploads/2020/01/7-11-768x378.png 768w, https://www.osradar.com/wp-content/uploads/2020/01/7-11-324x160.png 324w, https://www.osradar.com/wp-content/uploads/2020/01/7-11-533x261.png 533w, https://www.osradar.com/wp-content/uploads/2020/01/7-11-696x343.png 696w, https://www.osradar.com/wp-content/uploads/2020/01/7-11-1068x526.png 1068w, https://www.osradar.com/wp-content/uploads/2020/01/7-11-853x420.png 853w" sizes="(max-width: 1365px) 100vw, 1365px" /><figcaption id="caption-attachment-17938" class="wp-caption-text">7.- Using Nagios</figcaption></figure></p>
<p>And that is it.</p>
<h2>Conclusion</h2>
<p>This tutorial is an add-on for you to have fully functional Nagios on your Linux server. Now you have learned how to install the plugins of this tool.</p>
<p>Please share this post and join our <a href="https://t.me/osradar" target="_blank" rel="noopener noreferrer">Telegram channel</a>.</p>
<p>The post <a rel="nofollow" href="https://www.osradar.com/install-the-nagios-plugins-debian-10/">How to install the Nagios plugins on Debian 10?</a> appeared first on <a rel="nofollow" href="https://www.osradar.com">Linux  Windows and android  Tutorials</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.osradar.com/install-the-nagios-plugins-debian-10/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
	</channel>
</rss>
