installed php5,apache2,LAMP, PHPMyAdmin but if I type my IP and PHPMyAdmin like this it is showing the error
Forbidden
You don't have permission to access /PHPMyAdmin/ on this server.
I edited /etc/httpd/conf.d/phpmyadmin.conf this file also added my IP address and allow to my IP address, still it is showing above error,
my phpmyadmin.conf file is like this now
# 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/>
AddDefaultCharset UTF-8
<IfModule mod_authz_core.c>
# Apache 2.4
<RequireAny>
Require ip 27.34.248.3
#Require ip ::1
</RequireAny>
</IfModule>
<IfModule !mod_authz_core.c>
# Apache 2.2
Order Deny,Allowhow can I access PHPMyAdmin folder, so that I can manage database easily, I'm using Redhat Linux 7.3, all packages are updated!
please help me!
13 Answers
This works. Centos 7.
<Directory /usr/share/phpMyAdmin/> AddDefaultCharset UTF-8 <IfModule mod_authz_core.c> # Apache 2.4 <RequireAny> Require all granted </RequireAny> </IfModule> <IfModule !mod_authz_core.c> # Apache 2.2 Order Deny,Allow Allow from All </IfModule>
</Directory> Try this configuration:
<Directory /usr/share/phpMyAdmin/> AddDefaultCharset UTF-8 <IfModule mod_authz_core.c> # Apache 2.4 <RequireAny> Require ip 127.0.0.1 Require ip ::1 Require ip 27.34.248.3 </RequireAny> </IfModule> <IfModule !mod_authz_core.c> # Apache 2.2 Order Deny,Allow Deny from All Allow from 127.0.0.1 Allow from ::1 Allow from 27.34.248.3 </IfModule> </Directory>Restart the Apache service:
systemctl restart httpd 1 You need to change in apache config file of phpmyadmin
location is /etc/httpd/conf.d/phpMyAdmin.conf
Default Config is:
<Directory /usr/share/phpMyAdmin/> AddDefaultCharset UTF-8 <IfModule mod_authz_core.c> # Apache 2.4 <RequireAny> Require ip 127.0.0.1 Require ip ::1 </RequireAny> </IfModule> <IfModule !mod_authz_core.c> # Apache 2.2 Order Deny,Allow Deny from All Allow from 127.0.0.1 Allow from ::1 </IfModule>
</Directory>Change it to:
<Directory /usr/share/phpMyAdmin/> AddDefaultCharset UTF-8 <IfModule mod_authz_core.c> # Apache 2.4 <RequireAny> Require all granted </RequireAny> </IfModule> <IfModule !mod_authz_core.c> # Apache 2.2 Order Deny,Allow Allow from All </IfModule>
</Directory>and restart apache using command
# service httpd restartOR
# systemctl restart httpd.service 1