0

I am trying access remotely the mysql from different machine in my local machine. When i gave the following command mysql -u root -p i got the following error ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES). $cfg['Servers'][$i]['host'] = 'localhost'; This is the code in config.inc.php. Is it so the root user have to grant me the permission for accessing the db remotely?

3
  • 1
    I doubt we can help you with this. Ask the admin to provide access for user root and your password.
    – Rinzwind
    Commented Sep 3, 2019 at 11:17
  • @Rinzwind According to askubuntu.com/a/1171947/250300, this is the solution. Consider posting an answer.
    – Melebius
    Commented Sep 9, 2019 at 12:08
  • Ok I will post this in separate question
    – tweety
    Commented Sep 9, 2019 at 13:48

2 Answers 2

0

You have to do something like mysql -u root -p -h example.com/orIPAddress
There are also chance of mysql root password is not set on remote machine so also in this situation you will not able to connect.
Another way is to create a mysql tunnel as shown in Link but it shows how to dump mysql db but except this you have to just login.

0

I got the username and password for accessing phpmyadmin remotely. But now i got the other problem. Cannot log in to the MySQL server

1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .