Add Linux With SNMP Error

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
tsabit
Posts: 35
Joined: Thu Sep 15, 2016 3:26 am

Add Linux With SNMP Error

Post by tsabit »

Hi Support,

i add the LInux OS on Nagios XI but the OID is not available

please assist me
You do not have the required permissions to view the files attached to this post.
dwasswa

Re: Add Linux With SNMP Error

Post by dwasswa »

Hi @tsabit,

Before you can monitor a Linux machine using SNMP, you'll need to install and configure it on your linux machine.

On RHEL / CentOS systems use the following command:

Code: Select all

yum install net-snmp
On Debian / Ubuntu based systems use the following command:

Code: Select all

sudo apt-get install snmpd libsnmp-dev
Please follow this guide...https://assets.nagios.com/downloads/nag ... 1493223405 and then when you complete all the steps you may now use the wizard.
tsabit
Posts: 35
Joined: Thu Sep 15, 2016 3:26 am

Re: Add Linux With SNMP Error

Post by tsabit »

dwasswa wrote:Hi @tsabit,

Before you can monitor a Linux machine using SNMP, you'll need to install and configure it on your linux machine.

On RHEL / CentOS systems use the following command:

Code: Select all

yum install net-snmp
On Debian / Ubuntu based systems use the following command:

Code: Select all

sudo apt-get install snmpd libsnmp-dev
Please follow this guide...https://assets.nagios.com/downloads/nag ... 1493223405 and then when you complete all the steps you may now use the wizard.
Hi dwasswa,

I have installed net-snmp on the server the communitity is "tmli" but still error on Nagios.

please assist me.

Regards,

Tsabit
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Add Linux With SNMP Error

Post by scottwilkerson »

Can you run the following from the CLI on your Nagios XI box and get a response that is not a Timeout?

Code: Select all

snmpwalk -v 2c -c tmli 192.168.1.84
If you do not, either the firewall is blocking access, the snmpd service isn't running or there is some other error in accessing the machine.
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
dwasswa

Re: Add Linux With SNMP Error

Post by dwasswa »

Hi @tsabit,

First,can you please verify the version of linux you are using?

Second, please make sure that the snmp daemon is running by running by doing the following:

1.Go to your terminal on the remote / target linux host and run the following commnads:

Start the service....

Code: Select all

systemctl start  snmpd.service
Check if its running.....

Code: Select all

systemctl status  snmpd.service
expected output if its running:

Code: Select all

 snmpd.service - Simple Network Management Protocol (SNMP) Daemon.
   Loaded: loaded (/usr/lib/systemd/system/snmpd.service; disabled; vendor preset: disabled)
   Active: active (running) since Wed 2017-09-27 11:52:40 CDT; 32s ago
 Main PID: 20304 (snmpd)
   CGroup: /system.slice/snmpd.service
           └─20304 /usr/sbin/snmpd -LS0-6d -f
Third,make sure ports

Code: Select all

161
for SNMP AND

Code: Select all

162
for SNMP traps are open. This you have to check on your firewall permissions.
OR
You could simply run

Code: Select all

firewall-cmd --list-all 
to show you open or active ports and you will get this kind of output

Code: Select all

public (active)
  target: default
  icmp-block-inversion: no
  interfaces: ens160
  sources:
  services: dhcpv6-client ssh
  ports: 5666/tcp 161/tcp 80/tcp 5667/tcp 12489/tcp
  protocols:
  masquerade: no
  forward-ports:
  sourceports:
  icmp-blocks:
  rich rules:
If your port 161 and 162 for SNMP are not listed as active, then run command

Code: Select all

firewall-cmd --zone=public --add-port=<161>/tcp --permanent
to open,then

Code: Select all

firewall-cmd --reload
and check updates on the firewall again with

Code: Select all

firewall-cmd --list-all
Lastly check make sure you don't have special characters in your community tmli(make sure its correct)and correct ports and IPs for your target host.

Here is some good articles that will guide you on SNMP:

https://assets.nagios.com/downloads/nag ... 1493223405
https://support.nagios.com/kb/article/s ... tocol.html
https://support.nagios.com/kb/article/snmp-tools.html
https://support.nagios.com/kb/article/n ... orial.html

Please let me know if you have any questions
Locked