mysql 5.7.9(GA) 终于发布了,感受一下。

一、下载
下载页面 http://dev.mysql.com/downloads/mysql/
选择相应系统的版本下载。

本文OS为centos6.5 64bit 对应包为mysql-5.7.9-1.el6.x86_64.rpm-bundle

[root@TPCC2 ~]# ll mysql-5.7.9-1.el6.x86_64.rpm-bundle/
total 426792
-rw-r--r--. 1 root root 24134464 Oct 12 21:29 mysql-community-client-5.7.9-1.el6.x86_64.rpm
-rw-r--r--. 1 root root 331912 Oct 12 21:30 mysql-community-common-5.7.9-1.el6.x86_64.rpm
-rw-r--r--. 1 root root 3851928 Oct 12 21:30 mysql-community-devel-5.7.9-1.el6.x86_64.rpm
-rw-r--r--. 1 root root 38081256 Oct 12 21:30 mysql-community-embedded-5.7.9-1.el6.x86_64.rpm
-rw-r--r--. 1 root root 130479844 Oct 12 21:30 mysql-community-embedded-devel-5.7.9-1.el6.x86_64.rpm
-rw-r--r--. 1 root root 2224356 Oct 12 21:31 mysql-community-libs-5.7.9-1.el6.x86_64.rpm
-rw-r--r--. 1 root root 1720248 Oct 12 21:31 mysql-community-libs-compat-5.7.9-1.el6.x86_64.rpm
-rw-r--r--. 1 root root 139636924 Oct 12 21:32 mysql-community-server-5.7.9-1.el6.x86_64.rpm
-rw-r--r--. 1 root root 96549460 Oct 12 21:33 mysql-community-test-5.7.9-1.el6.x86_64.rpm

二、 安装
按照rpm包依赖性,依次安装
[root@localhost mysql-5.7.9-1.el6.x86_64.rpm-bundle]# rpm -ivh mysql-community-common-5.7.9-1.el6.x86_64.rpm
warning: mysql-community-common-5.7.9-1.el6.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
Preparing... ########################################### [100%]
1:mysql-community-common ########################################### [100%]
[root@localhost mysql-5.7.9-1.el6.x86_64.rpm-bundle]# rpm -ivh mysql-community-libs-*
warning: mysql-community-libs-5.7.9-1.el6.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
Preparing... ########################################### [100%]
1:mysql-community-libs ########################################### [ 50%]
2:mysql-community-libs-co########################################### [100%]
[root@localhost mysql-5.7.9-1.el6.x86_64.rpm-bundle]# rpm -ivh mysql-community-client-5.7.9-1.el6.x86_64.rpm
warning: mysql-community-client-5.7.9-1.el6.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
Preparing... ########################################### [100%]
1:mysql-community-client ########################################### [100%]
[root@localhost mysql-5.7.9-1.el6.x86_64.rpm-bundle]# rpm -ivh mysql-community-server-5.7.9-1.el6.x86_64.rpm
warning: mysql-community-server-5.7.9-1.el6.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
Preparing... ########################################### [100%]
1:mysql-community-server ########################################### [100%]
[root@localhost mysql-5.7.9-1.el6.x86_64.rpm-bundle]# rpm -ivh mysql-community-devel-5.7.9-1.el6.x86_64.rpm
warning: mysql-community-devel-5.7.9-1.el6.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
Preparing... ########################################### [100%]
1:mysql-community-devel ########################################### [100%]
三、初始化
1.创建用户和datadir目录
groupadd mysql
useradd -m -d /home/mysql -g mysql mysql

su - mysql
mkdir data

2.初始化my.cnf

[root@TPCC2 ~]# cat /etc/my.cnf
# For advice on how to change settings please see
# http://dev.mysql.com/doc/refman/5.7/en/server-configuration-defaults.html

[mysqld]
#
# Remove leading # and set to the amount of RAM for the most important data
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M
#
# Remove leading # to turn on a very important data integrity option: logging
# changes to the binary log between backups.
# log_bin
#
# Remove leading # to set options mainly useful for reporting servers.
# The server defaults are faster for transactions and fast SELECTs.
# Adjust sizes as needed, experiment to find the optimal values.
# join_buffer_size = 128M
# sort_buffer_size = 2M
# read_rnd_buffer_size = 2M
datadir=/home/mysql/data
socket=/home/mysql/data/mysql.sock

# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0

log-error=/home/mysql/data/mysqld.log
pid-file=/home/mysql/data/mysqld.pid

3.初始化数据库
mysqld --initialize --user=mysql
默认使用/etc/my.cnf

[mysql@localhost data]$ pwd
/home/mysql/data
[mysql@localhost data]$ ll
total 110624
-rw-r-----. 1 mysql mysql 56 Oct 23 12:59 auto.cnf
-rw-r-----. 1 mysql mysql 407 Oct 23 12:59 ib_buffer_pool
-rw-r-----. 1 mysql mysql 12582912 Oct 23 12:59 ibdata1
-rw-r-----. 1 mysql mysql 50331648 Oct 23 12:59 ib_logfile0
-rw-r-----. 1 mysql mysql 50331648 Oct 23 12:59 ib_logfile1
drwxr-x---. 2 mysql mysql 4096 Oct 23 12:59 mysql
-rw-r-----. 1 mysql mysql 991 Oct 23 12:59 mysqld.log
drwxr-x---. 2 mysql mysql 4096 Oct 23 12:59 performance_schema
drwxr-x---. 2 mysql mysql 12288 Oct 23 12:59 sys

4.临时密码
查找初始用户、密码

[mysql@localhost data]$ grep "A temporary password" mysqld.log
2015-10-23T04:59:09.504285Z 1 [Note] A temporary password is generated for root@localhost: BdwK<Crzy08g

四、启动

[mysql@localhost ~]$ mysqld_safe --user=mysql &
[1] 11255
[mysql@localhost ~]$ 151023 13:01:37 mysqld_safe Logging to '/home/mysql/data/mysqld.log'.
151023 13:01:37 mysqld_safe Starting mysqld daemon with databases from /home/mysql/data

[mysql@localhost data]$ tail -f mysqld.log
2015-10-23T05:01:38.114718Z 0 [Note] Plugin 'FEDERATED' is disabled.
2015-10-23T05:01:38.116051Z 0 [Note] InnoDB: Buffer pool(s) load completed at 151023 13:01:38
2015-10-23T05:01:38.118122Z 0 [Warning] Failed to set up SSL because of the following SSL library error: SSL context is not usable without certificate and private key
2015-10-23T05:01:38.118780Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
2015-10-23T05:01:38.127582Z 0 [Note] IPv6 is available.
2015-10-23T05:01:38.127598Z 0 [Note] - '::' resolves to '::';
2015-10-23T05:01:38.127607Z 0 [Note] Server socket created on IP: '::'.
2015-10-23T05:01:38.143935Z 0 [Note] Event Scheduler: Loaded 0 events
2015-10-23T05:01:38.144134Z 0 [Note] /usr/sbin/mysqld: ready for connections.
Version: '5.7.9' socket: '/home/mysql/data/mysql.sock' port: 3306 MySQL Community Server (GPL)

五、登陆并修改临时密码

[mysql@TPCC2 ~]$ mysql -u root -h localhost -p -S /home/mysql/data/mysql.sock
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 3
Server version: 5.7.9

Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> ? set password
ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.
mysql> ? alter suer
ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.
mysql> ? alter user
ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.
mysql> alter user 'root'@'localhost' identified by 'mysql';
Query OK, 0 rows affected (0.00 sec)

mysql> flush privileges;
Query OK, 0 rows affected (0.01 sec)

mysql> exit
Bye

六、测试
1.新密码登陆
[mysql@localhost ~]$ mysql -u root -h localhost -S /home/mysql/data/mysql.sock -pmysql
mysql: [Warning] Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 5
Server version: 5.7.9 MySQL Community Server (GPL)

Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| mysql |
| performance_schema |
| sys |
+--------------------+
4 rows in set (0.00 sec)
2.查看sys库
mysql> use sys
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed
mysql> show tables;
+-----------------------------------------------+
| Tables_in_sys |
+-----------------------------------------------+
| host_summary |
| host_summary_by_file_io |
| host_summary_by_file_io_type |
| host_summary_by_stages |
| host_summary_by_statement_latency |
| host_summary_by_statement_type |
| innodb_buffer_stats_by_schema |
| innodb_buffer_stats_by_table |
| innodb_lock_waits |
| io_by_thread_by_latency |
| io_global_by_file_by_bytes |
| io_global_by_file_by_latency |
| io_global_by_wait_by_bytes |
| io_global_by_wait_by_latency |
| latest_file_io |
| memory_by_host_by_current_bytes |
| memory_by_thread_by_current_bytes |
| memory_by_user_by_current_bytes |
| memory_global_by_current_bytes |
| memory_global_total |
| metrics |
| processlist |
| ps_check_lost_instrumentation |
| schema_auto_increment_columns |
| schema_index_statistics |
| schema_object_overview |
| schema_redundant_indexes |
| schema_table_lock_waits |
| schema_table_statistics |
| schema_table_statistics_with_buffer |
| schema_tables_with_full_table_scans |
| schema_unused_indexes |
| session |
| session_ssl_status |
| statement_analysis |
| statements_with_errors_or_warnings |
| statements_with_full_table_scans |
| statements_with_runtimes_in_95th_percentile |
| statements_with_sorting |
| statements_with_temp_tables |
| sys_config |
| user_summary |
| user_summary_by_file_io |
| user_summary_by_file_io_type |
| user_summary_by_stages |
| user_summary_by_statement_latency |
| user_summary_by_statement_type |
| version |
| wait_classes_global_by_avg_latency |
| wait_classes_global_by_latency |
| waits_by_host_by_latency |
| waits_by_user_by_latency |
| waits_global_by_latency |
| x$host_summary |
| x$host_summary_by_file_io |
| x$host_summary_by_file_io_type |
| x$host_summary_by_stages |
| x$host_summary_by_statement_latency |
| x$host_summary_by_statement_type |
| x$innodb_buffer_stats_by_schema |
| x$innodb_buffer_stats_by_table |
| x$innodb_lock_waits |
| x$io_by_thread_by_latency |
| x$io_global_by_file_by_bytes |
| x$io_global_by_file_by_latency |
| x$io_global_by_wait_by_bytes |
| x$io_global_by_wait_by_latency |
| x$latest_file_io |
| x$memory_by_host_by_current_bytes |
| x$memory_by_thread_by_current_bytes |
| x$memory_by_user_by_current_bytes |
| x$memory_global_by_current_bytes |
| x$memory_global_total |
| x$processlist |
| x$ps_digest_95th_percentile_by_avg_us |
| x$ps_digest_avg_latency_distribution |
| x$ps_schema_table_statistics_io |
| x$schema_flattened_keys |
| x$schema_index_statistics |
| x$schema_table_lock_waits |
| x$schema_table_statistics |
| x$schema_table_statistics_with_buffer |
| x$schema_tables_with_full_table_scans |
| x$session |
| x$statement_analysis |
| x$statements_with_errors_or_warnings |
| x$statements_with_full_table_scans |
| x$statements_with_runtimes_in_95th_percentile |
| x$statements_with_sorting |
| x$statements_with_temp_tables |
| x$user_summary |
| x$user_summary_by_file_io |
| x$user_summary_by_file_io_type |
| x$user_summary_by_stages |
| x$user_summary_by_statement_latency |
| x$user_summary_by_statement_type |
| x$wait_classes_global_by_avg_latency |
| x$wait_classes_global_by_latency |
| x$waits_by_host_by_latency |
| x$waits_by_user_by_latency |
| x$waits_global_by_latency |
+-----------------------------------------------+
101 rows in set (0.00 sec)

mysql 5.7.9(GA) 安装的更多相关文章

  1. mysql学习之-三种安装方式与版本介绍

    MYSQL版本介绍 mysql分alpha,beta,rc,GA四个版本. alpha  暗示这是一个以展示新特性为目的的版本,存在比较多的不稳定因素,还会向代码中添加新新特性beta 以后的beta ...

  2. MySQL的Master/Slave群集安装和配置

    本文介绍MySQL的Master/Slave群集安装和配置,版本号安装最新的稳定版GA 5.6.19. 为了支持有限HA.我们用Master/Slave读写简单孤立的集群.有限HA这是当Master不 ...

  3. 记:MySQL 5.7.3.0 安装 全程截图

    前言: 下一个班快讲MySQL数据库了,正好把服务器里面的MySQL卸了重装了一下. 截个图,作为笔记.也正好留给需要的朋友们. 目录: 下载软件 运行安装程序 安装程序欢迎界面 许可协议 查找更新 ...

  4. Ubuntu MYSQL和Windows MYSQL (非C盘安装)

    1.Ubuntu 默认安装 Mysql 5.6版本以上: 1.查看系统是否安装mysql 数据库: sudo netstat -tap | grep mysql 如果安装了,就查看一下版本命令: my ...

  5. 彻底解决mysql中文乱码的办法,修改mysql解压缩版(免安装版或zip版)字符编码

    MySQL会出现中文乱码的原因不外乎下列几点:1.server本身设定问题,例如server字符编码还停留在latin12.table的语系设定问题(包含character与collation)3.客 ...

  6. MySQL数据库学习笔记(一)----MySQL 5.6.21的安装和配置(setup版)

    [声明] 欢迎转载,但请保留文章原始出处→_→ 生命壹号:http://www.cnblogs.com/smyhvae/ 文章来源:http://www.cnblogs.com/smyhvae/p/4 ...

  7. Linux 下 MySQL 的彻底卸载和安装配置字符集

    前言: Linux环境下MySQL的安装和配置在网上已经有很多教程了.之所以写这篇文章是因为在配置字符集的时候找了网上的一些教程发现并不能用导致折腾了一阵子.下面的教程均是亲自实践. MySQL的彻底 ...

  8. Mysql的cmake编译与安装

    Mysql的cmake编译与安装 实验准备环境: 我的操作系统是centos6.6 编译安装MariaDB之前,我们需要准备一些需要的环境 1.开发包组套件 [root@node19 ~]# yum ...

  9. MySQL 5.7.9 免安装配置

    MySQL 5.7.9 免安装配置 环境:win10 64位 mysql版本:mysql-5.7.9-winx64.zip (http://dev.mysql.com/downloads/mysql/ ...

随机推荐

  1. swift代码排版-参考

    代码排版包括: 空行.空格.断行和缩进等内容.代码排版内容比较多工作量很多,但是非常重要. 空行 空行将逻辑相关的代码段分隔开,以提高可读性.下列情况应该总是添加空行: 类型声明之前. import语 ...

  2. 怎样卸载goldengate

    1. Log on to the database server (as oracle) where the GoldenGate software isinstalled.2. Change dir ...

  3. Gmail 一些需注意的事

    display none 的问题 如果我们写html 然后用 mail server 发给gmail client . 如果内容涉及 display:none , 请加一个 important 比如 ...

  4. 热爱工作 发财机会大增(这里不是选择软件还是硬件的问题,是自己的性格和追求的问题)——当你的老板不如你懂行的时候,还赚的盆满钵满的时候,你就可以考虑独立了 good

    爱工作 发财机会大增 [ 油老板 ] 于:2011-02-09 06:39:41 复:1269077 认真回顾发主贴以来的三年半,俺觉得对于想发财的上班族来说,认真工作,刻苦钻研是发财的重要保证. 为 ...

  5. ExpandableListView(可展开的列表组件)的说明以及其用法

    ExpandableListView的用法和ListView非常像,只是其所显示的列表项应该由ExpandableListAdapter提供,下面是它的xml属性及说明: 然而,接下来是用事实说话了: ...

  6. opencv 图像仿射变换 计算仿射变换后对应特征点的新坐标 图像旋转、缩放、平移

    常常需要最图像进行仿射变换,仿射变换后,我们可能需要将原来图像中的特征点坐标进行重新计算,获得原来图像中例如眼睛瞳孔坐标的新的位置,用于在新得到图像中继续利用瞳孔位置坐标. 仿射变换在:http:// ...

  7. linux signal 用法和注意事项

    http://blog.chinaunix.net/uid-9354-id-2425031.html 所以希望能用相同方式处理信号的多次出现,最好用sigaction.信号只出现并处理一次,可以用si ...

  8. 2014-08-13 SQL语句之Left Join

    今天是在吾索实习的第26天.这天在处理数据库数据的时候发现了一个不错的语句就是Left Join,即左连接.  其功能是:即使右表中没有匹配,也从左表返回所有的行.也就是说,显示的行数与左表一致,且当 ...

  9. 大型分布式C++框架《三:序列化与反序列化》

    一.前言  个人感觉序列化简单来说就是按一定规则组包.反序列化就是按组包时的规则来接包.正常来说.序列化不会很难.不会很复杂.因为过于复杂的序列化协议会导致较长的解析时间,这可能会使得序列化和反序列化 ...

  10. log.sh

    #!/bin/echo Warnning, this library must only be sourced! # vim: set expandtab smarttab shiftwidth=4 ...