phpMyAdmin ERROR: mysqli_real_connect(): (HY000/1045): Access denied for user 'pma'@'localhost' (using password: NO)

后端 未结 16 843
谎友^
谎友^ 2020-12-05 00:17

I keep getting the following errors with mysql connection through XAMPP and I don\'t know what to do:

That\'s the code in the config.inc.php



        
16条回答
  •  春和景丽
    2020-12-05 00:46

    I am using UniServer Zero XIV 13.x.x UniController XIV V2.3.1:

    From the command line I did this:

    mysql> CREATE USER 'pmauser'@'%' IDENTIFIED BY 'MyPasswordHere!';
    Query OK, 0 rows affected (0.07 sec)
    
    mysql> GRANT ALL PRIVILEGES ON *.* TO 'pmauser'@'%' WITH GRANT OPTION;
    Query OK, 0 rows affected (0.02 sec)
    

    Then I went to C:\...\wamp\ZeroXIV_unicontroller_2_3_1\UniServerZ\home\us_opt1\config.inc.php and modified the file to have this:

    /* PMA User advanced features */
    //////////$cfg['Servers'][$i]['controluser']    = 'pma';
    //////////$cfg['Servers'][$i]['controlpass']    = $password;
    $cfg['Servers'][$i]['controluser']    = 'pmauser';
    $cfg['Servers'][$i]['controlpass']    = 'MyPasswordHere!';
    

    I restarted Apache and MySQL. The error is gone!

提交回复
热议问题