How to Solve the XAMPP 1.7.7 - PHPMyAdmin - MySQL Error #2002 in Ubuntu

前端 未结 11 2211
逝去的感伤
逝去的感伤 2020-12-05 03:07

I have been through lots of forums and checked various posts on similar topic but non seems to work out for me.

I have freshly installed XAMPP 1.7.7 on my Ubuntu 11

11条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-05 03:38

    Go to config.inc.php file using terminal by typing the following:

    sudo gedit /opt/lampp/phpmyadmin/config.inc.php
    

    The file will open in gedit.

    Now open the file and edit

    $cfg['Servers'][$i]['auth_type'] = 'localhost';
    

    to

    $cfg['Servers'][$i]['auth_type'] = 'cookie';
    

    and keep the username as: root password:

    Also make sure that the lines with username and password are not commented:

    //$cfg['Servers'][$i]['user'] = 'root'; //$cfg['Servers'][$i]['password'] = '';
    

    Make sure that // is removed from the above lines.

提交回复
热议问题