Oh. forget it. it is not free! tks again regards Peter Kok Below is script for installing apache + php + mysql, it worked before MySQL/PHP3/Apache Installation: By default RedHat will have installed Apache web server on your computer. We will need to remove it before we can continue. If you execute this command rpm -e apache You will probably then get an error that reads: error: removing these packages would break dependencies: webserver is needed by mod_perl-1.21-2 webserver is needed by php-3.0.12-6 If so, we will need to remove those packages too. Use these commands, one at a time, to remove them, followed by removing the Apache web server with the last command: rpm -e mod_perl rpm -e php rpm -e apache Now that we have removed those packages we need to make sure that Apache is not running and that no httpd processes are running. Check it out with this command: ps ax | grep httpd There should be no httpd processes running. If there are, kill them like this, substituting the actual process ID number where you see <pid>: kill -9 <pid> We will be placing all of the packages into the /usr/src directory. Get in there with this command: cd /usr/src Now we'll need to fetch the packages we'll need. We'll start by using the Lynx web browser to get the Apache web server source code. Type this command at the prompt to do so: lynx http://www.apache.org/dist/apache_1.3.9.tar.gz You will need to hit the 'd' when prompted to download it, wait for it to download, then hit [enter] when it asks you if you want to save the file to disk, then hit enter when the line pops up with the file name. You will repeat this process to get the PHP3 source code too by entering this command: lynx http://www.php.net/distributions/php-3.0.14.tar.gz Now we need to uncompress and un-tar the files that we just downloaded into /usr/src using these commands, one at a time, will uncompress the files and you will see lots of stuff scroll up your screen. This is normal. Execute these two commands: tar -zxvf apache_1.3.9.tar.gz tar -zxvf php-3.0.14.tar.gz To make life easier we will make symbolic links to these directories with names that are easier to remember. We'll call them 'apache' and 'php3'. Use these commands, one at a time, to create the links: ln -s /usr/src/apache_1.3.9 apache ln -s /usr/src/php-3.0.14 php3 I usually clean up and remove any unnecessary files, so now that the files have been expanded into their own subdirectories issue this command to remove the gzipped tarball files: rm *.gz Now we will change directories again to where we will be installing MySQL. Use this command: cd /usr/local We will fetch the MySQL binary package the same way we did with Apache and PHP3 using the Lynx web browser. Do so with this command: lynx http://www.mysql.com/Downloads/MySQL-3.22/mysql-3.22.30-pc-linux-gnu-i686.tar.gz You will need to hit the 'd' when prompted to download it, wait for it to download, then hit [enter] when it asks you if you want to save the file to disk, then hit enter when the line pops up with the file name. Now we will need to uncompress and un-tar the MySQL archive we just downloaded. The following command will uncompress the files into their own directory and you will see lots of stuff scroll up your screen. This is normal. tar -zxvf mysql-3.22.30-pc-linux-gnu-i686.tar.gz While we are at it, let's make a symbolic link to this new directory with a friendlier name, we'll call it 'mysql': ln -s /usr/local/mysql-3.22.30-pc-linux-gnu-i686 mysql Next we will need to set the ownership and change the group of the newly created MySQL directories. We will give ownership to the user 'mysql' you created earlier and change the group to 'root'. If you haven't already created a user called 'mysql' on your system, create one now with the following command. Then give it a password with the second command: adduser mysql passwd mysql Once you have a mysql user, proceed with assigning the ownership and group: chown -R mysql mysql-3.22.30-pc-linux-gnu-i686 mysql chgrp -R root mysql-3.22.30-pc-linux-gnu-i686 mysql Now we will need to become the user 'mysql' for a bit. Change to that user with this command: su mysql You will notice that your prompt has changed from a # to a $ sign. Then get into the new mysql directory with this command: cd mysql We will execute the script that sets up MySQL for the first time now like this: scripts/mysql_install_db We no longer need to be the mysql user anymore. Return to the root user by exiting. exit We are going to start the MySQL server up now. First we will need to make the script that does this executable, using the first command. Then we will actually start up MySQL with the second command: chmod 755 /usr/local/mysql/support-files/mysql.server /usr/local/mysql/support-files/mysql.server start You will want to set a password for MySQL now. Do this by typing the following and substituting whatever password you want where you see <password>: /usr/local/mysql/bin/mysqladmin -u root password <password> MySQL should now be installed and running! We will now get into MySQL and set up a test database, a table in that test database, and throw in a record too. YAY. To begin, type the following command and it should prompt you for a password as shown: /usr/local/mysql/bin/mysql -u root -p ~# Enter password: You should now be in the MySQL database and see the following prompt: mysql> Type the following command to create a database called "test_database", then the second command to get into and use the new database. Always use the ; semi-colon after any SQL statements. CREATE DATABASE test_db; USE test_db; Now we will create a table called "test_table", and create some room for data: CREATE TABLE test_table ( first_name varchar(30), last_name varchar(30), phone_number varchar(12)); Now we'll want to throw some data, a record, into our new table within our new database. INSERT INTO test_table VALUES ("John", "Doe", "602-555-1212"); You can use the SQL "SELECT" statement to locate and see data from within a table. The * (asterisk) is a "wild card" that will pull out all of the data. Try this: SELECT * FROM test_table; You should now see the record you just entered show up. Cool, eh? We're done with MySQL for now. You can get out of it by exiting now. exit Now on to setting up PHP3 and the Apache web server. We will return to our source directory like this: cd /usr/src Get into the Apache directory first: cd apache We will run the configuration script and specify an install directory with the "--prefix" command because PHP3 will need to know the location of the Apache config files to compile correctly and work with Apache later on. I chose to install it in /usr/local/apache out of habit. To make this tutorial easier, install yours there too. ./configure --prefix=/usr/local/apache Once the Apache configuration script has run we will change to the PHP3 directory like this: cd ../php3 You are now in the PHP3 directory. First run the configuration script using the following command. The \ character allows you to hit return but still enter more data without starting the script yet. ./configure --with-mysql=/usr/local/mysql \ --with-apache=/usr/src/apache \ --enable-track-vars If all went well with the configuration, hopefully it did, you need to start compiling. We do this with these commands, run one at a time. This may take some time depending on the speed of your machine. On my AMD K6-2 400mhz with 64mb of RAM it was fairly quick and painless. make make install If there were no compiler errors PHP3 should be done and we will move on to configuring and building the Apache web server. Change directories into Apache to begin: cd ../apache We need to first run the configuration script. We are also configuring Apache to load PHP3 as a loadable module. There are cool reasons for this that we won't get into now though. ./configure --prefix=/usr/local/apache \ --activate-module=src/modules/php3/libphp3.a As with PHP3 we will now need to compile and make the Apache web server. Use these commands, one at a time: make make install Hopefully Apache compiled with no problems. If so, we need to copy a PHP3 file with this command: cd ../php3 cp php3.ini-dist /usr/local/lib/php3.ini Next we will make a couple of minor adjustments to the Apache configuration file so that it knows to send any web pages with a .php3 extension to be processed by PHP. Change directories with the first command and get into httpd.conf with the editor of your choice, I used the 'pico' editor for simplicity but you could always use 'vi' or 'emacs' too. Note: The -w switch used below keeps the lines from wrapping when editing the file. cd /usr/local/apache/conf pico -w httpd.conf Now that you are in the httpd.conf file you will want to uncomment the following lines by removing the # (pound sign) from the front of them. You can initiate a search in 'pico' by hitting '<ctrl> w' to easily find where these lines are located in the file: AddType application/x-httpd-php3 .php3 AddType application/x-httpd-php3-source .phps You will probably want to also add 'index.php3' to the list of Index files on this line like so: DirectoryIndex index.html index.php3 Once you've done that hit '<ctrl> x' to save the httpd.conf file. We then want to start up Apache! Use this command to do so: /usr/local/apache/bin/apachectl start >From: "Britt Johnston" <[EMAIL PROTECTED]> >To: "Peter Kok" <[EMAIL PROTECTED]> >Subject: RE: install apache, php + mysql on linux redhat 6.2 >Date: Mon, 4 Jun 2001 09:55:30 -0400 > >You might want to try an integrated solution like NuSphere MySQL, I >would uninstall everything then install the download at www.nusphere.com >and >you will end up with a fully integrated working web server, mysql, perl and >php environment. Please let me know if you give it a try. > >Britt... > >-----Original Message----- >From: Peter Kok [mailto:[EMAIL PROTECTED]] >Sent: Sunday, June 03, 2001 10:42 PM >To: [EMAIL PROTECTED] >Subject: install apache, php + mysql on linux redhat 6.2 > > >Hi all > >I installed the following version on redhat 6.2 but failed on installing >apache finally! >Please teach me > >apache 1.3.19 >php-4.0.5 >mysql-3.23.38-pc-linux-gnu-i686.tar.gz > >mysql can start: /usr/local/mysql/support-files/mysql.server start > >php nothing error: when make and make install >./configure --with-mysql=/usr/local/mysql \ >--with-apache=/usr/src/apache \ >--enable-track-vars > >apache >./configure --prefix=/usr/local/apache \ >--activate-module=src/modules/php4/libphp4.a > >The error is in 'make' >it seems not locate mysqlclient.xxxx > >Thank you > >regards >Peter > > > >--------------------------------------------------------------------- >Before posting, please check: > http://www.mysql.com/manual.php (the manual) > http://lists.mysql.com/ (the list archive) > >To request this thread, e-mail <[EMAIL PROTECTED]> >To unsubscribe, e-mail ><[EMAIL PROTECTED]> >Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php > > _________________________________________________________________________ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php