0

WampServer Icon is yellow, and my application with a database connexion and use is working perfectly fine, but Apache can't launch and I'll need it to share this same database between differents computers

When I start localhost or localhost/phpmyadmin, the browser give me a "ERROR:CONNEXION_REFUSED". Apache was working perfectly fine before, but I changed the httpd.conf to the lines "Require all denied" to "Require all granted" to allow others computers to connect the database. But it should do the exact opposite of what's it's actually doing. (I'm not using Skype, port 80 is free I tested it, and I noticed that auth.form_module, cache.socache_module have a Warning icon in apache modules)

Thanks for the attention you will grant to my problem, have a nice day

Fenwyr
  • 3
  • 3

1 Answers1

0

There are only two place where the Require all denied syntax exists in the httpd.conf file in WAMPServer and those are :-

<Files ".ht*">
    Require all denied
</Files>

This stops people accessing and .htaccess files and should stay with Require all denied

<Directory />
    AllowOverride none
    Require all denied
</Directory>

This sets the base security for the drive where Apache is installed. It correctly says NOTHING AND NOBODY can access anything on the root of the drive, or any of its subfolders. With Apache you always start by denying all access, then for the specific folders that contain your site, you allow Apache to have access.

Assuming you have not created a Virtual Host for your site, You should and here is how to do it

But assuming you have not, then all you need to do to allow remote access to your site, is tell Apache anyone can access your site. This is simply done using the wampmanager menus :-

wampmanager -> Put Online

This will edit this section of the httpd.conf file

From

#   onlineoffline tag - don't remove
    Require local

To

#   onlineoffline tag - don't remove
    Require all granted

This will allow anyone access, but only to the folder mentioned in the containing <Directory "c:/wamp/www/"> block. Oh and it also automatically restart Apache so it picks up the change

However, there are safer ways of doing this, if you are working in an intranet, which it sounds like you are, manually edit the httpd.conf file again using the wampmanager menus

wampmanager -> Apache -> httpd.conf

Find this section

<Directory "c:/wamp/www/">
    #
    # Possible values for the Options directive are "None", "All",
    # or any combination of:
    #   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
    #
    # Note that "MultiViews" must be named *explicitly* --- "Options All"
    # doesn't give it to you.
    #
    # The Options directive is both complicated and important.  Please see
    # http://httpd.apache.org/docs/2.4/mod/core.html#options
    # for more information.
    #
    Options Indexes FollowSymLinks

    #
    # AllowOverride controls what directives may be placed in .htaccess files.
    # It can be "All", "None", or any combination of the keywords:
    #   AllowOverride FileInfo AuthConfig Limit
    #
    AllowOverride all

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

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

And add this after the Require local like so

#   onlineoffline tag - don't remove
    Require local

# to allow anyone on your subnet to access note only 3 of the 4 quartiles used
    Require ip 192.168.1

# or to be more specific
    Require ip 192.168.1.100
    Require ip 192.168.1.101
    Require ip 192.168.1.102
</Directory>

Finally if you did create a Virtual Host for this project, drop me a comment, and I will add something describing how to do this but just for the one Virtual Host.

Community
  • 1
  • 1
RiggsFolly
  • 93,638
  • 21
  • 103
  • 149
  • First i'd like to thanks you for your quick response that helped me understand the configuration files a little better But actually I can't set wampserver online and he's sending me a error message when i try : "Could not execute menu item (internal error) [Exception] Could not perform service action : Le service n'a pas démarré" (the service didn't start, i'm french) I want to try to reinstall WampServer but my coworkers already began to fill the database, which i can't access anymore to export and save the datas... – Fenwyr Feb 02 '16 at 13:41
  • I'll be back on this network problem because they asked me to add a function (as always :p) so I didn't take the time to fully read about virtual hosts yet – Fenwyr Feb 02 '16 at 13:41
  • The `could not execute menu item` is either you dont have all the required MSVC Runtimes on the PC [See this for help there](http://forum.wampserver.com/read.php?2,134915) Point 20. Or it is because Apache was not started when you clicked a menu item – RiggsFolly Feb 02 '16 at 13:51