---
type: Setup Guide
title: "snmpd.conf: The Complete Configuration Guide"
description: "Configure the net-snmp agent — listen address, SNMPv3 or community access, VACM views, system info and traps — in /etc/snmp/snmpd.conf."
resource: "https://snmp-monitoring.info/setup/snmpd-conf/"
tags: [setup]
timestamp: 2026-07-11T00:00:00Z
---

# snmpd.conf: The Complete Configuration Guide

Configure the net-snmp agent — listen address, SNMPv3 or community access, VACM views, system info and traps — in /etc/snmp/snmpd.conf.

## Related concepts

- Up: [SNMP Setup & Configuration: Install, Secure & Test](/setup/index.md)

## Frequently asked questions

### Where is snmpd.conf?

The net-snmp agent's main config is /etc/snmp/snmpd.conf. There's often a second, persistent file at /var/lib/snmp/snmpd.conf where net-snmp stores created v3 users after first start. Distro option files (/etc/default/snmpd, or a sysconfig file on RHEL) control daemon flags like the listen address.

### What is rocommunity?

rocommunity <string> [source] is the quick way to grant SNMPv1/v2c read-only access with a community string, optionally restricted to a source IP or subnet. It's shorthand for the longer com2sec/group/view/access chain. Use a random string, never public, and add a source restriction.

### How do I add a v3 user?

Add createUser <name> SHA "<authpass>" AES "<privpass>" to define the user with authentication and encryption, then rouser <name> priv to grant read-only access at the authenticated-and-encrypted level. Restart snmpd; net-snmp migrates the createUser line into its persistent state on first start.

### How do I restrict which OIDs are readable?

Define a VACM view listing the subtrees you want visible (view name included <oid>), then bind it in an access line. A read-only agent still exposes its whole tree unless you scope it, so an OID allowlist limits what a leaked community or credential can read.

## Source

Concept generated from https://snmp-monitoring.info/setup/snmpd-conf/ — the SNMP Monitoring vendor-neutral knowledge base. Content is limited to what that page states (no external claims added here).
