{"id":83,"date":"2005-11-12T12:30:39","date_gmt":"2005-11-12T01:30:39","guid":{"rendered":""},"modified":"2011-03-20T20:22:45","modified_gmt":"2011-03-20T09:22:45","slug":"cacti-snmp-and-gentoo","status":"publish","type":"post","link":"https:\/\/riscy.biz\/index.php\/2005\/11\/12\/cacti-snmp-and-gentoo\/","title":{"rendered":"Cacti, SNMP and Gentoo"},"content":{"rendered":"<p>Here are the instructions I followed to get SNMP and Cacti working on Gentoo:<\/p>\n<p>emerge cacti cacti-cactid<br \/>groupadd cacti<br \/>useradd -g cacti -G cron cactiuser<\/p>\n<p>cd \/var\/www\/localhost\/htdocs\/cacti\/ <br \/>mysql &#8211;user=root cacti &lt; cacti.sql<br \/>chown -R cactiuser rra\/ log\/ <br \/>mysql<br \/>mysql&gt; create database cactidb;<br \/>mysql&gt; grant all on cactidb.* to root;<br \/>mysql&gt; grant all on cactidb.* to root@localhost;<br \/>mysql&gt; grant all on cactidb.* to cactiuser;<br \/>mysql&gt; grant all on cactidb.* to cactiuser@localhost;<br \/>mysql&gt; set password for cactiuser@localhost=password(&#8216;mycactipw&#8217;);<br \/>mysql&gt; exit <\/p>\n<p>nano config.php<\/p>\n<p>$database_type = &quot;mysql&quot;;<br \/>$database_default = &quot;cacti&quot;;<br \/>$database_hostname = &quot;localhost&quot;;<br \/>$database_username = &quot;cactiuser&quot;;<br \/>$database_password = &quot;mycactipw&quot;; <\/p>\n<p>Now open browser to http:\/\/localhost\/cacti<\/p>\n<p>Follow the steps:<\/p>\n<p>Login as admin password admin<br \/>change password<\/p>\n<p>Back to the command line<\/p>\n<p>crontab -e -u cactiuser<br \/>*\/5 * * * * \/usr\/bin\/php \/var\/www\/localhost\/htdocs\/cacti\/poller.php &gt; \/dev\/null 2&gt;&amp;1<\/p>\n<p>nano -w \/etc\/snmp\/snmpd.conf<\/p>\n<blockquote><p>com2sec local&nbsp;&nbsp;&nbsp;&nbsp; 127.0.0.1\/32&nbsp;&nbsp;&nbsp; public<br \/>com2sec local&nbsp;&nbsp;&nbsp;&nbsp; 10.10.10.0\/24&nbsp;&nbsp; public<\/p>\n<p>group MyROGroup v1&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; local<br \/>group MyROGroup v2c&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; local<br \/>group MyROGroup usm&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; local<\/p>\n<p>view all&nbsp;&nbsp;&nbsp; included&nbsp; .1&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 80<\/p>\n<p>access MyROGroup &quot;&quot;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; any&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; noauth&nbsp;&nbsp;&nbsp; exact&nbsp; all&nbsp;&nbsp;&nbsp; none&nbsp;&nbsp; none<\/p>\n<p>syslocation MyLocation<br \/>syscontact Me &lt;me@somewhere.org&gt;<\/p><\/blockquote>\n<p>\/etc\/init.d\/snmpd start<br \/>rc-update add snmpd default<\/p>\n<p>Should be all good!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Here are the instructions I followed to get SNMP and Cacti working on Gentoo:<\/p>\n<p>emerge cacti cacti-cactid<br \/>groupadd cacti<br \/>useradd -g cacti -G cron cactiuser<\/p>\n<p>cd \/var\/www\/localhost\/htdocs\/cacti\/ <br \/>mysql &#8211;user=root cacti &lt; cacti.sql<br \/>chown -R cactiuser rra\/ log\/ <br \/>mysql<br \/>mysql&gt; create database cactidb;<br \/>mysql&gt; grant all on cactidb.* to root;<br \/>mysql&gt; grant all on cactidb.* to root@localhost;<br \/>mysql&gt; grant all on cactidb.* to cactiuser;<br \/>mysql&gt; grant all on cactidb.* to cactiuser@localhost;<br \/>mysql&gt; set password for cactiuser@localhost=password(&#8216;mycactipw&#8217;);<br \/>mysql&gt; exit <\/p>\n<p>nano config.php<\/p>\n<p>$database_type = &quot;mysql&quot;;<br \/>$database_default = &quot;cacti&quot;;<br \/>$database_hostname = &quot;localhost&quot;;<br \/>$database_username = &quot;cactiuser&quot;;<br \/>$database_password = &quot;mycactipw&quot;; <\/p>\n<p>Now open browser to http:\/\/localhost\/cacti<\/p>\n<p>Follow the steps:<\/p>\n<p>Login as admin password admin<br \/>change password<\/p>\n<p> <a href=\"https:\/\/riscy.biz\/index.php\/2005\/11\/12\/cacti-snmp-and-gentoo\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[1],"tags":[44,5,9,43],"class_list":["post-83","post","type-post","status-publish","format-standard","hentry","category-computers","tag-cacti","tag-gentoo","tag-linux","tag-snmp"],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/riscy.biz\/index.php\/wp-json\/wp\/v2\/posts\/83","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/riscy.biz\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/riscy.biz\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/riscy.biz\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/riscy.biz\/index.php\/wp-json\/wp\/v2\/comments?post=83"}],"version-history":[{"count":0,"href":"https:\/\/riscy.biz\/index.php\/wp-json\/wp\/v2\/posts\/83\/revisions"}],"wp:attachment":[{"href":"https:\/\/riscy.biz\/index.php\/wp-json\/wp\/v2\/media?parent=83"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/riscy.biz\/index.php\/wp-json\/wp\/v2\/categories?post=83"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/riscy.biz\/index.php\/wp-json\/wp\/v2\/tags?post=83"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}