This post resolves issues relating to the install and setup of a home based web server although for a quick fix (in my opinion) skip to the end of the post here to install XAMPP.
~
Setting up a home web server for development purposes is not something I have done for a while, as everything I do now is web based. I have a couple of larger projects which will have a lot of Database testing so to make life a little easier I thought I would set things up locally. Initially I downloaded the stable releases of Apache 2.2, PHP 5.2 and MySql 5.1 and installed them.
An issue after editing the httpd.conf and adding these lines:
- LoadModule php5_module “c:/php/php5apache2.dll”
- AddType application/x-httpd-php .php
- PHPIniDir “c:/php”
brought into play an error:
c:/Server/Apache/conf/httpd.conf: Cannot load C:/Server/PHP/php5apache2.dll into server: The specified module could not be found.
..although this file is present. I solved this by changing the reference in apache.conf to php5apache2_2.dll. (php-5.1.4-Win32.zip does not provide php5apache2_2.dll you must download php5.2-win32)
~
Not having run through this process for quite a while I didn’t realise WinMySqlAdmin had been removed for which I found a quick result and downloaded it here courtesy of Vincent Graux (thanks Vincent). I’ve also mirrored this here just in case that link goes down. You will also have to download libmysql.dll as this is not included in
If you have reinstalled before reading this then you may get this error when trying to run WinMySqlAdmin:
ThisAccess violation at address 10002593 in Module ‘LIBMYSQL.dll’. Read of address 00000000.
This is caused ny the my.ini file that was left over form the previous install having a password already specified. Go to c:\windows or c:\WINNT and edit the file my.ini changing the last couple of lines to:
user=root
password=
~
MySql GUI may be the better option to save yourself some grief. This is the MySQL GUI Tools Bundle for 5.0. It includes the following products which are also supported for MySQL 5.1.
- MySQL Administrator 1.2
- MySQL Query Browser 1.2
- MySQL Migration Toolkit 1.1
You can download this directly from the Sql website here.
~
This was my solution to the whole mess of trying to get this web server off the ground, you would have though as these three apps worked so closely together that they would dance the tango with a skip or a jump. So I downloaded Xampp 1.7.0 at the time of wrtiting and although not flawless had a ‘working’ web server parsing php pages in less than 5 minutes. It includes the following in a very well packaged installer.
- Apache HTTPD 2.2.11 + Openssl 0.9.8i
- MySQL 5.1.30
- PHP 5.2.8
- phpMyAdmin 3.1.1
- FileZilla FTP Server 0.9.29
- Mercury Mail Transport System 4.52
The only glitch I came across afte the install was Apache wouldn’t install as a service the frst time although it started fine. If you have to reinstall Xampp for any reason or you get this error when trying to start MySql:
ERROR: Myslq service not started [-1]
Remove the MySql folder found in C:\Documents and Settings\All Users\Application Data before you install, it seems this is left behind after the applications have been removed.
One more thing, once you have installed Xampp you will need to set some security settings (you’ll see it on your left hand menu) you may get a ‘FORBIDDEN FOR CLIENT 127.0.01‘ message or something similar. Edit your httpd.conf in the apache/extra folder and change ‘allow localhost‘ to ‘allow 127.0.0.1‘ - this however will not solve the issue if you were using hostname.lan to access your site, make sure you accss the security page by using http://127.0.0.1 and you’ll have no problems.
So after a couple of hours of fiddling with http.conf, libmysql.dll and winmysqladmin, removing files, folders and pulling teeth XAMPP as far as I’m concerned came flying to the rescue.
Well good luck in getting things up and running!
//dev.virtu.al