can't access the phpmyadmin
Posted by: cerberus478 (41.177.66.---)
Date: February 12, 2013 08:14PM

Hi

I had to re install windows vista on my computer and I installed wamp but when I try to access the phpmyadmin I get

Forbidden

You don't have permission to access /phpmyadmin/ on this server.

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: RiggsFolly (---.as13285.net)
Date: February 12, 2013 09:19PM

Does it work if you use this address


http://127.0.0.1/phpmyadmin

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: cerberus478 (41.177.66.---)
Date: February 13, 2013 05:52AM

yes it does work with the address

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: RiggsFolly (---.as13285.net)
Date: February 13, 2013 10:17AM

Then this is probably your problem


Right, Windows as of Vista and above comes with the ability to use the IPV4 network address range and the IPV6 network address range and by default they are both turned on.

IPV4 addresses look like this: 123.321.10.234
IPV6 addresses look like this: 2001:0db8:85a3:0042:1000:8a2e:0370:7334

The IPV4 address for localhost is 127.0.0.1
The IPV6 address for localhost is ::1


See
[en.wikipedia.org]
[en.wikipedia.org]
[en.wikipedia.org]


However, Wamp's security as of now ( Feb 2013 ) is only configured to expect the IPV4 address range, but the Apache that is delivered with WAMPServer is aware of both the IPV4 and IPV6 address ranges and is happy to use either or in fact both.
I am not sure how Windows/Browsers decide which range to use but it appears to be fairly arbitrary, so you can get either.

This is the route of your problem.

There are 2 ways you can go to solve this small anomily. You can either ignore the IPV6 address range or change the security to include the IPV6 address range.


+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
KEEP COPIES OF ALL FILES CHANGED SO YOU CAN EASILY UNDO THESE CHANGES IF THEY DO NOT WORK FOR YOU

In fact copy c:\wamp to a backup location and then you can just replace
the whole folder if you have problems with your changes.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++


Option 1 is easier to do.
==============================================================

Option 1:
Ignore the IPV6 address range.


Use the wamp menus to edit these files where possible.

edit httpd.conf
change Listen 80 TO Listen 0.0.0.0:80
The 0.0.0.0 part tells Apache to only listen on IPV4 addresses.


edit c:\windows\system32\drivers\etc\hosts
If it exists, remove or comment out (comment is a # in colum 1) the line containing the IPV6 address for localhost >::1 localhost
(This makes the domain 'localhost' disappear from the IPV6 network, its existance is not hard coded anywhere it has to be mentioned in the hosts file to make it exists)
Make sure you have a line in the hosts file like this >127.0.0.1 localhost
(This makes the domain 'localhost' exists on the IPV4 network)

Wamps security should now work after a reboot. And
http://localhost
should now get you to wamps Apache installation. The exisiting security should also now work for phpMyAdmin,WebGrind and SQLBuddy


============================================================
Option 2:
Add the IPV6 address range to wamps security.


Again always use the wamp menus to edit these files where possible.

!!!! Make sure WAMP is set to 'Offline' before starting this part.


Now this is the dangerous bit!!!!! You must get these next 2 edits right. The text between the double quotes in C:\wamp\scripts\onlineOffline.php must match exactly that used in the httpd.conf file, so a copy and paste would be recommended. If you get this wrong the Online/Offline process will not work.

edit httpd.conf

Change
# onlineoffline tag - don't remove
Order Deny,Allow
Deny from all
Allow from 127.0.0.1

TO
# onlineoffline tag - don't remove
Order Deny,Allow
Deny from all
Allow from 127.0.0.1 ::1

Note we have added the ::1 IPV6 localhost address to the security, make sure there is a space between 127.0.0.1 and ::1.


Edit C:\wamp\scripts\onlineOffline.php
Change

$offlineText = "# onlineoffline tag - don't remove
Order Deny,Allow
Deny from all
Allow from 127.0.0.1";

TO

$offlineText = "# onlineoffline tag - don't remove
Order Deny,Allow
Deny from all
Allow from 127.0.0.1 ::1";

This makes sure that the Online/Offline process still works in WampServer. Make sure that this exactly matches your change above made to httpd.conf


Now edit each of the files
C:\wamp\alias\phpmyadmin.conf
C:\wamp\alias\sqlbuddy.conf
C:\wamp\alias\webgrind.conf

were ever you see >127.0.0.1 change it to >127.0.0.1 ::1
Ignore the lines that start with a #, as these are comment lines

This tells Wamp that whichever ip address from either address range you get for the domain localhost, is allowed to access the apache server.
Now whichever address range windows/browser picks for you when you use the
http://localhost
domain the security will allow you in.

edit c:\windows\system32\drivers\etc\hosts
In Windows8 you will probably see both domains in the file, but this is not guaranteed. When you are finished it should look like this.

127.0.0.1 localhost
::1 localhost

This makes the domain localhost appear on both the IPV4 and IPV6 address ranges.


When you get as far as accessing MySQL you will see that the 'root' user is configured so that it can be accesses from localhost and 127.0.0.1 and ::1 so that is all ready to go and needs no changes.

If you decide to change the password for the 'root' userid in mysql, make sure you use the same password for all the instances of root that exist in mysql. A complete MySQL userid is associated with a location, so it is not the same userid when you login from root@127.0.0.1 as when you login from root@::1. This is why there are 3 'root' userids in the default MySQL userid configiration.

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: cerberus478 (41.177.66.---)
Date: February 13, 2013 07:31PM

Thank you so much RiggsFolly that worked. Thanks a million!!!!!

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: Anil Singh (---.60.146.245.mtnl.net.in)
Date: February 14, 2013 05:43PM

Re: Forbidden You don't have permission to access /phpmyadmin/ on this server.
Posted by: Anil Singh (---.60.146.245.mtnl.net.in)
Date: February 14, 2013 03:48PM

I am not able to access the any of the alias of wamp.

LIKE....phpMyAdmin----->whicl clicking it will show an message

Getting the message while accessing is "Forbidden

You don't have permission to access /phpmyadmin/ on this server."

I am using windows 8.

Help me out !

Anil Singh

anielsingh@hotmail.com



%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

i had try this one

[127.0.0.1]

its working ,know what should i do ..?

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: stevenmartin99 (Moderator)
Date: February 14, 2013 05:52PM

STOP POSTING ALL OVER THE FORUM OR I WILL DELETE YOUR POST 100%

Steven Martin
stevenmartin99@gmail.com
stevenmartin99@hotmail.com
PampServer.com - [pampserver.com]

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: effing (---.static.adinet.com.uy)
Date: February 17, 2013 11:05PM

Ok- i got excited when the suggested url
[127.0.0.1]
worked..

however-- still cannot access localhost

offline i can get to localhost but not myphp.. in online mode cannot access either.

ive done everything riggs suggested- twice--

any help appreciated

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: RiggsFolly (---.ppp.as43234.net)
Date: February 18, 2013 12:08AM

OK install TeamViewer so either I or Steve can connect to your PC and see what is actually going on.

Its free. Once its runnning send me a Private Message with the IS and Password so I can connect.

I am on GMT so I will be available tomorrow as of 09:00 GMT till 16:30 GMT and possibly during the evening as well.

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: effing (---.static.adinet.com.uy)
Date: February 18, 2013 03:39PM

Thank You!! absolutely wonderful.

i will get teamview installed and pm.

it may not be today but i will follow up ASAP

BTW using
[127.0.0.1]
gets me in so i can at least work in the meantime , so , many thanks!

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: Herbalite (---.dynamic.hinet.net)
Date: February 18, 2013 04:39PM

If I may comment on RiggsFolly excellent instructions.

I needed access to phpmyadmin on an intranet.

The only way that seems to work for me, without opening the server to the entire world (as opposed to the suggestiion in phpmyadmin.conf) was to

use the following in phpmyadmin.conf

On all lines where there is => 127.0.0.1

I changed them to => 127.0.0.1 ::1 192.168.0

Where the last 3 number IP is the one used by the router.

Same should work for for the other 2 apps (sqlbuddy, webgrind)

Hope it helps someone else

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: effing (---.static.adinet.com.uy)
Date: February 20, 2013 03:43PM

FYI To ALL

This IS the answer! Although i edited the wrong commands at one point AND there were commands missing from httpd and needed to be added... (operator error)
I found help- Thanks RIGGS!!

FYI to all- remember that reinstalling WAMP doesnt reset HTTPD or other edits we've done previously..

Many thanks to RIGGS and i hope this solves the issue that so so many seek the answer to-



RiggsFolly Wrote:
-------------------------------------------------------
> Then this is probably your problem
>
>
> Right, Windows as of Vista and above comes with
> the ability to use the IPV4 network address range
> and the IPV6 network address range and by default
> they are both turned on.
>
>
> IPV4 addresses look like this: 123.321.10.234
> IPV6 addresses look like this:
> 2001:0db8:85a3:0042:1000:8a2e:0370:7334
>
> The IPV4 address for localhost is 127.0.0.1
> The IPV6 address for localhost is ::1
>
>
> See
> [en.wikipedia.org]
> [en.wikipedia.org]
> [en.wikipedia.org]
>
>
>
> However, Wamp's security as of now ( Feb 2013 ) is
> only configured to expect the IPV4 address range,
> but the Apache that is delivered with WAMPServer
> is aware of both the IPV4 and IPV6 address ranges
> and is happy to use either or in fact both.
> I am not sure how Windows/Browsers decide which
> range to use but it appears to be fairly
> arbitrary, so you can get either.
>
> This is the route of your problem.
>
> There are 2 ways you can go to solve this small
> anomily. You can either ignore the IPV6 address
> range or change the security to include the IPV6
> address range.
>
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++
> +++++++++++++++++++
> KEEP COPIES OF ALL FILES CHANGED SO YOU CAN EASILY
> UNDO THESE CHANGES IF THEY DO NOT WORK FOR YOU
>
> In fact copy c:\wamp to a backup location and then
> you can just replace
> the whole folder if you have problems with your
> changes.
> ++++++++++++++++++++++++++++++++++++++++++++++++++
> ++++++++++++++++++++
>
> Option 1 is easier to do.
> ==================================================
> ============
>
> Option 1:
> Ignore the IPV6 address range.
>
>
> Use the wamp menus to edit these files where
> possible.
>
> edit httpd.conf
> change Listen 80 TO Listen 0.0.0.0:80
> The 0.0.0.0 part tells Apache to only listen on
> IPV4 addresses.
>
>
> edit c:\windows\system32\drivers\etc\hosts
> If it exists, remove or comment out (comment is a
> # in colum 1) the line containing the IPV6 address
> for localhost >::1 localhost
> (This makes the domain 'localhost' disappear from
> the IPV6 network, its existance is not hard coded
> anywhere it has to be mentioned in the hosts file
> to make it exists)
> Make sure you have a line in the hosts file like
> this >127.0.0.1 localhost
> (This makes the domain 'localhost' exists on the
> IPV4 network)
>
> Wamps security should now work after a reboot. And
> [localhost] should now get you to wamps
> Apache installation. The exisiting security should
> also now work for phpMyAdmin,WebGrind and
> SQLBuddy
>
>
> ==================================================
> ==========
> Option 2:
> Add the IPV6 address range to wamps security.
>
> Again always use the wamp menus to edit these
> files where possible.
>
> !!!! Make sure WAMP is set to 'Offline' before
> starting this part.
>
>
> Now this is the dangerous bit!!!!! You must get
> these next 2 edits right. The text between the
> double quotes in C:\wamp\scripts\onlineOffline.php
> must match exactly that used in the httpd.conf
> file, so a copy and paste would be recommended. If
> you get this wrong the Online/Offline process will
> not work.
>
> edit httpd.conf
>
> Change
> # onlineoffline tag - don't remove
> Order Deny,Allow
> Deny from all
> Allow from 127.0.0.1
>
> TO
> # onlineoffline tag - don't remove
> Order Deny,Allow
> Deny from all
> Allow from 127.0.0.1 ::1
>
> Note we have added the ::1 IPV6 localhost address
> to the security, make sure there is a space
> between 127.0.0.1 and ::1.
>
>
> Edit C:\wamp\scripts\onlineOffline.php
> Change
> $offlineText = "# onlineoffline tag - don't
> remove
> Order Deny,Allow
> Deny from all
> Allow from 127.0.0.1";
>
> TO
>
> $offlineText = "# onlineoffline tag - don't
> remove
> Order Deny,Allow
> Deny from all
> Allow from 127.0.0.1 ::1";
>
> This makes sure that the Online/Offline process
> still works in WampServer. Make sure that this
> exactly matches your change above made to
> httpd.conf
>
>
> Now edit each of the files
> C:\wamp\alias\phpmyadmin.conf
> C:\wamp\alias\sqlbuddy.conf
> C:\wamp\alias\webgrind.conf
>
> were ever you see >127.0.0.1 change it to
> >127.0.0.1 ::1
> Ignore the lines that start with a #, as these are
> comment lines
>
> This tells Wamp that whichever ip address from
> either address range you get for the domain
> localhost, is allowed to access the apache
> server.
> Now whichever address range windows/browser picks
> for you when you use the [localhost] domain
> the security will allow you in.
>
> edit c:\windows\system32\drivers\etc\hosts
> In Windows8 you will probably see both domains in
> the file, but this is not guaranteed. When you are
> finished it should look like this.
>
> 127.0.0.1 localhost
> ::1 localhost
>
> This makes the domain localhost appear on both the
> IPV4 and IPV6 address ranges.
>
>
> When you get as far as accessing MySQL you will
> see that the 'root' user is configured so that it
> can be accesses from localhost and 127.0.0.1 and
> ::1 so that is all ready to go and needs no
> changes.
>
> If you decide to change the password for the
> 'root' userid in mysql, make sure you use the same
> password for all the instances of root that exist
> in mysql. A complete MySQL userid is associated
> with a location, so it is not the same userid when
> you login from root@127.0.0.1 as when you login
> from root@::1. This is why there are 3 'root'
> userids in the default MySQL userid configiration.

Options: ReplyQuote
Re: can't access the phpmyadmin
Posted by: dirtyx (---.residential.rdsnet.ro)
Date: February 26, 2013 07:38PM

Thank you RiggsFolly.
Your Option 1 did the trick:

Option 1 is easier to do.
==============================================================

Option 1:
Ignore the IPV6 address range.


Use the wamp menus to edit these files where possible.

edit httpd.conf
change Listen 80 TO Listen 0.0.0.0:80
The 0.0.0.0 part tells Apache to only listen on IPV4 addresses.


edit c:\windows\system32\drivers\etc\hosts
If it exists, remove or comment out (comment is a # in colum 1) the line containing the IPV6 address for localhost >::1 localhost
(This makes the domain 'localhost' disappear from the IPV6 network, its existance is not hard coded anywhere it has to be mentioned in the hosts file to make it exists)
Make sure you have a line in the hosts file like this >127.0.0.1 localhost
(This makes the domain 'localhost' exists on the IPV4 network)

Wamps security should now work after a reboot. And
[localhost]
should now get you to wamps Apache installation. The exisiting security should also now work for phpMyAdmin,WebGrind and SQLBuddy

Options: ReplyQuote


Sorry, only registered users may post in this forum.