Welcome to my personal blog website: http://www.yanmin99.com/
centos 6.5 installs mysql 5.6.35-libc.so.6 (GLIBC_2.14) (64bit), libstdc+.so.6 (GLIBCXX_3.4.15) (64bit)
-
1. The reason should be that centos 6 should be el/6 and centos should be the source of el/7.
Error: Package: mysql-community-server-5.6.30-2.el7.i686 (mysql56-community) Requires: systemd Error: Package: mysql-community-server-5.6.30-2.el7.i686 (mysql56-community) Requires: libstdc++.so.6(GLIBCXX_3.4.15) Error: Package: mysql-community-client-5.6.30-2.el7.i686 (mysql56-community) Requires: libc.so.6(GLIBC_2.17) Error: Package: mysql-community-server-5.6.30-2.el7.i686 (mysql56-community) Requires: libc.so.6(GLIBC_2.17) You could try using --skip-broken to work around the problem You could try running: rpm -Va --nofiles --nodigest
-
2. Solutions
-
A. Delete yum remove "mysql56-community-release-el7. *"
yum remove "mysql56-community-release-el7.*"
-
B. Clear cache yum clean all
yum clean all
-
Modify the value of baseurl in mysql56-community
//Before modification # enable to use MySQL 5.6 [mysql56-community] name=MySQL 5.6 Community Server baseurl=http://repo.mysql.com/yum/mysql-5.6-community/el/7/$basearch/ enabled=1 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql //After modification # enable to use MySQL 5.6 [mysql56-community] name=MySQL 5.6 Community Server baseurl=http://repo.mysql.com/yum/mysql-5.6-community/el/6/$basearch/ enabled=1 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
Solving ERROR 1130: Host'xxx'is not allowed to connect to this MySQL server method
-
-
Analysis cause
- This account should not be able to login remotely, so take a look at the access permission settings used by the User table in the mysql library.
-
Scheme 1: Tables modification method
-
1. Login database
mysql -u root -p
-
View the user table in the mysql Library
mysql> use mysql; mysql> select host,user from user; +-----------------------------+------+ | host | user | +-----------------------------+------+ | localhost | root | | 127.0.0.1 | root | | ::1 | root | | node404v.add.bjsc.qihoo.net | root | +-----------------------------+------+
Check to find that root users are only accessible locally
-
Change the host field "localhost" in the User table to "%"
mysql> update user set host = '%' where user = 'root'; mysql> select host,user from user; +-----------------------------+------+ | host | user | +-----------------------------+------+ | % | root | | 127.0.0.1 | root | | ::1 | root | | node404v.add.bjsc.qihoo.net | root | +-----------------------------+------+
-
-
Programme 2: Authorization Law
-
1. If you want myuser to connect to mysql server from any host using mypassword.
GRANT ALL PRIVILEGES ON *.* TO 'myuser'@'%' IDENTIFIED BY 'mypassword' WITH GRANT OPTION;
This is a bit insecure, so it is recommended to specify an ip to access.
-
2. If you want to allow user myuser to connect to mysql server from host with ip 192.168.1.18 and use mypassword as password.
GRANT ALL PRIVILEGES ON *.* TO 'myuser'@'192.168.1.18' IDENTIFIED BY 'mypassword' WITH GRANT OPTION;
-
The operation is as follows:
GRANT ALL PRIVILEGES ON *.* TO 'myuser'@'192.168.1.18' IDENTIFIED BY 'mypassword' WITH GRANT OPTION; Query OK, 0 rows affected (0.23 sec) mysql> select user,host from user ; +-----------------------------+------+ | host | user | +-----------------------------+------+ | 10.255.9.79 | root | | 127.0.0.1 | root | | localhost | root | | ::1 | root | | node404v.add.bjsc.qihoo.net | root |
-