How To Install snmpd on Ubuntu 20.04

In this tutorial we learn how to install snmpd on Ubuntu 20.04. snmpd is SNMP (Simple Network Management Protocol) agents SNMP (Simple Network Management Protocol) agents

Introduction

In this tutorial we learn how to install snmpd on Ubuntu 20.04.

What is snmpd

snmpd is:

The Simple Network Management Protocol (SNMP) provides a framework for the exchange of management information between agents (servers) and clients.

The Net-SNMP agent is a daemon which listens for incoming SNMP requests from clients and provides responses.

Package: snmpd Architecture: amd64 Version: 5.8+dfsg-2ubuntu2 Priority: optional Section: net Source: net-snmp Origin: Ubuntu Maintainer: Ubuntu Developers [email protected] Original-Maintainer: Net-SNMP Packaging Team [email protected] Bugs: https://bugs.launchpad.net/ubuntu/+filebug Installed-Size: 141 Pre-Depends: init-system-helpers (>= 1.54~) Depends: libc6 (>= 2.4), libsnmp35 (= 5.8+dfsg-2ubuntu2), debconf (>= 0.5) | debconf-2.0, adduser, debconf, lsb-base (>= 3.2-13), libsnmp-base Suggests: snmptrapd Filename: pool/main/n/net-snmp/snmpd_5.8+dfsg-2ubuntu2_amd64.deb Size: 56444 MD5sum: 77384965fb62ab63b93b4540ca3db71d SHA1: b817e36cf7f57797093b847cd4666b3d58e9d178 SHA256: 167faea73f298eaa76b006e477a31b8ff4ed2dbce8435f931c1a08897caf8021 Homepage: http://net-snmp.sourceforge.net/ Description-en: SNMP (Simple Network Management Protocol) agents The Simple Network Management Protocol (SNMP) provides a framework for the exchange of management information between agents (servers) and clients.

The Net-SNMP agent is a daemon which listens for incoming SNMP requests from clients and provides responses.

There are three methods to install snmpd on Ubuntu 20.04. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install snmpd Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install snmpd using apt-get by running the following command:

sudo apt-get -y install snmpd

Install snmpd Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install snmpd using apt by running the following command:

sudo apt -y install snmpd

Install snmpd Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Ubuntu. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install snmpd using aptitude by running the following command:

sudo aptitude -y install snmpd

How To Uninstall snmpd on Ubuntu 20.04

To uninstall only the snmpd package we can use the following command:

sudo apt-get remove snmpd

Uninstall snmpd And Its Dependencies

To uninstall snmpd and its dependencies that are no longer needed by Ubuntu 20.04, we can use the command below:

sudo apt-get -y autoremove snmpd

Remove snmpd Configurations and Data

To remove snmpd configuration and data from Ubuntu 20.04 we can use the following command:

sudo apt-get -y purge snmpd

Remove snmpd configuration, data, and all of its dependencies

We can use the following command to remove snmpd configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge snmpd

References

Summary

In this tutorial we learn how to install snmpd package on Ubuntu 20.04 using different package management tools: apt, apt-get and aptitude.