In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article introduces you how to install mariadb in the centos system, the content is very detailed, interested friends can refer to, hope to be helpful to you.
Remove previously installed mariadb
1. Use rpm-qa | grep mariadb to search for existing packages in MariaDB:
If it exists, use rpm-e-- nodeps mariadb-* to delete all:
[root@localhost ~] # rpm-qa | grep mariadbmariadb-server-5.5.52-1.el7.x86_64mariadb-libs-5.5.52-1.el7.x86_64 [root@localhost ~] # rpm-e mysql-* error: software package mysql-* is not installed
two。 Use rpm-qa | grep mariadb to search for existing packages in MariaDB:
If it exists, delete it all using yum remove mysql mysql-server mysql-libs compat-mysql51
[root@localhost ~] # yum remove mysql mysql-server mysql-libs compat-mysql51
Loaded plug-ins: fastestmirror, langpacks
Parameter mysql does not match
Parameter mysql-server does not match
Parameter compat-mysql51 does not match
Resolving dependencies
-- > checking transaction
-> package mariadb-libs.x86_64.1.5.5.52-1.el7 will be deleted
-- > processing dependency libmysqlclient.so.18 () (64bit), which is required by the package perl-DBD-MySQL-4.023-5.el7.x86_64
-- > processing dependency libmysqlclient.so.18 () (64bit), which is required by the package 2:postfix-2.10.1-6.el7.x86_64
Processing dependency libmysqlclient.so.18 () (64bit), which is required by the package 1:qt-mysql-4.8.5-13.el7.x86_64.
Install mariadb
Installation commands:
The copy code is as follows:
Yum-y install mariadb mariadb-server
Start the command:
The copy code is as follows:
Systemctl start mariadb
Add boot boot
The copy code is as follows:
Systemctl enable mariadb
Simple configuration
The copy code is as follows:
Mysql_secure_installation
Enter command line mode
Mysql-uroot-p
Problems encountered
Host is not allowed to connect to this MySQL server
MySQL does not allow remote login, so remote login failed. The solution is as follows:
Log in to the MySQL mysql-u root-p password on the machine with MySQL
Execute use mysql
After executing the sentence update user set host ='% 'where user =' root';, you may report an error, regardless of it.
Execute FLUSH PRIVILEGES
After the above four steps, the problem can be solved.
Note: the fourth step is to refresh the permission-related table of MySQL. Don't forget that I didn't perform step 4 the first time, but I didn't succeed until I finally found this reason.
On how to install mariadb in the centos system to share here, I hope the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.