November 6 2017

MYSQL安装mysql8.0.3

安装mysql8.0.3

在官网上下载包以后解压然后安装依赖包
yum -y install gcc gcc-c++ gcc-g77 kernel-devel autoconf automake make cmake perl ncurses-devel libmcrypt* libtool-ltdl-devel* readline-devel pcre-devel openssl-devel openssl
我复制了一个5.7的my.cnf文件,在执行如下安装的时候报了以下的错:

./mysqld –defaults-file=/u01/my3306/my.cnf –initialize –user=mysql –basedir=/u01/mysql8.0 –datadir=/u01/my3306/data/

 

默认取消了query_cache相关的参数。
[ERROR] unknown variable ‘innodb_file_format=Barracuda’
[ERROR] unknown variable ‘log_warnings=1’
[ERROR] unknown variable ‘query_cache_limit=1M’
[ERROR] unknown variable ‘query_cache_type=0’
[ERROR] unknown variable ‘show_compatibility_56=on’

 

和5.7一样的 安装成功以后也是在alert.log里生产问题
2017-11-06T08:11:35.865054Z 5 [Note] A temporary password is generated for root@localhost: /8Kk-gIhJF+H

 

但是在起动的时候又报错了。
有些参数是在安装的时候去检查 有些参数则是在起动的时候才会去检查
2017-11-06 16:15:38 32381 [ERROR] /usr/sbin/mysqld: unknown variable ‘slave-parallel-type=LOGICAL_CLOCK’

可以看出来了多了很多sdi的文件 还有tablespaces 还有undo
$ls
auto.cnf ibdata1 ib_logfile0 ib_logfile2 ibtmp1 mysql_1.sdi performance_sche_3.sdi sys tablespaces.open.1 test undo_001
ib_buffer_pool ibdata2 ib_logfile1 ib_logfile3 mysql mysql.ibd performance_schema sys_4.sdi tablespaces.open.2 test_5.sdi undo_002
打开一个sdi查看可以看出来是json的描述文件
$cat test_5.sdi
{
“mysqld_version_id”: 80003,
“dd_version”: 1,
“sdi_version”: 1,
“dd_object_type”: “Schema”,
“dd_object”: {
“name”: “test”,
“default_collation_id”: 255,
“created”: 0,
“last_altered”: 0
}

进到mysql的文件里 可以看出来和以前的完全不一样

$ls
general_log_195.sdi general_log.CSM general_log.CSV slow_log_196.sdi slow_log.CSM slow_log.CSV

 

5.7版本如下:
[12-MySQL-Inst@db106 /u01/my3313/data/mysql]
$ls
columns_priv.frm event.MYI help_keyword.frm ndb_binlog_index.MYD proxies_priv.MYD slave_worker_info.ibd time_zone_name.frm
columns_priv.MYD func.frm help_keyword.ibd ndb_binlog_index.MYI proxies_priv.MYI slow_log.CSM time_zone_name.ibd
columns_priv.MYI func.MYD help_relation.frm plugin.frm server_cost.frm slow_log.CSV time_zone_transition.frm
db.frm func.MYI help_relation.ibd plugin.ibd server_cost.ibd slow_log.frm time_zone_transition.ibd
db.MYD general_log.CSM help_topic.frm proc.frm servers.frm tables_priv.frm time_zone_transition_type.frm
db.MYI general_log.CSV help_topic.ibd proc.MYD servers.ibd tables_priv.MYD time_zone_transition_type.ibd
db.opt general_log.frm innodb_index_stats.frm proc.MYI slave_master_info.frm tables_priv.MYI user.frm
engine_cost.frm gtid_executed.frm innodb_index_stats.ibd procs_priv.frm slave_master_info.ibd time_zone.frm user.MYD
engine_cost.ibd gtid_executed.ibd innodb_table_stats.frm procs_priv.MYD slave_relay_log_info.frm time_zone.ibd user.MYI
event.frm help_category.frm innodb_table_stats.ibd procs_priv.MYI slave_relay_log_info.ibd time_zone_leap_second.frm
event.MYD help_category.ibd ndb_binlog_index.frm proxies_priv.frm slave_worker_info.frm time_zone_leap_second.ibd

 

 



Copyright 2019. All rights reserved.

Posted 2017年11月6日 by ucjmh in category "mysql

Leave a Reply

Your email address will not be published. Required fields are marked *