This article shares the MySQL installation and configuration remote login tutorial for your reference. The specific content is as follows 1. Install MySQL 1. Install MySQL 1. sudo apt-get install mysql-server 2. sudo apt-get install mysql-client 3. sudo apt-get install libmysqlclient-dev Note: During the installation process, you will be prompted to set a password and confirm the password. Remember the password. After the installation is complete, you can use the following command to check whether the installation is successful: root@root:/# ps aux|grep mysql mysql 9323 1.4 10.3 1115748 138308 ? Ssl 22:34 0:00 /usr/sbin/mysqld root 9486 0.0 0.0 21312 928 pts/18 S+ 22:34 0:00 grep --color=auto mysql If you see the above results, the installation is successful. You can log in to the MySQL database directly through the following command: The password I set before was: root root@root:/#mysql -uroot -proot -u means to select the login user name. 2. Configure remote login 1. Open the configuration file root@root:/# sudo vim /etc/mysql/mysql.conf.d/mysqld.cnf 2. Modify the configuration file Change bind-address = 127.0.0.1 to 0.0.0.0 or comment it out 3. Add remote access permissions root@root:/#mysql -uroot -proot ->GRANT ALL PRIVILEGES ON *.* TO 'user'@'%' IDENTIFIED BY 'password' WITH GRANT OPTION; ->FLUSH PRIVILEGES; The above user and password can be set to your own 4. Check if it is successful root@root:/# netstat -an | grep 3306 tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN The above results indicate that the setup is successful 5. Restart MySQL root@root:/# service mysql restart 6. Test the connection Find the IP address via ifconfig Test the connection on Navicat The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM. You may also be interested in:
|
<<: How to introduce scss into react project
>>: Vue parent-child component mutual value transfer and call
Official documentation: https://dev.mysql.com/doc...
Hello everyone, I am Liang Xu. As we all know, in...
What is a web page? The page displayed after the ...
0. Preparation: • Close iTunes • Kill the service...
1. Introduction When writing animation effects fo...
Table of contents 1. Introduction 2. Usage Statel...
Table of contents 1. Basic overview of the proces...
Our bank's MGR will be launched at the end of...
Problem Record Today I was going to complete a sm...
1. VMware download and install Link: https://www....
Preface In the process of continuous code deliver...
The figure below shows the browser viewing rate i...
Table of contents 1. Spark vs. Hadoop 1.1 Disadva...
Result: html <canvas id="starfield"&...
I started working on my final project today, but ...