Ubuntu 16.04.7 LTS (GNU/Linux 4.4.0-194-generic x86_64) 安裝mysql 及配置本地登入
1.
sudo apt-get update
2.
sudo apt-get install mysql-server
安裝的時候會提示輸入密碼
3.
mysql -u root -p
檢視程序
ps aux|grep mysqld
更改IP 登入限制
sudo vim /etc/mysql/mysql.conf.d/mysqld.cnf
重新開機服務
sudo service mysql restart
進入mysql 執行
grant all privileges on *.* to 'root'@'%' identified by 'admin' with grant option;
flush privileges;
即可遠端本地登入!
