Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I can`t reach phpmyadmin. I tried all ways what I found in google. Maybe someone can help me? Thanks for any answer.

Forbidden

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

I use CentOS 5 with virtualmin.

phpMyAdmin.conf

# phpMyAdmin - Web based MySQL browser written in php
# 
# Allows only localhost by default
#
# But allowing phpMyAdmin to anyone other than localhost should be considered
# dangerous unless properly secured by SSL

Alias /phpMyAdmin /usr/share/phpMyAdmin
Alias /phpmyadmin /usr/share/phpMyAdmin
<Directory /usr/share/phpMyAdmin/>
   #order deny,allow
   #deny from all
   allow from 127.0.0.1
   allow from ::1
</Directory>

# This directory does not require access over HTTP - taken from the original
# phpMyAdmin upstream tarball
#
<Directory /usr/share/phpMyAdmin/libraries>
    Order Deny,Allow
    Deny from All
    Allow from None
</Directory>

# This configuration prevents mod_security at phpMyAdmin directories from
# filtering SQL etc.  This may break your mod_security implementation.
#
#<IfModule mod_security.c>
#    <Directory /usr/share/phpMyAdmin>
#        SecRuleInheritance Off
#    </Directory>
#</IfModule>

config.inc.php

...
$cfg['Servers'][$i]['auth_type']     = 'http';      // Authentication method (config, http or cookie based)
...
share|improve this question

1 Answer 1

up vote 3 down vote accepted

You are not accessing the phpmyadmin from the 127.0.0.1 or ::1 addresses.

You need to find out what address you are accessing phpmyadmin from and add it to the list of allowed addresses. This will most likely be the public ip address of your server.

e.g. if your public ip address is 192.168.1.54 then you would add it to your configuration

<Directory /usr/share/phpMyAdmin/>
   #order deny,allow
   #deny from all
   allow from 192.168.1.54
   allow from 127.0.0.1
   allow from ::1
</Directory>
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.