Changeset 14437 for trunk/dports
- Timestamp:
- Oct 6, 2005, 5:02:31 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/dports/net/nedi/Portfile
r14151 r14437 1 # $Id: Portfile,v 1. 1 2005/09/18 23:28:22markd Exp $1 # $Id: Portfile,v 1.2 2005/10/06 05:02:31 markd Exp $ 2 2 3 3 PortSystem 1.0 … … 71 71 ui_msg "\n#### To complete the NeDi OS X installation #### 72 72 73 1) Download Applications 73 1) Re-install MySQL using the +server variant 74 ----------------------------------------------- 75 -Perform these commands 76 sudo port -f uninstall mysql4 77 sudo port clean --all mysql4 78 sudo port install mysql4 +server 79 80 Configure MySQL and set a root password: (for new MySQL installs) 81 sudo -u mysql mysql_install_db 82 sudo chown -R mysql:mysql ${prefix}/var/db/mysql/ 83 sudo chown -R mysql:mysql ${prefix}/var/run/mysqld/ 84 sudo chown -R mysql:mysql ${prefix}/var/log/mysql/ 85 86 sudo ${prefix}/etc/rc.d/mysql4.sh start (or reboot) 87 mysqladmin -u root password <new-password> 88 89 90 2) Download Apache 2 and PHP Binaries 74 91 ------------------------------------------------ 75 -Download Complete Apache 2 , Complete PHP, and Complete MySQL92 -Download Complete Apache 2 and Complete PHP 76 93 http://www.serverlogistics.com/downloads.php 77 94 78 Notes about Apache , PHP, and MySQL95 Notes about Apache and PHP 79 96 ---------------------------------- 80 97 NeDi requires PHP with SNMP support enabled, which is a non-default option 81 and extremely challenging to compile into PHP. Complete PHP is the only 82 PHP binary installer that has it -Complete PHP requires Complete Apache 2. 83 NeDi requires the MySQL 4.0.x series -the easiest way to install that is 84 with Complete MySQL. All this entails using packages from Server Logistics 85 for Apache, PHP, and MySQL in combination to run NeDi. 98 and extremely challenging to compile into PHP. Complete PHP is a binary 99 installed PHP package with SNMP support and it requires Complete Apache 2. 86 100 87 101 88 2) Create an OS X nedi user (or choose an existing one) using the Accounts102 3) Create an OS X NeDi user (or choose an existing one) using the Accounts 89 103 pane in System Preferences 90 104 91 105 92 3) Install Complete Apache 2 (version 2.0.52)106 4) Install Complete Apache 2 (version 2.0.52) 93 107 ------------------------------------------------ 94 108 -Turn off Personal Web Sharing … … 104 118 105 119 106 4) Install Complete PHP 4 (version 4.3.9)120 5) Install Complete PHP 4 (version 4.3.9) 107 121 ------------------------------------------------ 108 122 -Run PHP4.pkg installer 123 -Edit /Library/PHP4/lib/php.ini 124 mysql.default_socket = /opt/local/var/run/mysqld/mysqld.sock 109 125 -Drag test.php to /Library/Apache2/htdocs 110 126 -Start Apache via the Apache 2 System Preferences pane … … 112 128 113 129 114 5) Install Complete MySQL (version 4.0.21) 115 ------------------------------------------------ 116 -Run MySQL.pkg installer 117 -Drag MySQL.prefPane to /Library/PreferencePanes 118 -Add /Library/MySQL/bin to the *front* of your path statement in ~/.bash_profile 119 -Use the MySQL Pane in System Preferences to initialize, set a root password, & start MySQL 120 121 NOTE: 122 A copy of MySQL 4.1.x is installed automatically during the NeDi DarwinPorts 123 install (below) because NeDi requires a MySQL Perl module, the installation 124 of which triggers a DarwinPorts MySQL install. That version won't run if we 125 just ignore it, and we'll do that because NeDi does not work with MySQL 4.1.x. 126 127 128 6) Configure, and Login to NeDi 130 6) Configure NeDi, initialize database, and Login to NeDi 129 131 ----------------------------------------------- 130 132 -Set NeDi owner: sudo chown -R <nedi-user>:<nedi-group> ${prefix}/var/${name}/ 131 133 -Apache symlink: ln -s ${prefix}/var/${name}/html/ /Library/Apache2/htdocs/nedi 132 -MySQL symlink: ln -s /tmp/mysql.sock /opt/local/var/run/mysqld/mysqld.sock133 134 -Edit nedi.conf Backend/Authen. vars: sudo pico ${prefix}/var/${name}/nedi.conf 134 135 Leave nedi.conf permissions at 600 to protect your network passwords! … … 139 140 -Initialize the NeDi database: ${prefix}/var/${name}/nedi.pl -i 140 141 Enter 'root' and the MySQL root password when prompted 142 143 -Verify the NeDi DB: 144 mysql -u root -p 145 mysql> use nedi; 146 mysql> show tables; 147 mysql> exit; 148 141 149 -Login to the NeDi web interface: http://localhost/nedi/index.php 142 150 Initial user/pass is 'admin'/'admin' … … 152 160 153 161 -Make any other desired changes in nedi.conf 154 -Start NeDi data collect.: sudo -u <nedi-user> ${prefix}/var/${name}/nedi.pl -c 155 Use -d for debug output until you know NeDi is running properly. 162 -Start NeDi data collection: 163 cd ${prefix}/var/${name}/nedi.pl 164 sudo -u <nedi-user> nedi.pl -c -d (debug) 156 165 -Put a command in the crontab to discover your network at regular intervals. 157 166 For example, to run NeDi every day at 11:00 and 3:00:
Note: See TracChangeset
for help on using the changeset viewer.