{"id":394,"date":"2014-12-22T22:13:17","date_gmt":"2014-12-22T22:13:17","guid":{"rendered":"http:\/\/eltonoverip.com\/blog\/?p=394"},"modified":"2016-06-20T15:54:41","modified_gmt":"2016-06-20T15:54:41","slug":"snmpd-in-ubuntudebian","status":"publish","type":"post","link":"https:\/\/eltonoverip.com\/blog\/2014\/12\/snmpd-in-ubuntudebian\/","title":{"rendered":"SNMPd in Ubuntu\/Debian"},"content":{"rendered":"<p>Install the SNMP daemon.<\/p>\n<pre>\r\n<code>aptitude install snmpd<\/code>\r\n<\/pre>\n<p><\/p>\n<p>To check which version of SNMP daemon that was installed, run the following<\/p>\n<pre>\r\n<code>aptitude show snmpd<\/code>\r\n<\/pre>\n<p><\/p>\n<p>Make a backup of the original SNMP daemon configuration file.<\/p>\n<pre>\r\n<code>cp \/etc\/snmp\/snmpd.conf \/etc\/snmp\/snmpd.conf_ORIGINAL<\/code>\r\n<\/pre>\n<p><\/p>\n<p>Modify the SNMP daemon configuration file<\/p>\n<pre>\r\n<code>vim \/etc\/snmp\/snmpd.conf<\/code>\r\n<\/pre>\n<p><\/p>\n<p>The above command should also create the same file, if the configuration file does not exist.  Append the following lines.  Adjust the values to the SNMP community string that you use.  This assumes SNMP version 2<\/p>\n<pre>\r\n<code>\r\nrocommunity public\r\nsyslocation \"Your Location\"\r\nsyscontact admin@domain.com\r\n<\/code>\r\n<\/pre>\n<p><\/p>\n<p>Modify the <code>\/etc\/default\/snmpd<\/code> file.  Duplicate the the following line then uncomment it (the original line).  You always want to make a copy of the original line.<\/p>\n<pre>\r\n<code>SNMPDOPTS='-Lsd -Lf \/dev\/null -u snmp -I -smux -p \/var\/run\/snmpd.pid'<\/code>\r\n<\/pre>\n<p><\/p>\n<p>Append the following to the duplicate line.  Basically, point to the SNMP configuration file.<\/p>\n<pre>\r\n<code>-c \/etc\/snmp\/snmpd.conf'<\/code>\r\n<\/pre>\n<p><\/p>\n<p>It should look like the following:<\/p>\n<pre>\r\n<code>SNMPDOPTS='-Lsd -Lf \/dev\/null -u snmp -I -smux -p \/var\/run\/snmpd.pid -c \/etc\/snmp\/snmpd.conf'<\/code>\r\n<\/pre>\n<p><\/p>\n<p>Two ways to restart the snmpd service<\/p>\n<pre>\r\n<code>service restart snmpd<\/code>\r\n<\/pre>\n<p>\nor<\/p>\n<pre>\r\n<code>\/etc\/init.d\/snmpd restart<\/code>\r\n<\/pre>\n<p><\/p>\n<p>While you poll the machine, run this on the server to check the status<\/p>\n<pre>\r\n<code>tcpdump -i eth0 \"src or dst [ip address of SNMP polling server]\"<\/code>\r\n<\/pre>\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Install the SNMP daemon. aptitude install snmpd To check which version of SNMP daemon that was installed, run the following aptitude show snmpd Make a backup of the original SNMP daemon configuration file. cp \/etc\/snmp\/snmpd.conf \/etc\/snmp\/snmpd.conf_ORIGINAL Modify the SNMP daemon configuration file vim \/etc\/snmp\/snmpd.conf The above command should also create the same file, if the [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3,2,18],"tags":[],"class_list":["post-394","post","type-post","status-publish","format-standard","hentry","category-debian","category-linux","category-ubuntu"],"_links":{"self":[{"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/posts\/394","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/comments?post=394"}],"version-history":[{"count":12,"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/posts\/394\/revisions"}],"predecessor-version":[{"id":1100,"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/posts\/394\/revisions\/1100"}],"wp:attachment":[{"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/media?parent=394"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/categories?post=394"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/eltonoverip.com\/blog\/wp-json\/wp\/v2\/tags?post=394"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}