Chinaunix

标题: [问题已解决]安装完phpmyadmin 用浏览器不能访问出错。。好心人帮我看看吧 [打印本页]

作者: 矛盾无奈    时间: 2006-07-28 20:34
标题: [问题已解决]安装完phpmyadmin 用浏览器不能访问出错。。好心人帮我看看吧
出现这个错误;Wrong permissions on configuration file, should not be world writable!
真不知道怎么回事,搞了一天还没弄好.到底哪里出问题了呀.

下面是我的安装方法:
七、phpMyAdmin的安装
1、
cd /usr/ports/databases/phpmyadmin
make install clean
2、
把安装后的phpMyAdmin目录放到apache定义的主目录
3、
进入phpMyAdmin目录
cp ./libraries/config.default.php  复制到phpMyAdmin目录

修改 config.inc.php,第39行:
$cfg['PmaAbsoluteUri'] = '';
改为:
$cfg['PmaAbsoluteUri'] = 'http://172.16.51.1/phpMyAdmin/';

$cfg['Servers'][$i]['auth_type'] = 'config';
改为:
$cfg['Servers'][$i]['auth_type'] = 'http';
4、
编辑/usr/local/etc/apache2/httpd.conf
修改如下内容:
DirectoryIndex 指定预设网页档名
当使用者使用网址「http://www.example.com/dir」连到一个目录中时,如果没有指定网页,Apache 会去查找 DirectoryIndex 中所设定的网页在不在,如果存在则秀出预设的网页。
预设的网页只有二个,我们可以再加上 index.htm、index.php 等常用的网页:
DirectoryIndex index.php index.htm index.html index.html.var

在浏览器上输入http://本机ip/phpMyAdmin/


注:phpMyAdmin2.8系列的使用方法和以前不同了,程序中没有config.inc.php。
有两种安装方法:
1、将./libraries/config.default.php 复制到phpMyAdmin根目录并重命名为config.inc.php,之后按照以前的方法对该文件进行编辑配置即可;
2、在浏览器中运行http://..../phpMyAdmin/scripts/setup.php 以向导模式进行安装(类似Discuz!的安装过程)。
详细的安装帮助参见phpMyAdmin根目录中的Documentation.html文件。

[ 本帖最后由 矛盾无奈 于 2006-7-28 22:26 编辑 ]
作者: 矛盾无奈    时间: 2006-07-28 21:18
好心疼.没人帮.是我的问题太白痴?
作者: zero-B    时间: 2006-07-28 21:34
Wrong permissions on configuration file, should not be world writable
错误的(操作?)配置文件权限,不能写?world writeable不知道怎么翻译好
作者: 矛盾无奈    时间: 2006-07-28 21:37
老大你要救我啊.我把它整个目录都改成777 还是出现这个权限问题.郁闷阿
作者: 江南人    时间: 2006-07-28 21:55
直接下载PHPMYADMIN2.8后解压放到你的网站目录,修改config.default.php,这样试试~~~

$cfg['Servers'][$i]['auth_type']     = 'http';    // Authentication method (config, http or cookie based)?
$cfg['Servers'][$i]['user']          = 'root';      // MySQL user
$cfg['Servers'][$i]['password']      = '你的mysql密码';          // MySQL password (only needed
                                                                                               // with 'config' auth_type)

[ 本帖最后由 江南人 于 2006-7-28 22:10 编辑 ]
作者: 江南人    时间: 2006-07-28 21:57
cp ./libraries/config.default.php  复制到phpMyAdmin目录

修改 config.inc.php,第39行:
$cfg['PmaAbsoluteUri'] = '';
改为:
$cfg['PmaAbsoluteUri'] = 'http://172.16.51.1/phpMyAdmin/';

$cfg['Servers'][$i]['auth_type'] = 'config';
改为:
$cfg['Servers'][$i]['auth_type'] = 'http';
4、
编辑/usr/local/etc/apache2/httpd.conf


cp WHY??
修改的应该是./libraries/config.default.php而不是config.inc.php
作者: 矛盾无奈    时间: 2006-07-28 22:04
我试试直接下载的方法
作者: 矛盾无奈    时间: 2006-07-28 22:24
晕,问题出在ports下载来的phpmyadmin.
大家还是用其他方法安装,不要用PORTS.
作者: 江南人    时间: 2006-07-28 22:39
我用PORTS也可以呀~~~
作者: 矛盾无奈    时间: 2006-07-29 12:51
那就奇怪了,
最后我是从网上直接下载下来,FTP传上去修改一下就OK了
作者: zero-B    时间: 2006-07-29 14:19
汗死,仅工作在php和mysql4.1.x下。。。。
作者: zbhdpx    时间: 2006-07-31 17:39
试试phpMyAdmin-2.7.0-pl2,我也用ports .发觉无法安装,下了个最新版的发觉不能用,(可能是配置问题)
最后我就用这个,解决问题了,
作者: roolg    时间: 2007-05-08 22:28
标题: 回复 1楼 矛盾无奈 的帖子
老帖子阿 ~~~

刚刚也遇到同样的问题~~~~
看到这里权限问题,才想到我对 pma目录做了个 links
把文件权限都改成了  a+w

你只要把所有文件的组和其他用户 w 权限去掉问题就可以解决 ,    《 安全问题》 。。
作者: asmboy001    时间: 2008-02-07 21:14
你把目录权限改为755就ok了,设置为777就会出现问题
作者: niao7409    时间: 2008-02-07 22:18
原帖由 江南人 于 2006-7-28 21:57 发表
cp ./libraries/config.default.php  复制到phpMyAdmin目录

修改 config.inc.php,第39行:
$cfg['PmaAbsoluteUri'] = '';
改为:
$cfg['PmaAbsoluteUri'] = 'http://172.16.51.1/phpMyAdmin/';

$cfg[' ...

我就是用ports装的
改了config.inc.php文件就可以了
作者: yhhdl    时间: 2008-02-09 10:26
标题: 关于虚拟目录的说明
apache22 以后,虚拟目录不能直接该httpd.conf
作者: hy0kl    时间: 2008-04-01 16:46
果然是权限设置的问题!!!




欢迎光临 Chinaunix (http://bbs.chinaunix.net/) Powered by Discuz! X3.2