【发布时间】:2017-06-24 17:35:59
【问题描述】:
我无法在我的服务器中访问 phpmyadmin。我被禁止了。
操作系统版本:Red Hat Enterprise Linux Server release 7.3 (Maipo)
我已经在 stackoverflow 中检查了答案,但是我无法解决我的问题。 我使用命令行安装了 phpmyadmin。 运行 phpmyadmin 版本信息:4.5.4.1
我修改了 /etc/httpd/conf.d/phpMyAdmin.conf 中的值
我的服务器在 Amazon Web Services 免费层上运行。
这是 phpMyAdmin.conf 中的内容
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 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 all
# Allow from 127.0.0.1
# Allow from ::1
# AllowOverride all
# Require all granted
# </IfModule>
</Directory>
<Directory /usr/share/phpMyAdmin/setup/>
<IfModule mod_authz_core.c>
# Apache 2.4
<RequireAny>
Require ip ::1
</RequireAny>
</IfModule>
<IfModule !mod_authz_core.c>
# Apache 2.2
Order Deny,Allow
Deny from All
Allow from ::1
</IfModule>
</Directory>
<Directory /usr/share/phpMyAdmin/libraries/>
Order Deny,Allow
Deny from All
Allow from None
</Directory>
<Directory /usr/share/phpMyAdmin/setup/lib/>
Order Deny,Allow
Deny from All
Allow from None
</Directory>
<Directory /usr/share/phpMyAdmin/setup/frames/>
Order Deny,Allow
Deny from All
Allow from None
</Directory>
【问题讨论】:
-
您必须确保 apache 正在运行,然后才能访问 phpmyadmin。尝试使用日志发布问题,在您的情况下,它可能是 apache-log。这样就可以帮助您找出问题所在,而不是四处寻找。
标签: amazon-web-services amazon-ec2 phpmyadmin rhel