Enabling SNMPv3 service on SLES
This document (000020702) is provided subject to the disclaimer at the end of this document.
Environment
SUSE Linux Enterprise Server for SAP Applications 15 SP4
SUSE Linux Enterprise Server 15 SP3
SUSE Linux Enterprise Server for SAP Applications 15 SP3
Situation
Resolution
1. If snmpd service is not installed, install the required package:
zypper in net-snmp
2. Create an SNMPv3 user (snmpuser) with read-only permissions:
net-snmp-create-v3-user -ro -a snmpuser_authPass -x snmpuser_privPass -a SHA -X AES snmpuserThe information will be automatically added to the /var/lib/net-snmp/snmpd.conf and /etc/snmp/snmpd.conf configuration files.
Full command usage:
net-snmp-create-v3-user [-ro] [-a authpass] [-x privpass] [-a MD5|SHA] [-X DES|AES] [username] --version displays the net-snmp version number -ro create an user with read-only permissions -a authpass specify authentication password -x privpass specify encryption password -X DES|AES specify encryption algorithm
3. Start the daemon and set it to start on server boot.
systemctl enable --now snmpd.service
4. Test the user using snmpwalk from the localhost:
snmpwalk -u snmpuser -A snmpuser_authPass -a SHA -X snmpuser_privPass -x AES -l authPriv 127.0.0.1 -v3
The command should return information read by SNMP. If not, check the firewall and make sure to open ports 161 for polling, and 162 for notifications.
Additional Information
Disclaimer
This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.
- Document ID:000020702
- Creation Date: 19-Jul-2022
- Modified Date:19-Jul-2022
-
- SUSE Linux Enterprise Server
- SUSE Linux Enterprise Server for SAP Applications
For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com