Skip to content

Instantly share code, notes, and snippets.

@xiaoysh8
Last active January 15, 2019 02:01
Show Gist options
  • Save xiaoysh8/8d6c57e1f976daa50310576ee5b46606 to your computer and use it in GitHub Desktop.
Save xiaoysh8/8d6c57e1f976daa50310576ee5b46606 to your computer and use it in GitHub Desktop.
mysql remote access
1 GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'password' WITH GRANT OPTION;
FLUSH PRIVILEGES;
Out of the box, MySQL will only allow access from the localhost address 127.0.0.1. To change this, you need to open the /etc/mysql/mysql.conf.d/mysqld.cnf file and change the line:
2 bind-address = 127.0.0.1
to
#bind-address = 127.0.0.1
//下载
ssh [email protected] mysqldump -uapi_njges_com -pXr2F7A5JyEJXtmKd api_njges_com | mysql -uroot -psecret green
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment