[103572] trunk/dports/net/nedi/Portfile
markd at macports.org
markd at macports.org
Fri Mar 1 12:04:25 PST 2013
Revision: 103572
https://trac.macports.org/changeset/103572
Author: markd at macports.org
Date: 2013-03-01 12:04:25 -0800 (Fri, 01 Mar 2013)
Log Message:
-----------
Update notes section only.
Modified Paths:
--------------
trunk/dports/net/nedi/Portfile
Modified: trunk/dports/net/nedi/Portfile
===================================================================
--- trunk/dports/net/nedi/Portfile 2013-03-01 19:38:18 UTC (rev 103571)
+++ trunk/dports/net/nedi/Portfile 2013-03-01 20:04:25 UTC (rev 103572)
@@ -124,42 +124,47 @@
sudo ${prefix}/lib/mysql5/bin/mysqladmin -u root password <mypassword>
-2) Install PHP5 with SNMP support and Apache 2
+2) Install PHP5 with SNMP support and MacPorts Apache
------------------------------------------------
sudo port install php5 +apache2 +mysql5 +snmp
sudo ${prefix}/apache2/bin/apxs -a -e -n \"php5\" libphp5.so
--Check to make sure the PHP variable \"mysql.default_socket\" is set to path
+NOTE: Check to make sure the PHP variable \"mysql.default_socket\" is set to path
${prefix}/var/run/mysql5/mysqld.sock by viewing the output of this terminal command:
php -i
-3) Turn on Apache 2
+3) Turn on MacPorts Apache
------------------------------------------------
--Turn off Apple's Apache 1.3 (Personal Web Sharing in System Preferences). Then execute
- these commands:
-
+-Turn off Apple's built-in Apache (Personal Web Sharing in System Preferences). Then execute
+ these commands:
cd ${prefix}/apache2/conf
sudo cp httpd.conf.sample httpd.conf
- Edit the user/group variables in the Apache 2 httpd.conf to be your selected NeDi user/group.
+-Edit your httpd.conf
+ Change the user/group variables in the Apache httpd.conf to be the Unix user/group that
+ you'll use to run the NeDi executable
- Start Apache 2 and set it to run at system boot:
+ Add an alias statement:
+ Alias /nedi \"/opt/local/share/nedi/html\"
+
+-Start Apache and set it to run at system boot:
sudo launchctl load -w /Library/LaunchdDaemons/org.macports.apache2.plist
-4) Configure NeDi, initialize database, and Login to NeDi
+4) Configure NeDi, initialize NeDi database, and Login to NeDi
-----------------------------------------------
-Set NeDi owner: sudo chown -R <nedi-user>:<nedi-group> ${nedidir}
--Apache symlink: ln -s ${nedidir}/html/ ${prefix}/apache2/htdocs/nedi
+
-Edit nedi.conf Backend/Authen/Device Access sections: sudo pico ${nedidir}/nedi.conf
Leave nedi.conf permissions at 600 to protect your network passwords!
+
backend MSQ
dbpass <nedidb-password>
authuser mysql
-comm <my-commnity-string> (community string of your Cisco devices)
+comm <my-community-string> (community string of your Cisco devices)
<usr> <pass> <enablepass> (user/pass of your Cisco devices)
-Initialize the NeDi database:
@@ -167,17 +172,13 @@
sudo ./nedi.pl -i
When prompted for \"MySQL admin user:\" and enter 'root' and then MySQL root password.
--Set Nedi MySQL user to use old style passwords
- mysql -u root -p
- mysql> SET PASSWORD FOR nedi at localhost = OLD_PASSWORD('<nedidb-pwd>');
-
-Verify the NeDi DB:
mysql -u root -p
mysql> use nedi;
mysql> show tables;
mysql> exit;
--Login to the NeDi web interface: http://localhost/nedi/index.php
+-Login to the NeDi web interface: http://localhost/nedi
Initial user/pass is 'admin'/'admin'
@@ -188,19 +189,19 @@
comm <my-community-string>
<usr> <pass> <enablepass>
-Optionally uncomment the 'cacticli' variable to create Cacti graphs within NeDi
-
-Make any other desired changes in nedi.conf
+
-Start NeDi data collection:
cd ${nedidir}
- sudo -u <nedi-user> nedi.pl -c -d (debug)
+ sudo -u <nedi-user> nedi.pl -pr (options shown set CDPR and routing tables for discovery)
+
-Put a command in the crontab to discover your network at regular intervals.
A typical interval is 1 hour; to get accurate NeDi rrdtool graphs at
NeDi's default settings you must run NeDi at 1 hour intervals.
Otherwise, you must adjust NeDi's default rrdtool settings. To run
NeDi every hour, the cron entry is:
-0 * * * * cd ${nedidir} ; ./nedi.pl -c >> /dev/null 2>&1
+0 * * * * cd ${nedidir} ; ./nedi.pl -pr >> /dev/null 2>&1
6) Set NeDi to receive device alerts, syslogs, and SNMP traps. (optional)
@@ -211,13 +212,4 @@
-To enable the NeDi syslog daemon:
- sudo launchctl load -w /Library/LaunchDaemons/org.macports.nedisyslog.plist
-
--To enable the NeDi SNMP trap receiver, first use the snmpconf Unix utility to create an
- snmptrapd.conf file with the entry:
-
- traphandle default ${nedidir}/trap.pl
-
- Then load the startup script to run the Unix snmptrapd daemon:
-
- sudo load lauchctl load -w /Library/LaunchDaemons/org.macports.snmptrapd.plist"
+ sudo launchctl load -w /Library/LaunchDaemons/org.macports.nedisyslog.plist"
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130301/eca88dd6/attachment.html>
More information about the macports-changes
mailing list