This tutorial shares the installation and configuration methods of MySQL 5.6.33 under Linux for your reference. The specific contents are as follows 1. Download Download address: http://dev.mysql.com/downloads/mysql/5.6.html#downloads Download version: I chose 5.6.33 here, general version, 64-bit under Linux You can also directly copy the 64-bit download address and download it through the command: Copy the code as follows: wget http://dev.mysql.com/get/Downloads/MySQL-5.6/mysql-5.6.33-linux-glibc2.5-x86_64.tar.gz 2. Decompression #Unzip tar -zxvf mysql-5.6.33-linux-glibc2.5-x86_64.tar.gz #Copy the unzipped mysql directory cp -r mysql-5.6.33-linux-glibc2.5-x86_64 /usr/local/mysql 3. Add user groups and users #Add user group groupadd mysql #Add user mysql to user group mysql useradd -g mysql mysql 4. Installation cd /usr/local/mysql/<br>mkdir ./data/mysql chown -R mysql:mysql ./ ./scripts/mysql_install_db --user=mysql --datadir=/usr/local/mysql/data/mysql cp support-files/mysql.server /etc/init.d/mysqld chmod 755 /etc/init.d/mysqld cp support-files/my-default.cnf /etc/my.cnf #Modify the startup script vi /etc/init.d/mysqld #Modifications: basedir=/usr/local/mysql/ datadir=/usr/local/mysql/data/mysql #Start the service service mysqld start #Test connection ./mysql/bin/mysql -uroot #Add environment variables and edit /etc/profile so that you can use mysql commands anywhere export PATH=$PATH:/usr/local/mysql//bin<br>source /etc/profile #Start mysql service mysqld start #Shut down mysql service mysqld stop #View the running status service mysqld status 5. Errors 5.1 When sqlyog connects, error 1130 is reported because the user permissions for the remote connection are not given Solution 1: Change the 'host' entry in the 'user' table of the 'mysql' database from 'localhost' to '%'. use mysql; select 'host' from user where user='root'; update user set host = '%' where user = 'root'; flush privileges; Solution 2: Direct authorization Copy the code as follows: GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'youpassword' WITH GRANT OPTION; 5.2 Some errors during installation -bash: ./scripts/mysql_install_db: /usr/bin/perl: bad interpreter: no such file or directory Solution: yum -y install perl perl-devel Installing MySQL system tables..../bin/mysqld: error while loading shared libraries: libaio.so.1: cannot open shared object file: No such file or directory 6. Others 6.1 Configure environment variables vi + /etc/profile export PATH=....:/usr/local/mysql/bin Wonderful topic sharing: MySQL different versions installation tutorial MySQL 5.6 installation tutorials for various versions MySQL 5.7 installation tutorials for various versions mysql8.0 installation tutorials for various versions 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 lock a virtual console session on Linux
>>: How to achieve 3D dynamic text effect with three.js
Install TomCat on Windows This article will intro...
KILL [CONNECTION | QUERY] processlist_id In MySQL...
What products do you want to mention? Recently, t...
<br />This tag can display a horizontal line...
Table of contents 1.sleep function 2. setTimeout ...
Download and installConfigure environment variabl...
2048 mini game, for your reference, the specific ...
When changing the time zone under Linux, it is al...
First, let’s understand what MySQL is? MySQL is a...
The BGCOLOR attribute can be used to set the back...
Use HTML CSS and JavaScript to implement a simple...
Operating system: Alibaba Cloud ESC instance cent...
1. Apache static resource cross-domain access Fin...
Database transaction isolation level There are 4 ...
This CSS reset is modified based on Eric Meyers...