0

I installed WAMP server 3.0.4 in Windows Server 2012. Want to host my site online for the LAN users.

The WAMP components are detailed below:

  • Apache version 2.4.18
  • MySQL version 5.7.11
  • PHP version 5.6.19

The server 2012 is installed on a virtual pc with a static IP address of 10.238.1.60. Right clicked the WAMP icon from the system tray and placed the site online. Made changes to the HTTPD file in the Apache server. Created new rules on the windows firewall to allow TCP traffic on port 80 and UDP traffic on port 443.

When I run http//:10.238.1.60/mysite on the local server I get the correct page displayed but when I run the same address from another pc within the same LAN it gives the forbidden error.

enter image description here

Below is the httpd file from the Apache server.

#
# This is the main Apache HTTP server configuration file.  It contains the
# configuration directives that give the server its instructions.

ServerSignature On
ServerTokens Full

#
# least PidFile.
#
ServerRoot "c:/wamp/bin/apache/apache2.4.18"

Define APACHE24 Apache2.4

# prevent Apache from glomming onto all bound IP addresses.

# Changes were made here 
#the original setting are commented out

#Listen 12.34.56.78:80
#Listen 0.0.0.0:80
#Listen [::0]:80
Listen 10.238.1.60:80

#
#
#
# running httpd, as with most system services.
#
User daemon
Group daemon

</IfModule>

# 'Main' server configuration
#
# The directives in this section set up the values used by the 'main'
# server, which responds to any requests that aren't handled by a
# <VirtualHost> definition.  These values also provide defaults for
# any <VirtualHost> containers you may define later in the file.
#
# All of these directives may appear inside <VirtualHost> containers,
# in which case these default settings will be overridden for the
# virtual host being defined.
#

#
# ServerAdmin: Your address, where problems with the server should be
# e-mailed.  This address appears on some server-generated pages, such
# as error documents.  e.g. admin@your-domain.com
#
ServerAdmin wampserver@otomatic.net

#
# If your host doesn't have a registered DNS name, enter its IP address here.
#Made change here from local host to static ip address
ServerName 10.238.1.60:80

#
# Deny access to the entirety of your server's filesystem. You must
# explicitly permit access to web content directories in other
# <Directory> blocks below.
#
<Directory />
    AllowOverride all
    Require all granted
</Directory>

#
enabled it
# below.
#
HostnameLookups Off

#
locations.
#
DocumentRoot "c:/wamp/www"
<Directory "c:/wamp/www/">
    #
       #
    AllowOverride all

    #
    # Controls who can get stuff from this server.
    #

#   onlineoffline tag - don't remove
    Require all granted
</Directory>

#
# DirectoryIndex: sets the file that Apache will serve if a directory
# is requested.
#
<IfModule dir_module>
    DirectoryIndex index.php index.php3 index.html index.htm
</IfModule>

#
# The following lines prevent .htaccess and .htpasswd files from being
# viewed by Web clients.
#
<Files ".ht*">
    Require all denied
</Files>

#
#
#ErrorLog "logs/error.log"
ErrorLog "c:/wamp/logs/apache_error.log"

#
# LogLevel: Control the number of messages logged to the error_log.
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
#
LogLevel warn

<IfModule log_config_module>
    #
    # The following directives define some format nicknames for use with
    # a CustomLog directive (see below).
    #
    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
    LogFormat "%h %l %u %t \"%r\" %>s %b" common

    <IfModule logio_module>
      # You need to enable mod_logio.c to use %I and %O
      LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
    </IfModule>

    #
 #
#MIMEMagicFile conf/magic

#
#EnableMMAP off
EnableSendfile off

# AcceptFilter: On Windows, none uses accept() rather than AcceptEx() and
# will not recycle sockets between connections. This is useful for network
# adapters with broken driver support, as well as some virtual network
# providers such as vpn drivers, or spam, virus or spyware filters.
AcceptFilter http none
AcceptFilter https none

# Configure mod_proxy_html to understand HTML4/XHTML1
<IfModule proxy_html_module>
Include conf/extra/proxy-html.conf
</IfModule>

#
<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>

Include "c:/wamp/alias/*"

Any suggestions to make this work for me.

A.L
  • 10,259
  • 10
  • 67
  • 98
faisal abdulai
  • 3,739
  • 8
  • 44
  • 66
  • See especially this answer http://stackoverflow.com/a/26326982/101087 – NineBerry Jun 05 '16 at 00:47
  • Also check this answer http://stackoverflow.com/questions/23665064/project-links-do-not-work-on-wamp-server/23990618#23990618 – RiggsFolly Jun 05 '16 at 12:22
  • Also this answer http://stackoverflow.com/questions/37630161/access-wamp-as-web-server-apache-2-4-globally/37630894#37630894 specifically about NOT amending the `` section like you have done – RiggsFolly Jun 05 '16 at 12:24

0 Answers0