In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-15 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
Linux system version: CentOS7.4
MySQL version: 5.7.28
There are RPM package, binary package and source package 3 in Linux platform. This article mainly takes RPM package as an example to introduce how to install MySQL under Linux platform.
Download address:
Https://cdn.mysql.com//Downloads/MySQL-5.7/mysql-5.7.28-linux-glibc2.12-x86_64.tar.gz
The specific installation steps are as follows:
(1) Uninstall mariadb first, otherwise it will conflict with the libraries needed to install mysql:
[root@localhost ~] # rpm-qa | grep mariadbmariadb-libs-5.5.56-2.el7.x86_64 [root@localhost ~] # rpm-e-nodeps mariadb-libs-5.5.56-2.el7.x86_64
(2) Log in to the system with root users, add mysql users and groups, and install the database under this user:
[root@localhost ~] # groupadd mysql [root@localhost ~] # useradd-r-g mysql-s / bin/false mysql
(3) prepare the data directory
Using / app/data as an example, logical volumes are recommended
[root@localhost ~] # mkdir-p / app/data [root@localhost ~] # chown mysql.mysql / app/data/ [root@localhost ~] # chmod 750 / app/data
(4) prepare binaries:
[root@localhost ~] # tar xvf mysql-5.7.28-linux-glibc2.12-x86_64.tar.gz-C / usr/local/root@localhost ~] # cd / usr/local [root@localhost local] # ln-sv mysql-5.7.28-linux-glibc2.12-x86_64 mysql'mysql'-> 'mysql-5.7.28-linux-glibc2.12-x86_64'
(5) initialize MySQL:
[root@localhost] # cd / usr/local/mysql [root@localhost mysql] # bin/mysqld-- initialize-- user=mysql-- basedir=/usr/local/mysql-- datadir=/app/data2019-11-03T09:47:18.263716Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use-- explicit_defaults_for_timestamp server option (see documentation for more details). 2019-11-03T09:47:19.059462Z 0 [Warning] InnoDB: New log files created, LSN=457902019-11-03T09:47:19.140866Z 0 [Warning] InnoDB: Creating foreign key constraint system tables.2019-11-03T09:47:19.207569Z 0 [Warning] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: ed1cd8ec-fe1e-11e9-8c9c-000c29f8617a.2019-11-03T09:47:19.209181Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.2019-11-03T09:47:19.646366Z 0 [Warning] CA certificate ca.pem is self signed.2019-11-03T09:47:20.056792Z 1 [Note] A temporary password is generated for root@localhost:
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.