Docstoc

Installing the necessary software_ MySQL_ Apache_ PHP

Document Sample
Installing the necessary software_ MySQL_ Apache_ PHP Powered By Docstoc
					File Available: http://www.library.american.edu/staff/bisk/lita2003 Hi-Tech Users and Low-Tech Workflow: Using Open Source Technology to Dynamically Generate and Print PDF Documents from Book Purchase Web Forms Installation Notes

PART A. These steps are outlined only for those who have never installed any of these programs. For those who have previously installed and used Apache/MySQL/PHP, feel free to follow your own installation steps. You only need to make sure that you compile the PDF library into your PHP installation.

Installing the necessary software: MySQL, Apache, PHP

I. Installing MySQL 1. Download a distribution from http://www.mysql.com 2. For a source installation, see “Installing a MySQL Source Distribution” section of INSTALL-SOURCE file. The version of MySQL used for this application is 3.23.54a. You will need to have root privileges on your server. Otherwise, ask your system administrator for help. The following is taken directly from INSTALL-SOURCE file. Please note that you may need to use your Un*x’ variant’s specific commands to create a group mysql and user mysql. On FreeBSD 4.* , use the /stand/sysinstall utility.

Quick Installation Overview for MySQL --------------------------The basic commands you must execute to install a MySQL source distribution are: shell> groupadd mysql shell> useradd -g mysql mysql shell> gunzip < mysql-VERSION.tar.gz | tar -xvf shell> cd mysql-VERSION shell> ./configure --prefix=/usr/local/mysql shell> make shell> make install shell> sh scripts/mysql_install_db shell> chown -R root /usr/local/mysql shell> chown -R mysql /usr/local/mysql/var shell> chgrp -R mysql /usr/local/mysql shell> cp support-files/my-medium.cnf /etc/my.cnf shell> /usr/local/mysql/bin/safe_mysqld --user=mysql & or shell> /usr/local/mysql/bin/mysqld_safe --user=mysql & Evgeny Bisk, Systems Team Leader American University Library Gwendolyn Reece, Web Librarian American University Library

File Available: http://www.library.american.edu/staff/bisk/lita2003 if you are running MySQL 4.x. II. Installing Apache 1. Preinstallation Change into the Apache source directory (e.g. ./usr/local/apache_1.3.28) and run this command: ./configure --prefix=/usr/local/apache This command only creates a layout for the installation. You will need to return to this directory and re-run the configure script (as well as finish the installation) after you have installed PHP and all three libraries PDFlib, TIFF and JPEG) that are required for enabling the pdf functionality in PHP. III. Installing PHP (with PDF library) 1. Download and install PDFlib-Lite (the source version) from http://www.pdflib.com. The new version is 5. Run ./configure, ./make, ./make install. 2. Download and install the JPEG library from ftp://ftp.uu.net/graphics/jpeg/ 3. Download and install the TIFF library from www.libtiff.org or from ftp://ftp.remotesensing.org/pub/libtiff 4. Download the latest version of PHP for your platform from www.php.net. Run ./configure with the following options: --with-apache=/usr/local/apache_1.3.28 --with-mysql=/usr/local/mysql --with-pdflib=/usr/local \ --enable-track-vars --with-zlib --with-gd --with-jpeg-dir=/usr/local --with-tiff-dir=/usr/local/tiff-v3.5.7

PART B. Hardware and Software components of the system and their configuration I. Web server: A. Hardware: Dell PowerEdge 2500, 1.4 Ghz Intel Pentium 4, 512 MB RAM, 4 drives, 3 network interfaces B. Software: Operating system: FreeBSD 4.7 MySQL version: 3.23.54 PHP version: 4.3.3 Apache version: 1.3.28 PDFlib version: 4.0.3 TIFF library version 3.5.7 JPEG library version: 6b Printer is configured through Apsilter, version 7.2.2 (www.apsfilter.org). Below is a partial printcap from the webserver: # APS1_BEGIN:printer1 Evgeny Bisk, Systems Team Leader American University Library Gwendolyn Reece, Web Librarian American University Library

File Available: http://www.library.american.edu/staff/bisk/lita2003 # - don't delete start label for apsfilter printer1 # - no other printer defines between BEGIN and END LABEL maggie|ljet4;r=600x600;q=medium;c=full;p=letter;m=auto:\ :lp=:\ :rm=147.9.xx.xx:\ :rp=maggie:\ :if=/usr/local/etc/apsfilter/basedir/bin/apsfilter:\ :sd=/var/spool/lpd/maggie:\ :lf=/var/spool/lpd/maggie/log:\ :af=/var/spool/lpd/maggie/acct:\ :mx#0:\ :sh: # APS1_END - don't delete this The label :rm denotes the IP address of the remote printserver, which is actually a full-blown FreeBSD server with a local printer attached to it on the parallel port. II. Remote printserver A. Hardware Dell Optiplex Gx100 (small form factor), 433 Mhz Celeron processor, 64MB RAM HP LaserJet 6P B. Software Server operating system: FreeBSD 4.8 Printing software: Apsfilter 7.2.2 Partial printcap file from the printserver: # APS1_BEGIN:printer1 # - don't delete start label for apsfilter printer1 # - no other printer defines between BEGIN and END LABEL maggie|lj5mono;r=600x600;q=medium;c=full;p=letter;m=auto:\ :lp=/dev/lpt0:\ :if=/usr/local/etc/apsfilter/basedir/bin/apsfilter:\ :sd=/var/spool/lpd/maggie:\ :lf=/var/spool/lpd/maggie/log:\ :af=/var/spool/lpd/maggie/acct:\ :mx#0:\ :sh: # APS1_END - don't delete this Note: When using this setup (i.e. a full-blown Un*x system for a print server vs. a built-in printer network interface, e.g. HP JetDirect), it is important to remember that there needs to be a hosts.lpd file on the remote printserver (in the /etc directory). The file should list IP addresses for all hosts that are allowed to send remote print jobs to that server. In our case, since our webserver has 3 network interfaces, they are all listed in that file: Evgeny Bisk, Systems Team Leader American University Library Gwendolyn Reece, Web Librarian American University Library

File Available: http://www.library.american.edu/staff/bisk/lita2003 # $FreeBSD: src/etc/hosts.lpd,v 1.4 1999/08/27 23:23:42 peter Exp $ # # See lpd(8) #machine.domain 147.9.54.69 147.9.aa.dd 147.9.bb.aa

Evgeny Bisk, Systems Team Leader American University Library Gwendolyn Reece, Web Librarian American University Library


				
DOCUMENT INFO
Shared By:
Categories:
Stats:
views:3
posted:1/26/2010
language:English
pages:4