为什么无法登录phpMyAdmin但又没有错误提示

Web、Mail、Ftp、DNS、Proxy、VPN、Samba、LDAP 等基础网络服务
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

为什么无法登录phpMyAdmin但又没有错误提示

#1

帖子 linforest » 2014-06-27 14:53

14.04上先后安装了LAMP。PHP Version 5.5.9-1ubuntu4.2
不知道哪里安装或设置不对,能够正常显示欢迎页面http://localhost/phpmyadmin/,但无论采用什么用户名和密码,都无法登录phpMyAdmin。每次输入用户名和密码之后回车或单击进入按钮时,看上去该页面只是刷新了一下,又回到初始状态,什么提示或错误信息都没有。
哪些测试页面(比如包含phpinfo()的php页面)都没问题,就是进不去phpMyAdmin。

请教各位前辈,谢谢!
poloshiao
论坛版主
帖子: 18279
注册时间: 2009-08-04 16:33

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#2

帖子 poloshiao » 2014-06-27 15:57

头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#3

帖子 linforest » 2014-06-27 15:59

谢谢,我先看看这个教程
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#4

帖子 linforest » 2014-06-27 16:04

与PHP版本有关吗?

之前已经在MySQL之中为root用户和另外一个用户授权(包括用户名和密码)

问题依旧:
能够正常显示欢迎页面http://localhost/phpmyadmin/。
但无论采用什么用户名和密码,都无法登录phpMyAdmin。
每次输入用户名和密码之后回车或单击进入按钮时,看上去该页面只是刷新了一下,又回到初始状态,什么提示或错误信息都没有。
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#5

帖子 linforest » 2014-06-27 16:08

在重新启动apache2的时候(sudo /etc/init.d/apache2 restart),出现如下2条错误/提示:
[Fri Jun 27 15:55:22.968368 2014] [alias:warn] [pid 3429] AH00671: The Alias directive in /etc/phpmyadmin/apache.conf at line 7 will probably never match because it overlaps an earlier Alias.
AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message

不知道与当前我的问题是否有关?
谢谢
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#6

帖子 linforest » 2014-06-27 16:12

重新加载apache2时未报错:
sudo /etc/init.d/apache2 reload
poloshiao
论坛版主
帖子: 18279
注册时间: 2009-08-04 16:33

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#7

帖子 poloshiao » 2014-06-27 16:25

之前已经在MySQL之中为root用户和另外一个用户授权(包括用户名和密码)
每次输入用户名和密码之后回车或单击进入按钮时
/etc/phpmyadmin/config.inc.php 是 phpmyadmin 的 主要設定檔
gksudo gedit /etc/phpmyadmin/config.inc.php
進去修改一些預設值
參閱
http://stackoverflow.com/questions/1870 ... s-to-login
apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1.
https://wiki.ubuntu.com/TrustyTahr/Rele ... Networking
In order to improve compatibility with other local nameserver packages, NetworkManager now assigns IP address 127.0.1.1 to the local nameserver process that it controls instead of 127.0.0.1. If the system's /etc/resolv.conf is absent or is a static file instead of the symbolic link to ../run/resolvconf/resolv.conf installed by default then this static file will have to be updated by the administrator in order to continue using the NetworkManager-controlled nameserver.
把 localhost 改為 127.0.1.1
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#8

帖子 linforest » 2014-06-27 16:28

谢谢,我去试试
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#9

帖子 linforest » 2014-06-27 17:36

删除(采用sudo apt-get remove,并不彻底)并重装之后,依然如故。 :em20
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#11

帖子 linforest » 2014-06-27 19:22

重新設定 root 密碼,问题依旧 :em06
谢谢!

补充:
倒是可以访问phpMyAdmin的文档http://localhost/phpmyadmin/doc/html/index.html
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#13

帖子 linforest » 2014-06-27 21:05

很可能需要使用 purge 方式徹底移除已经安装的这些东西啦 :em20
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#14

帖子 linforest » 2014-06-27 21:12

[转]Ubuntu Linux 使用 apt-get 指令移除軟體並清理遺留的垃圾
转自:http://blog.lyhdev.com/2013/01/ubuntu-l ... t-get.html


在 Ubuntu 下移除某個軟體套件,使用的指令是 apt-get remove,例如:

sudo apt-get remove texlive-full

但由於先前安裝此套件,會一併自動安裝相依套件(dependencies),所以需要再用 autoremove 清理。

sudo apt-get autoremove

或是在 remove 時加參數:

sudo apt-get remove --auto-remove

但是這樣還不夠乾淨,因為預設的 remove 行為,會保留一些設定檔之類的遺物。所以需要用 purge 的方式移除。針對單一套件使用 purge 方式徹底移除:

sudo apt-get purge texlive-full



sudo apt-get remove --purge texlive-full

在使用 autoremove 時可以加上 --purge 參數,同時徹底移除套件。

sudo apt-get autoremove --purge

對於先前用 autoremove 或 remove 或其它方式移除,但還沒經過 purge 徹底移除的套件,使用 dpkg 指令可以列出清單:

dpkg -l | grep ^rc

其中 ^rc 代表行首以 rc 標示開頭,這是只有 remove 沒有 purge 的意思。

要批次移除這些被標為 rc 的套件,可以配合 grep + awk 指令。

dpkg -l | grep ^rc | awk '{ print $2 }'

指令組合後即可批次徹底移除這些殘留套件。

sudo apt-get purge `dpkg -l | grep ^rc | awk '{ print $2 }'`

如此,就可以讓系統稍微乾淨一點!
头像
linforest
帖子: 129
注册时间: 2008-12-23 16:38

Re: 为什么无法登录phpMyAdmin但又没有错误提示

#15

帖子 linforest » 2014-06-27 22:00

:em05 :em05 :em05

上述您提供的这个指南 加上 sudo apt-get remove --purge(楼上)

https://help.ubuntu.com/community/ApacheMySQLPHP

终于可以登录pma, 只是/var/www/目录下的测试页面还访问不到(404)


poloshiao,感谢感谢! :em11 :em11 :em11 要不这两天脖子都快断了,一直也没有成功!

:em05 :em05 :em05
回复