構成定義ファイル(/etc/SnmpAgent.d/snmpd.conf)の提供内容を次に示します。
# Use this file (snmpd.conf) to configure the following SNMP Agent
# parameters. The valid configuration keywords are:
#
# get-community-name:
# set-community-name:
# trap-dest:
# contact:
# location:
#
# get-community-name: <name> IP: <ip_address_list> VIEW: <view_list>
#
# The agent will only respond to get requests using <name> as
# the community name. Embedded blanks are not allowed.
# If a community name is not specified in either this file or
# snmpd.cnf, the agent not respond to any get requests.
# More than one community name can be configured for the agent
# by adding a separate entry for each name to be allowed. For
# example,
#
# get-community-name: secret
#
# restricts access to only those requests using community "secret";
# and,
#
# get-community-name: secret
# get-community-name: private
#
# restricts access to only those requests using either community
# "secret" or "private".
#
# The IP: and VIEW: qualifiers are optional. When either or
# both qualifiers are omitted, the community name is allowed
# for any requesting IP address and provides access the entire
# MIB supported by the agent, respectively.
#
# The IP: qualifier further restricts use of the community name
# to only those requests that originate from one of the listed
# IP addresses. Host names are not supported. For example,
#
# get-community-name: operator IP: 15.2.112.90 15.2.114.101
#
# only allows access using community "operator" from IP address
# 15.2.112.90 or 15.2.114.101.
#
# The VIEW: qualifier further restricts access using the community
# name to the sub-set of the agent's supported MIB identified by
# the space list of "MIB view sub-trees". A view sub-tree may be
# either the object identifier (1.3.6.1.2.1.1) or object name
# (system) of the MIB sub-tree to be included. The '-' character
# may be used to exclude an oid/name from the view. For example,
#
# get-community-name: operator VIEW: 1.3.6.1.2.1 1.3.6.1.4.1.11 -1.3.6.1.2.1.1
#
# allows access using community "operator" to all MIB objects
# under "mib-2" except those objects under "system", plus all
# objects under the "hp" sub-tree.
#
# For example,
#
# get-community-name: operator IP: 15.2.112.90 15.2.114.101 VIEW: 1.3.6.1.2.1 1.3.6.1.4.1
#
# combines the access restrictions described in the previous
# examples for community "operator".
#
# set-community-name: <name> IP: <ip_address_list> VIEW: <view_list>
#
# The agent will only process get or set requests using <name>
# as the community name. Embedded blanks are not allowed.
# If a set community name is not configured in either this file
# or snmpd.cnf, set requests are not allowed by the agent. More
# than one set community name can be configured by adding a
# separate entry for each name to be allowed. For example,
#
# set-community-name: control
#
# enables the agent to process set requests using the community
# name "control".
#
# The IP: and VIEW: qualifiers are optional. They provide the
# same access restrictions for the set community name as descibed
# above for get-community-name. For example,
#
# set-community-name: technician VIEW: system
# set-community-name: administrator IP: 15.2.112.90
#
# allows set request processing using community "technician" to
# only those objects under the "system" group (e.g., sysContact);
# and allows set requests processing on any object using community
# "administrator", but only from IP address 15.2.112.90.
#
# trap-dest: <trap destination>
#
# Specifies the system name where traps will be sent. The system
# name is usually the hostname or IP address of the management
# station. More than one trap destination can be configured by
# by adding a separate entry for each destination. For example,
#
# trap-dest: manager1
# trap-dest: 15.2.113.223
#
# will cause traps to be sent to the systems named "manager1,"
# and "15.2.113.223".
#
# contact: <contact string>
#
# Specifies the value of the MIB-II sysContact object. This
# information usually includes the name of person responsible
# for the agent system, plus information on how to contact this
# person. For example, if Bob Jones is responsible person, and
# his phone number is 555-2000, enter:
#
# contact: Bob Jones (Phone 555-2000)
#
# NOTE: the value specified in this file overrides snmpd.cnf
#
# location: <location string>
#
# Specifies the value of the MIB-II sysLocation object. For
# example, if the agent system is on the first floor near the
# mens room, enter:
#
# location: 1st Floor near Mens Room
#
# NOTE: the value specified in this file overrides snmpd.cnf
#
##
#
get-community-name: public
#set-community-name: # enter community name
#contact: # enter contact person for agent
#location: # enter location of agent
#trap-dest: # enter trap destination