To create a Wamp-like Web Server in Windows7-#1.

Update information      Edit(Aug.11)


   Yesterday, I had the PC which was installed Windows7HP+SP1(x86) as I wrote the article. It is good for me to create a new Wamp-like Web Server.

   First I make two partitions. One for server wares(Drive_SV), another for other files(drive_DC).

   By the way, during creation, Windows Firewall gives alerts several times. At the time, confirm and open required ports. Well, let me get started.

The installation of the Apache HTTP Server.

  1. Download
    It requires VC11. So, I downloaded and installed vcredist_x86.exe.
    Extract the Zip archive.
  2. Customize the httpd.conf file in extracted files (Location:Apache24conf).
      Default Custom
    1 ServerRoot “c:/Apache24” ServerRoot “Drive_SV:/Apache24”
    2 ServerAdmin ServerAdmin My email address
    3 #ServerName ServerName
    4 DocumentRoot “c:/Apache24/htdocs” DocumentRoot “drive_DC:/WEB/htdocs”
    5 <Directory “c:/Apache24/htdocs”> <Directory “drive_DC:/WEB/htdocs”>
    6 Options Indexes FollowSymLinks Options FollowSymLinks
    7 ErrorLog “logs/error.log” ErrorLog “|bin/rotatelogs.exe -l -f logs/error.%Y.%m.%d 86400”
    8 CustomLog “logs/access.log” common # CustomLog “logs/access.log” common
    9 #CustomLog “logs/access.log” combined CustomLog “|bin/rotatelogs.exe -l -f logs/access.%Y.%m.%d 86400” combined
    10 ScriptAlias /cgi-bin/ “c:/Apache24/cgi-bin/” ScriptAlias /cgi-bin/ “drive_DC:/WEB/cgi-bin/”
    11 <Directory “c:/Apache24/cgi-bin”> <Directory “drive_DC:/WEB/cgi-bin”>
    12 Require all granted Require ip Lan IP range (Access control to cgi-bin directory)
    13   ServerTokens Prod
  3. Move the directory Apache24 to Drive_SV.
  4. Run a cmd.exe as an Administrator.
    >cd Drive_SV:Apache24bin
    >httpd.exe -t
    If having error messages, you have to fix them before continuing procedures.

    Install as a Service:
    >httpd.exe -k install
    Make an ApacheMonitor.exe shortcut in the Windows Startup folder. Start Apache.

  5. Move index.html from Apache24/htdocs to drive_DC:WEBhtdocs
    Access from a web browser.
    If you have “It works!”, the installation is complete.
  6. Remove index.html.

   These days, I was in trouble because my Apache sometimes made no response. At that time, I think the error log gave me the message “(OS 64)The specified network name is no longer available. : AH00341: winnt_accept: Asynchronous AcceptEx failed.”, so I added the next lines my httpd.conf. (Ref:AcceptFilter Directive)

<IfModule mpm_winnt_module>
AcceptFilter http none
AcceptFilter https none

Leave a Reply

Your email address will not be published. Required fields are marked *