phpmyadmin 2002 error

爷,独闯天下 提交于 2020-01-04 02:26:27

问题


I have got this error message:

#2002 - The server is not responding (or the local MySQL server's socket is not correctly configured)

I use Ubuntu 11.10... and Xampp

I used the google, and I saw this solution:

$cfg['Servers'][$i]['socket'] = '/var/run/mysql/mysql.sock'; or $cfg['Servers'][$i]['connect_type'] = 'tcp';

But these lines in the config.inc.php file, don't fix the problem.

Can somebody help me? What else can I do?

I want to learn php :) But there are a lot of problem... Maybe on Windows 7, there isn't this problem?


回答1:


So as you are telling that your are just started with php using ubuntu my advise is to start from scratch, here it's a small guite:

  • Install all you will be needing:

    sudo apt-get install apache2 php5 mysql-server phpmyadmin

  • Once all it's installed you will be using the following directories

    /var/www -- here its where your server stores your pages

    /var/log/apache2/ -- here it's where logs are stored (quite helpful when apache fails,check out the error.log file in that directory)

    /etc/apache2 -- apache configuration lives here

    /etc/php5/cli -- this is where configuration for php5 console live (when you use ~$ php5 test.php the configuration is read from here)

    /etc/php5/apache2 this is where configuration for php5 server live (when you access from a browser like http://localhost/test.php )

The configuration files out of the box dont need to be modified (maybe for more advance uses you will need to modify them)

To uninstall xamp here its a thread might be helful: http://www.apachefriends.org/f/viewtopic.php?p=135389 . First remove xamp and then follow my instructions



来源:https://stackoverflow.com/questions/8842450/phpmyadmin-2002-error

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!