Access mysql remote database from command line

后端 未结 17 1549
忘掉有多难
忘掉有多难 2020-11-28 01:41

I have a server with Rackspace. I want to access the database from my local machine command line.

I tried like:

mysql -u username -h my.application.com         


        
17条回答
  •  时光取名叫无心
    2020-11-28 02:15

    edit my.cnf file:

    vi /etc/my.cnf:

    make sure that:

    bind-address=YOUR-SERVER-IP

    and if you have the line:

    skip-networking

    make sure to comment it:

    #skip-networking

    don't forget to restart:

    /etc/init.d/mysqld restart

提交回复
热议问题