Changeset 14437 for trunk/dports


Ignore:
Timestamp:
Oct 6, 2005, 5:02:31 AM (19 years ago)
Author:
markd
Message:

Bug:
Submitted by:
Reviewed by:
Approved by:
Obtained from:

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:22 markd Exp $
     1# $Id: Portfile,v 1.2 2005/10/06 05:02:31 markd Exp $
    22
    33PortSystem      1.0
     
    7171ui_msg "\n#### To complete the NeDi OS X installation ####
    7272
    73 1) Download Applications
     731) 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
     80Configure 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
     902) Download Apache 2 and PHP Binaries
    7491------------------------------------------------
    75 -Download Complete Apache 2, Complete PHP, and Complete MySQL
     92-Download Complete Apache 2 and Complete PHP
    7693        http://www.serverlogistics.com/downloads.php
    7794
    78   Notes about Apache, PHP, and MySQL
     95  Notes about Apache and PHP
    7996  ----------------------------------
    8097  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.
    86100
    87101
    88 2) Create an OS X nedi user (or choose an existing one) using the Accounts
     1023) Create an OS X NeDi user (or choose an existing one) using the Accounts
    89103   pane in System Preferences
    90104
    91105
    92 3) Install Complete Apache 2 (version 2.0.52)
     1064) Install Complete Apache 2 (version 2.0.52)
    93107------------------------------------------------
    94108-Turn off Personal Web Sharing
     
    104118
    105119
    106 4) Install Complete PHP 4 (version 4.3.9)
     1205) Install Complete PHP 4 (version 4.3.9)
    107121------------------------------------------------
    108122-Run PHP4.pkg installer
     123-Edit /Library/PHP4/lib/php.ini
     124        mysql.default_socket = /opt/local/var/run/mysqld/mysqld.sock
    109125-Drag test.php to /Library/Apache2/htdocs
    110126-Start Apache via the Apache 2 System Preferences pane
     
    112128
    113129
    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
     1306) Configure NeDi, initialize database, and Login to NeDi
    129131-----------------------------------------------
    130132-Set NeDi owner: sudo chown -R <nedi-user>:<nedi-group> ${prefix}/var/${name}/
    131133-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.sock
    133134-Edit nedi.conf Backend/Authen. vars: sudo pico ${prefix}/var/${name}/nedi.conf
    134135        Leave nedi.conf permissions at 600 to protect your network passwords!
     
    139140-Initialize the NeDi database: ${prefix}/var/${name}/nedi.pl -i
    140141        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
    141149-Login to the NeDi web interface: http://localhost/nedi/index.php
    142150        Initial user/pass is 'admin'/'admin'
     
    152160
    153161-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)
    156165-Put a command in the crontab to discover your network at regular intervals.
    157166        For example, to run NeDi every day at 11:00 and 3:00:
Note: See TracChangeset for help on using the changeset viewer.