SlideShare a Scribd company logo
2
Most read
3
Most read
5
Most read
How To Install and Configure SNMP on RHEL 7
i | P a g e
Table of Contents
Overview.......................................................................................................................................................1
Applies To......................................................................................................................................................1
Pre-Requisites ...............................................................................................................................................1
Installation and Configuration procedure.....................................................................................................1
Check Package...........................................................................................................................................1
Install Package...........................................................................................................................................1
Verify Installation......................................................................................................................................2
SNMP – Configuration File........................................................................................................................2
Default Configuration File – Snippet.....................................................................................................2
Firewall Configuration...................................................................................................................................3
Firewall Configuration – Open UDP Port ..................................................................................................3
Firewall Configuration – Reload................................................................................................................3
Firewall Configuration – List .....................................................................................................................3
snmpwalk – localhost Query.....................................................................................................................4
snmpwalk – Remote Query.......................................................................................................................4
SNMP Configuration .....................................................................................................................................5
Listening address ......................................................................................................................................5
SNMP Daemon Management .......................................................................................................................5
Troubleshooting............................................................................................................................................6
Timeout: No Response from 127.0.0.1.....................................................................................................6
Error Message.......................................................................................................................................6
Cause.....................................................................................................................................................6
Resolution .............................................................................................................................................6
SNMP Version Features ................................................................................................................................7
How To Install and Configure SNMP on RHEL 7
1 | P a g e
Overview
SNMP stands for “Simple Network Management Protocol”, it can be utilized to monitor any devices that
support snmp, few of the devices are server, router, network printers, firewalls. SNMP can monitor a
variety of parameters for these devices such as server performance, network usage, disk utilization.
Applies To
Tested on RHEL 7, CentOS 7, though it can be configured on most of the *nix flavor of OS.
Pre-Requisites
 snmp, snmp-utils
Installation and Configuration procedure
First of all, we will check if the package is already installed else we will install the packages.
Check Package
Check if the package is already installed, to check package installation status, run the command;
rpm -qa | grep net-snmp net-snmp-utils
Install Package
After checking the package installation status, if the package is not installed. Install the package to install
run the command;
yum install net-snmp net-snmp-utils -y
How To Install and Configure SNMP on RHEL 7
2 | P a g e
Verify Installation
After installing the net-snmp packages verify if the package is installed, to check package installation
status, run the command;
rpm -qa | grep net-snmp*
SNMP – Configuration File
Default configuration file that is configured as per the below. To display current configuration without
comments and lines non-blank lines, run command;
grep -v "^$" /etc/snmp/snmpd.conf | grep -v '^ *#'
Default Configuration File – Snippet
com2sec notConfigUser default public
group notConfigGroup v1 notConfigUser
group notConfigGroup v2c notConfigUser
view systemview included .1.3.6.1.2.1.1
view systemview included .1.3.6.1.2.1.25.1.1
access notConfigGroup "" any noauth exact systemview none none
syslocation Unknown (edit /etc/snmp/snmpd.conf)
syscontact Root <root@localhost> (configure /etc/snmp/snmp.local.conf)
dontLogTCPWrappersConnects yes
How To Install and Configure SNMP on RHEL 7
3 | P a g e
Firewall Configuration
SNMP protocol works on UDP port “161” and this port needs to be opened in order to listen and scan the
report from remote servers and for latest version of snmp service supports running on TCP port which is
again on “161”.
Firewall Configuration – Open UDP Port
After installing and checking the default configuration, the next step that needs to be done is to open
firewall port, snmp protocol run on UDP port 161.
firewall-cmd --permanent --add-port=161/udp
Firewall Configuration – Reload
Reload the firewall configuration.
firewall-cmd --reload
Firewall Configuration – List
After reloading firewall daemon, list the current rules set.
firewall-cmd --list-all
How To Install and Configure SNMP on RHEL 7
4 | P a g e
snmpwalk – localhost Query
After configuring the firewall, you can go ahead and test the snmp query data on the localhost it should
be able to retrieve the OID values when you run. To retrieve the information run the command;
snmpwalk -v 1 -c public -O e 127.0.0.1
snmpwalk – Remote Query
To query from a remote client to retrieve the OID values when you run. To retrieve the information run
the command; in this case we are querying from a windows machine.
snmpwalk -r:54.165.245.172 -q -c:public
How To Install and Configure SNMP on RHEL 7
5 | P a g e
SNMP Configuration
In order to SNMP to work for any query requests, it should be configured only agentaddress directives is
listed and configured, similarly other directives can be configured according to the business needs.
Listening address
This attribute will associate the IP address wherein the snmp service will listen on.
Attribute Name IP Address Information Port
agentaddress 127.0.0.1 161
agentaddress IP Address 161
agentaddress 127.0.0.1:161
SNMP Daemon Management
State Command Purpose
Enable systemctl enable snmpd Enable the service to start at boot and start automatically
Start systemctl start snmpd Start the service
Stop systemctl stop snmpd Stop the service
Restart systemctl restart snmpd Restart the service
Disable systemctl disable snmpd Disable the service to start at upon booting
Mask systemctl mask snmpd Masking the service to disable dynamic and manual
starting.
How To Install and Configure SNMP on RHEL 7
6 | P a g e
Troubleshooting
Timeout: No Response from 127.0.0.1
Error Message
Timeout: No Response from 127.0.0.1
Cause
One of the cause is the service is not running, start the service.
Another cause is when the remote server doesn’t have port is blocked or not listening default port on the
client.
systemctl status snmpd
Resolution
To resolve the issue we will start the daemon and query again for the first cause, for the second cause
ensure firewall port is configured such that UDP port 161 is opened and listening, check firewall
configuration section.
systemctl start snmpd
How To Install and Configure SNMP on RHEL 7
7 | P a g e
SNMP Version Features
SNMP has 3 versions currently, that can be configured based on the business needs. The below table will
give insight into different versions and its features that provide device statistics.
SNMP Version Features
Version 1 This provides device statistics and error reporting without consuming a lot of system
resources. Security was limited to community strings and access controls based on
the IP address of the querying server. Data communication wasn't encrypted.
Version 2 This is referred to as v2c which expanded the number of supported error codes,
increased the size of counters used to track data, and has the ability to do bulk
queries that more efficiently loaded response packets with data
Version 3 This version provides greater security and remote configuration capabilities than
earlier versions.
Access is not only limited to a single community string for read-only and read/write
access, as usernames and passwords can also be configured in this version.
Support for encrypted SNMP data transfer and transfer error detection is also
provided.

More Related Content

PDF
Real life challenges and configurations when implementing HCL Sametime v12.0....
PPTX
HCL Domino V12 Key Security Features Overview
PDF
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법
PPTX
Overview of Distributed Virtual Router (DVR) in Openstack/Neutron
PDF
How To Configure SNMP Logging on RHEL 7
PDF
Simplifying The S's: Single Sign-On, SPNEGO and SAML
DOCX
Taller de habilidades-Windows Server 2012
PDF
AvailabilityZoneとHostAggregate
Real life challenges and configurations when implementing HCL Sametime v12.0....
HCL Domino V12 Key Security Features Overview
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법
Overview of Distributed Virtual Router (DVR) in Openstack/Neutron
How To Configure SNMP Logging on RHEL 7
Simplifying The S's: Single Sign-On, SPNEGO and SAML
Taller de habilidades-Windows Server 2012
AvailabilityZoneとHostAggregate

What's hot (20)

PPTX
Powershell Demo Presentation
PDF
HCL Domino V12 - TOTP
POTX
IBM Domino / IBM Notes Performance Tuning
PPTX
Docker Container Security - A Network View
PDF
お金が無いときのMySQL Cluster頼み
PPTX
Building IAM for OpenStack
PDF
【メモ】一般的に設計書に定義される項目例
PDF
PG-REXで学ぶPacemaker運用の実例
PPTX
EMEA Airheads - AP Discovery Logic and AP Deployment
PDF
OpenStackで始めるクラウド環境構築入門(Horizon 基礎編)
PPT
presentation on Docker
PDF
오픈스택 멀티노드 설치 후기
PDF
kube-system落としてみました
PDF
왜 쿠버네티스는 systemd로 cgroup을 관리하려고 할까요
PDF
Domino Tech School - Upgrading to Notes/Domino V10: Best Practices
PPT
Linux basic commands
ODP
Introduction to Ansible
PDF
Hyper-V Replica
PPTX
dominocamp2022.t1s1.dde.pptx
PPTX
Openstack zun,virtual kubelet
Powershell Demo Presentation
HCL Domino V12 - TOTP
IBM Domino / IBM Notes Performance Tuning
Docker Container Security - A Network View
お金が無いときのMySQL Cluster頼み
Building IAM for OpenStack
【メモ】一般的に設計書に定義される項目例
PG-REXで学ぶPacemaker運用の実例
EMEA Airheads - AP Discovery Logic and AP Deployment
OpenStackで始めるクラウド環境構築入門(Horizon 基礎編)
presentation on Docker
오픈스택 멀티노드 설치 후기
kube-system落としてみました
왜 쿠버네티스는 systemd로 cgroup을 관리하려고 할까요
Domino Tech School - Upgrading to Notes/Domino V10: Best Practices
Linux basic commands
Introduction to Ansible
Hyper-V Replica
dominocamp2022.t1s1.dde.pptx
Openstack zun,virtual kubelet
Ad

Viewers also liked (14)

PDF
Nginx bind() to 0.0.0.0:9080 failed
PDF
How To Install and Configure Salt Master on Ubuntu
PDF
How To Disable IE Enhanced Security Windows PowerShell
PDF
How To Install and Configure Screen on CentOS 7
PDF
How To Check IE Enhanced Security Is Enabled Windows PowerShell
PDF
How To Protect SSH Access with Fail2Ban on RHEL 7
PDF
How To Configure Nginx Load Balancer on CentOS 7
PDF
How To Install and Use ABRT CLI on RHEL 7
PDF
How To Find Package Installation Date on RHEL 7
PDF
How To Check file exists and Delete PowerShell
PDF
How To View Current Execution Policy PowerShell
PDF
How To Reset root Password on CentOS 7
PDF
How to Upgrade Openfire on CentOS 7
PDF
How to Install Configure and Use sysstat utils on RHEL 7
Nginx bind() to 0.0.0.0:9080 failed
How To Install and Configure Salt Master on Ubuntu
How To Disable IE Enhanced Security Windows PowerShell
How To Install and Configure Screen on CentOS 7
How To Check IE Enhanced Security Is Enabled Windows PowerShell
How To Protect SSH Access with Fail2Ban on RHEL 7
How To Configure Nginx Load Balancer on CentOS 7
How To Install and Use ABRT CLI on RHEL 7
How To Find Package Installation Date on RHEL 7
How To Check file exists and Delete PowerShell
How To View Current Execution Policy PowerShell
How To Reset root Password on CentOS 7
How to Upgrade Openfire on CentOS 7
How to Install Configure and Use sysstat utils on RHEL 7
Ad

Similar to How To Install and Configure SNMP on RHEL 7 or CentOS 7 (20)

PPT
Positive Hack Days. Pavlov. Network Infrastructure Security Assessment
PDF
Install and Configure RSyslog – CentOS 7 / RHEL 7
PDF
NetSim Technology Library - Software defined networks
PDF
An Express Guide ~ SNMP for Secure Rremote Resource Monitoring
ODP
Firewalld : A New Interface to Your Netfilter Stack
ODP
PandoraFMS: Free Monitoring System
PDF
26.1.7 lab snort and firewall rules
PPTX
RAC-Installing your First Cluster and Database
PDF
Configuration Firewalld On CentOS 8
PDF
Smart pos stepbystep-v2-0
DOCX
Packet Tracer: SNMP, Netflow, Sys-log
ODP
Nagios Conference 2013 - Spenser Reinhardt - Intro to Network Monitoring Usin...
PDF
Student packet tracer manual v1.1
PPT
Nagios Conference 2013 - Troy Lea - Leveraging and Understanding Performance ...
PDF
System monitoring
PDF
hakin9_6-2006_str22-33_snort_EN
PDF
Advanced RAC troubleshooting: Network
PDF
Free radius billing server with practical vpn exmaple
PDF
Nat mikrotik
PDF
2.5.1.2 packet tracer configure cisco routers for syslog, ntp, and ssh oper...
Positive Hack Days. Pavlov. Network Infrastructure Security Assessment
Install and Configure RSyslog – CentOS 7 / RHEL 7
NetSim Technology Library - Software defined networks
An Express Guide ~ SNMP for Secure Rremote Resource Monitoring
Firewalld : A New Interface to Your Netfilter Stack
PandoraFMS: Free Monitoring System
26.1.7 lab snort and firewall rules
RAC-Installing your First Cluster and Database
Configuration Firewalld On CentOS 8
Smart pos stepbystep-v2-0
Packet Tracer: SNMP, Netflow, Sys-log
Nagios Conference 2013 - Spenser Reinhardt - Intro to Network Monitoring Usin...
Student packet tracer manual v1.1
Nagios Conference 2013 - Troy Lea - Leveraging and Understanding Performance ...
System monitoring
hakin9_6-2006_str22-33_snort_EN
Advanced RAC troubleshooting: Network
Free radius billing server with practical vpn exmaple
Nat mikrotik
2.5.1.2 packet tracer configure cisco routers for syslog, ntp, and ssh oper...

More from VCP Muthukrishna (17)

PDF
How to Fix Duplicate Packages in YUM on CentOS 7
PDF
How To Install and Configure GNome on CentOS 7
PDF
How To Connect to Active Directory User Validation
PDF
How To Connect To Active Directory PowerShell
PDF
How To List Files on Remote Server - PowerShell
PDF
How To List Files and Display In HTML Format
PDF
How To Check and Delete a File via PowerShell
PDF
Zimbra Troubleshooting - Mails not being Delivered or Deferred or Connection ...
PDF
How To Setup SSH Keys on CentOS 7
PDF
How To Install and Configure Open SSH Server on Ubuntu
PDF
Windows PowerShell Basics - How To List PSDrive Info
PDF
How To List Nginx Modules Installed / Complied on CentOS 7
PDF
Windows PowerShell Basics – How To Create powershell for loop
PDF
How To Construct IF and Else Conditional Statements
PDF
How To Create PowerShell Function Mandatory Parameter and Optional Parameter
PDF
How To Create Power Shell Function Mandatory Parameter Value
PDF
How To Create PowerShell Function
How to Fix Duplicate Packages in YUM on CentOS 7
How To Install and Configure GNome on CentOS 7
How To Connect to Active Directory User Validation
How To Connect To Active Directory PowerShell
How To List Files on Remote Server - PowerShell
How To List Files and Display In HTML Format
How To Check and Delete a File via PowerShell
Zimbra Troubleshooting - Mails not being Delivered or Deferred or Connection ...
How To Setup SSH Keys on CentOS 7
How To Install and Configure Open SSH Server on Ubuntu
Windows PowerShell Basics - How To List PSDrive Info
How To List Nginx Modules Installed / Complied on CentOS 7
Windows PowerShell Basics – How To Create powershell for loop
How To Construct IF and Else Conditional Statements
How To Create PowerShell Function Mandatory Parameter and Optional Parameter
How To Create Power Shell Function Mandatory Parameter Value
How To Create PowerShell Function

Recently uploaded (20)

PPTX
Spectroscopy.pptx food analysis technology
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PPTX
sap open course for s4hana steps from ECC to s4
PDF
Network Security Unit 5.pdf for BCA BBA.
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Machine learning based COVID-19 study performance prediction
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Approach and Philosophy of On baking technology
PDF
Empathic Computing: Creating Shared Understanding
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
Spectroscopy.pptx food analysis technology
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
NewMind AI Weekly Chronicles - August'25 Week I
sap open course for s4hana steps from ECC to s4
Network Security Unit 5.pdf for BCA BBA.
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Diabetes mellitus diagnosis method based random forest with bat algorithm
Machine learning based COVID-19 study performance prediction
MYSQL Presentation for SQL database connectivity
Approach and Philosophy of On baking technology
Empathic Computing: Creating Shared Understanding
Dropbox Q2 2025 Financial Results & Investor Presentation
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
Programs and apps: productivity, graphics, security and other tools
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
“AI and Expert System Decision Support & Business Intelligence Systems”
20250228 LYD VKU AI Blended-Learning.pptx

How To Install and Configure SNMP on RHEL 7 or CentOS 7

  • 1. How To Install and Configure SNMP on RHEL 7 i | P a g e Table of Contents Overview.......................................................................................................................................................1 Applies To......................................................................................................................................................1 Pre-Requisites ...............................................................................................................................................1 Installation and Configuration procedure.....................................................................................................1 Check Package...........................................................................................................................................1 Install Package...........................................................................................................................................1 Verify Installation......................................................................................................................................2 SNMP – Configuration File........................................................................................................................2 Default Configuration File – Snippet.....................................................................................................2 Firewall Configuration...................................................................................................................................3 Firewall Configuration – Open UDP Port ..................................................................................................3 Firewall Configuration – Reload................................................................................................................3 Firewall Configuration – List .....................................................................................................................3 snmpwalk – localhost Query.....................................................................................................................4 snmpwalk – Remote Query.......................................................................................................................4 SNMP Configuration .....................................................................................................................................5 Listening address ......................................................................................................................................5 SNMP Daemon Management .......................................................................................................................5 Troubleshooting............................................................................................................................................6 Timeout: No Response from 127.0.0.1.....................................................................................................6 Error Message.......................................................................................................................................6 Cause.....................................................................................................................................................6 Resolution .............................................................................................................................................6 SNMP Version Features ................................................................................................................................7
  • 2. How To Install and Configure SNMP on RHEL 7 1 | P a g e Overview SNMP stands for “Simple Network Management Protocol”, it can be utilized to monitor any devices that support snmp, few of the devices are server, router, network printers, firewalls. SNMP can monitor a variety of parameters for these devices such as server performance, network usage, disk utilization. Applies To Tested on RHEL 7, CentOS 7, though it can be configured on most of the *nix flavor of OS. Pre-Requisites  snmp, snmp-utils Installation and Configuration procedure First of all, we will check if the package is already installed else we will install the packages. Check Package Check if the package is already installed, to check package installation status, run the command; rpm -qa | grep net-snmp net-snmp-utils Install Package After checking the package installation status, if the package is not installed. Install the package to install run the command; yum install net-snmp net-snmp-utils -y
  • 3. How To Install and Configure SNMP on RHEL 7 2 | P a g e Verify Installation After installing the net-snmp packages verify if the package is installed, to check package installation status, run the command; rpm -qa | grep net-snmp* SNMP – Configuration File Default configuration file that is configured as per the below. To display current configuration without comments and lines non-blank lines, run command; grep -v "^$" /etc/snmp/snmpd.conf | grep -v '^ *#' Default Configuration File – Snippet com2sec notConfigUser default public group notConfigGroup v1 notConfigUser group notConfigGroup v2c notConfigUser view systemview included .1.3.6.1.2.1.1 view systemview included .1.3.6.1.2.1.25.1.1 access notConfigGroup "" any noauth exact systemview none none syslocation Unknown (edit /etc/snmp/snmpd.conf) syscontact Root <root@localhost> (configure /etc/snmp/snmp.local.conf) dontLogTCPWrappersConnects yes
  • 4. How To Install and Configure SNMP on RHEL 7 3 | P a g e Firewall Configuration SNMP protocol works on UDP port “161” and this port needs to be opened in order to listen and scan the report from remote servers and for latest version of snmp service supports running on TCP port which is again on “161”. Firewall Configuration – Open UDP Port After installing and checking the default configuration, the next step that needs to be done is to open firewall port, snmp protocol run on UDP port 161. firewall-cmd --permanent --add-port=161/udp Firewall Configuration – Reload Reload the firewall configuration. firewall-cmd --reload Firewall Configuration – List After reloading firewall daemon, list the current rules set. firewall-cmd --list-all
  • 5. How To Install and Configure SNMP on RHEL 7 4 | P a g e snmpwalk – localhost Query After configuring the firewall, you can go ahead and test the snmp query data on the localhost it should be able to retrieve the OID values when you run. To retrieve the information run the command; snmpwalk -v 1 -c public -O e 127.0.0.1 snmpwalk – Remote Query To query from a remote client to retrieve the OID values when you run. To retrieve the information run the command; in this case we are querying from a windows machine. snmpwalk -r:54.165.245.172 -q -c:public
  • 6. How To Install and Configure SNMP on RHEL 7 5 | P a g e SNMP Configuration In order to SNMP to work for any query requests, it should be configured only agentaddress directives is listed and configured, similarly other directives can be configured according to the business needs. Listening address This attribute will associate the IP address wherein the snmp service will listen on. Attribute Name IP Address Information Port agentaddress 127.0.0.1 161 agentaddress IP Address 161 agentaddress 127.0.0.1:161 SNMP Daemon Management State Command Purpose Enable systemctl enable snmpd Enable the service to start at boot and start automatically Start systemctl start snmpd Start the service Stop systemctl stop snmpd Stop the service Restart systemctl restart snmpd Restart the service Disable systemctl disable snmpd Disable the service to start at upon booting Mask systemctl mask snmpd Masking the service to disable dynamic and manual starting.
  • 7. How To Install and Configure SNMP on RHEL 7 6 | P a g e Troubleshooting Timeout: No Response from 127.0.0.1 Error Message Timeout: No Response from 127.0.0.1 Cause One of the cause is the service is not running, start the service. Another cause is when the remote server doesn’t have port is blocked or not listening default port on the client. systemctl status snmpd Resolution To resolve the issue we will start the daemon and query again for the first cause, for the second cause ensure firewall port is configured such that UDP port 161 is opened and listening, check firewall configuration section. systemctl start snmpd
  • 8. How To Install and Configure SNMP on RHEL 7 7 | P a g e SNMP Version Features SNMP has 3 versions currently, that can be configured based on the business needs. The below table will give insight into different versions and its features that provide device statistics. SNMP Version Features Version 1 This provides device statistics and error reporting without consuming a lot of system resources. Security was limited to community strings and access controls based on the IP address of the querying server. Data communication wasn't encrypted. Version 2 This is referred to as v2c which expanded the number of supported error codes, increased the size of counters used to track data, and has the ability to do bulk queries that more efficiently loaded response packets with data Version 3 This version provides greater security and remote configuration capabilities than earlier versions. Access is not only limited to a single community string for read-only and read/write access, as usernames and passwords can also be configured in this version. Support for encrypted SNMP data transfer and transfer error detection is also provided.