数据库连接错误。使用PHP 5.4正确登录信息的Magento 1.7

时间:2013-07-23 18:14:06

标签: php magento fastcgi suphp

尝试连接安装向导时,我得到Database connection error.虽然我能够使用相同的凭据在Codegniter上设置基本用户登录到同一个数据库。所以这应该消除这个共同的假设。还有哪些其他潜在问题?

这是在根目录中,而我们让Magento在同一台服务器上运行正常,在/ magento目录下使用不同的域名。

我已经在网上搜索过了12个小时但没有运气解决这个问题。我们正在使用fastCGI / suPHP并将所有文件权限更改为755/644。

更新... 在以前工作的服务器上从Magento站点测试新的.zip文件时,我发现了同样的问题。可能是他们改变了这些下载和我的问题?我尝试了一个tar文件,现在两个服务器都显示错误......

The page isn't redirecting properly

Firefox has detected that the server is redirecting the request for this address in a way that will never complete.

This problem can sometimes be caused by disabling or refusing to accept
cookies.

所有这些错误,我在测试Magento之前没有经历过,现在尝试将其带入真实世界的服务。我甚至发现什么设置在Apache上运行得最好。

Chrome说......

The webpage at http://www.axxxa.com/magento/index.php/install/ has resulted in too many
redirects. Clearing your cookies for this site or allowing third-party cookies may fix the
problem. If not, it is possibly a server configuration issue and not a problem with your
computer.

IE在分享这些有价值的数据之前已经相当长时间了......

This page can't be displayed

1 个答案:

答案 0 :(得分:1)

您使用localhost作为数据库主机吗?我以前遇到过这个问题,修复方法是使用127.0.0.1代替。

我还会详细检查您的.htaccess文件,因为Firefox上的错误似乎表明您的重写/重定向中存在无限循环。也许尝试禁用.htaccess的mod_rewrite部分。

最后但同样重要的是,我会确保您的数据库表core_config_data中的网址与虚拟主机中的网址相匹配 - 尤其是围绕www或非www。