Check if MySQL Server is installed:
Rpm-qa | grep MySQL
Rpm-qa | grep mariadb
Delete method:
RPM-E MySQL #普通删除模式
Rpm-e--nodeps MySQL #强行删除模式, if you use the above command to delete, prompted to have other dependent files, then use this command can be forcibly deleted.
Yum Remove mariadb-libs-5.5.41-2.el7_0.x86_64Note that mariadb also cannot exist, some words to delete the tune, delete when there are dependencies, direct yum uninstall before installing MySQL need to install Perl, and need to data:dumped this Perl module, So when installing Perl, you need to install the corresponding module using the following command.yum-y Install Perl-module-install.noarch。 Also need to install Libaio this module, the corresponding command foryum-y Install Libaio libaio-develTo create users and groups:Groupadd MySQL
Useradd mysql-g MySQL
Yum get install: Yum install http://www.percona.com/downloads/percona-release/redhat/0.1-3/percona-release-0.1-3.noarch.rpm viewYum List | grep perconaStart Yum Installation 5.7Yum Install percona-server-server-57After the installation is completeRpm-qa | grep Percona Initialization/usr/bin/mysql_install_db--defaults-file=/etc/my.cnf--basedir=/usr/local/mysql--datadir=/var/lib/mysql-- User=mysqlmysql_install_db--user=mysql--datadir=/data/mysqland lift it up PerconaService MySQL StartService MySQL StatusAfter installing MySQL complete directly:Cat/var/log/mysqld.logFind the initial value password for Percona. After logging in with the initial password, execute the following statement to change the password:SET PASSWORD = PASSWORD (' ****************** ');Then authorizeGrant all privileges on * * to [e-mail protected] "172.16.25.126" identified by "*********";Grant All on * * to [e-mail protected] '% ' identified by ' Your_password ';Flush Privilegesfirewall-cmd--zone=public--add-port=3306/tcp--permanentFirewall-cmd--reloadTo view the running status of MySQL:Service MySQL StatusPS aux |grep mysqld
Percona MySQL 5.7yum Installation