In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-01 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
Environment: Centos8 minimized installation
[root@Oracle2 ~] # cat / etc/redhat-release CentOS Linux release 8.0.1905 (Core)
Note: do not use less than 8 system to compile MySQL8, there will be various errors that the version of each tool is not high enough, which is very troublesome
Mysql version
Mysql-8.0.18
Step 1: install the dependency package
Install rpcgen and download it from here
Https://github.com/thkukuk/rpcsvc-proto/releases
[root@test3 mysql] # wget https://github.com/thkukuk/rpcsvc-proto/releases/download/v1.4/rpcsvc-proto-1.4.tar.gz[root@test3 mysql] # tar-xzf rpcsvc-proto-1.4.tar.gz [root@test3 mysql] # cd rpcsvc-proto-1.4/ [root@test3 rpcsvc-proto-1.4] #. / configure [root@test3 rpcsvc-proto-1.4] # make & & make install
Install additional dependencies
Yum install-y ncurses-devel cmake gcc perl-Data-Dumper gcc-c++ git openssl-devel make
Step 2: download the MySQL to boots source package
Download address: https://dev.mysql.com/downloads/mysql/
Decompress tar-xzf mysql-boost-8.0.18.tar.gzcd mysql-8.0.18/
Step 3: compile and install
Check [root@test3 mysql-8.0.18] # cmake-DCMAKE_INSTALL_PREFIX=/usr/local/mysql-DMYSQL_DATADIR=/data/mysql-DFORCE_INSOURCE_BUILD=1-DWITH_BOOST=boost/ to start compiling and installing [root@test3 mysql-8.0.18] # make-j 4 & & make install
Errors that may exist:
-- Running cmake version 3.11.4-Found Git: / usr/bin/git (found version "2.18.1")-- MySQL 8.0.18CMake Error: CMake was unable to find a build program corresponding to "Unix Makefiles". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool.CMake Error: CMAKE_C_COMPILER not set, after EnableLanguageCMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage-- Configuring incomplete, errors occurred see also "/ root/mysql/mysql-8.0.18/CMakeFiles/CMakeOutput.log".
Solution:
[root@test3 mysql-8.0.18] # yum install-y make
Error report:
Cannot find appropriate system libraries for WITH_SSL=system.Make sure you have specified a supported SSL version. Valid options are: system (use the OS openssl library), yes (synonym for system), * *
Solution:
[root@test3 mysql-8.0.18] # yum install-y openssl-devel
Error report:
-- Checking for module 'libtirpc'-- Package' libtirpc', required by 'virtual:world', not foundCMake Error at cmake/rpc.cmake:65 (MESSAGE): Could not find rpc/rpc.h in/ usr/include or / usr/include/tirpcCall Stack (most recent call first): plugin/group_replication/libmysqlgcs/configure.cmake:57 (MYSQL_CHECK_RPC) plugin/group_replication/libmysqlgcs/CMakeLists.txt:28 (INCLUDE)
Solution:
[root@test3 mysql-8.0.18] # yum install-y libtirpc-devel
Step 4: configure
Create a new data storage directory [root@test3 mysql-8.0.18] # mkdir / data/mysql-p [root@test3 mysql-8.0.18] # chown mysql:mysql / data/mysql/ [root@test3 mysql-8.0.18] # chown mysql:mysql-R / usr/local/mysql/ [root@test3 mysql-8.0.18] # cp support-files/mysql.server / usr/local/sbin/ [root@test3 mysql-8.0.18] # chmod 755 / usr/local/sbin/mysql.server
Generate a configuration file here and put it on / etc/my.cnf
Https://imysql.com/my-cnf-wizard.html
Initialize the database
[root@test3 mysql-8.0.18] # / usr/local/mysql/bin/mysqld-- initialize-- user=mysql launch database [root@test3 mysql-8.0.18] # mysql.server startStarting MySQL... SUCCESS! Configure the environment variable [root@test3 mysql-8.0.18] # echo 'PATH=/usr/local/mysql/bin:$PATH' > > / etc/profile [root@test3 mysql-8.0.18] # source / etc/profile
Step 5: log in
Find the temporary password [root@test3 mysql-8.0.18] # grep password / data/mysql/error.log | grep root2020-01-09T22:18:59.395962+08:00 5 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: MYtoDe (> o6i & modify the temporary root password [root@test3 mysql-8.0.18] # mysqladmin-u root-p password "Re@1dh7at" Enter password: mysqladmin: [Warning] Using a password on the command line Interface can be insecure.Warning: Since password will be sent to server in plain text Use ssl connection to ensure password safety. Log in to [root@test3 mysql-8.0.18] # mysql- pEnter password with root:
Step 6: create a new database and authorize users
Note: Mysql has not been able to put authorization database and new users into one command since 8.0.
New testdb database root@Oracle2 22:30: [(none)] > create database testdb;Query OK, 1 row affected (0.01 sec) create a new testuser user and set password root@Oracle2 22:35: [(none)] > create user testuser@127.0.0.1 identified by 'huH345sfrfs';Query OK, 0 rows affected (0.01 sec) authorize root@Oracle2 22:36: [(none)] > grant all privileges on testdb.* to testuser@127.0.0.1 Query OK, 0 rows affected (0.00 sec)
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.