Send a link

snmpd

Install snmpd from FreeBSD ports

cd /usr/ports/net-mgmt/net-snmp
make DEFAULT_SNMP_VERSION="2" NET_SNMP_SYS_CONTACT="mail@confighell.com" NET_SNMP_SYS_LOCATION="Confighell" install


Insert into /etc/rc.conf

snmpd_enable="YES"


Configure it by doing

snmpconf -g basic_setup
Do you want to configure the information returned in the system MIB group (contact info, etc)? (default = y): n
Do you want to configure the agent's access control? (default = y): y
Do you want to allow SNMPv3 read-write user based access (default = y): n
Do you want to allow SNMPv3 read-only user based access (default = y): y
Enter the SNMPv3 user that should have read-only access to the system: readuser
The minimum security level required for that user [noauth|auth|priv, default = auth]: noauth
The OID that this community should be restricted to [if appropriate]: <enter> (nothing)
Do another rouser line? (default = y): n
Do you want to allow SNMPv1/v2c read-write community access (default = y): n
Do you want to allow SNMPv1/v2c read-only community access (default = y): y
The community name to add read-only access for: read2user
The hostname or network address to accept this community name from [RETURN for all]: 127.0.0.1
The OID that this community should be restricted to [RETURN for no-restriction]: <enter> (nothing)
Do another rocommunity line? (default = y): n
Do you want to configure where and if the agent will send traps? (default = y): n
Do you want to configure the agent's ability to monitor various aspects of your system? (default = y): y
Do you want to configure the agents ability to monitor processes? (default = y): n
Do you want to configure the agents ability to monitor disk space? (default = y): n
Do you want to configure the agents ability to monitor load average? (default = y): n
Do you want to configure the agents ability to monitor file sizes? (default = y): n
mv snmpd.conf /usr/local/share/snmp/

Or simply echo into config file

echo "rocommunity read2user 127.0.0.1" >> /usr/local/share/snmp/snmpd.conf


Then run the daemon

/usr/local/etc/rc.d/snmpd start



  • + : A leading plus sign indicates that this word must be present in every object returned.
  • - : A leading minus sign indicates that this word must not be present in any row returned.
  • By default (when neither plus nor minus is specified) the word is optional, but the object that contain it will be rated higher.
  • < > : These two operators are used to change a word's contribution to the relevance value that is assigned to a row.
  • ( ) : Parentheses are used to group words into subexpressions.
  • ~ : A leading tilde acts as a negation operator, causing the word's contribution to the object relevance to be negative. It's useful for marking noise words. An object that contains such a word will be rated lower than others, but will not be excluded altogether, as it would be with the - operator.
  • * : An asterisk is the truncation operator. Unlike the other operators, it should be appended to the word, not prepended.
  • " : The phrase, that is enclosed in double quotes ", matches only objects that contain this phrase literally, as it was typed.

Menu