centos6 yum安装最新版mysql5.7
在看来mysql5.7诸多改进介绍后,决定也安装一个试用下;本文将使用rpm的方式来安装。
环境:
OS: CentOS6.5 x86_64 最小化安装
MEM: 1G
CPU: 1
1. 本文连着上一篇安装GCC5.3之后,新版本的glibc环境需设置到全局环境
shell> strings /usr/lib64/libstdc++.so.6|grep GLIBCXX # 查看当前版本
shell> rm -f /usr/lib64/libstdc++.so.6
shell> ln -s /usr/local/lib64/libstdc++.so.6.0.21 /usr/lib64/libstdc++.so.6
shell> strings /usr/local/lib64/libstdc++.so.6.0|grep GLIBCXX # 查看当前版本
2. 更新yum源到最新
shell> yum update
# 下载mysql的yum仓库文件
shell> wget
# 安装mysql yum repo
shell> rpm -Uvh mysql57-community-release-el6-7.noarch.rpm
# 或: yum localinstall mysql57-community-release-el6-7.noarch.rpm
# 查看
shell> vim /etc/yum.repos.d/mysql-community.repo # 可以看到里面关于mysql的内容,确保mysql57的enable是打开的状态(1)
3. 安装mysql服务
shell> yum install mysql-community-server
# 完成后启动服务
shell> service mysqld start
# 启动后,查看安装后自动生成的密码
shell> grep "password" /var/log/mysqld.log
## 输出
2015-12-24T02:12:21.721431Z 1 [Note] A temporary password is generated for root@localhost: s8)9B9)!#iWJ
2015-12-24T02:12:25.495271Z 0 [Note] Execution of init_file '/var/lib/mysql/install-validate-password-plugin.lv0PNr.sql' started.
2015-12-24T02:12:25.506256Z 0 [Note] Execution of init_file '/var/lib/mysql/install-validate-password-plugin.lv0PNr.sql' ended.
2015-12-24T02:12:27.323654Z 0 [Note] Shutting down plugin 'sha256_password'
2015-12-24T02:12:27.323657Z 0 [Note] Shutting down plugin 'mysql_native_password'
2015-12-24T02:12:29.351753Z 2 [Note] Access denied for user 'UNKNOWN_MYSQL_USER'@'localhost' (using password: NO)
## 第一行“root@localhost:”后面的字符就是密码了,我们需要用它来设置我们自己的root登录密码
shell> mysql_secure_installation
## 输出
Securing the MySQL server deployment.
Enter password for user root: [请在这里输出自动生成的密码,如:s8)9B9)!#iWJ]
## 注:密码必须满足1)长度大于8;2)包含至少1个数字,1个大写字母,1个小写字母,1个非字母数字的符号;3)长度不得超过32位。
## 完成后还需要设置一些初始化的配置,请按照提示来做
# 以上步骤结束后,可以使用root用户登录mysql试试了
shell> mysql -u root -p
# mysql的配置文件所在目录
shell> find / -name my.cnf
## 输出
/etc/my.cnf
4. 更多配置请到my.cnf中修改
5. 其他
官方文档请查看:
http://dev.mysql.com/doc/refman/5.7/en/linux-installation-yum-repo.html
centos6 yum安装最新版mysql5.7的更多相关文章
- Linux -- Centos6 yum安装相关问题与处理
Centos6 yum安装相关问题与处理 由于要使用yum下载文件,突然yum下载不了想要的文件,想更换yum源,结果得重新安装yum 来自本人GitHub地址https://github.com/m ...
- centos6 yum 安装memcached
centos6 yum 安装memcached - 像块石头 - 博客园http://www.cnblogs.com/rockee/archive/2012/08/01/2619160.html yu ...
- Centos6 yum安装openldap+phpldapadmin+TLS+双主配置
原文地址:http://54im.com/openldap/centos-6-yum-install-openldap-phpldapadmin-tls-%E5%8F%8C%E4%B8%BB%E9%8 ...
- Centos6 yum安装nginx
1.Centos6系统库中默认是没有nginx的rpn包的,所以我们需要先更新下rpm依赖库 (1):使用yum安装nginx,安装nginx库 rpm -Uvh http://nginx.org/p ...
- centos6 yum安装jdk1.8+
一.环境Linux操作系统: centos6.9 安装jdk版本: jdk1.8+ 二.安装步骤1. 检查系统是否自带有jdk[root@VM_0_11_centos ~]# rpm -qa |gre ...
- CentOS-6 yum安装nginx php53 mysql55 搭建LNMP环境
1.导入外部软件库 01.rpm -Uvh http://dl.iuscommunity.org/pub/ius/stable/Redhat/6/x86_64/epel-release-6-5.noa ...
- CentOS6 YUM安装MariaDB10.3.10
1.先新增加一个MariaDB.repo vi /etc/yum.repos.d/MariaDB.repo [mariadb] name = MariaDB baseurl = http://mirr ...
- linux centos6 yum 安装lamp
centos 6.5 1.yum安装和源代码编译在使用的时候没啥区别,但是安装的过程就大相径庭了,yum只需要3个命令就可以完成,源代码需要13个包,还得加压编译,步骤很麻烦,而且当做有时候会出错,源 ...
- centos6 yum 安装nginx 不成功解决办法
转自 http://wlheihei.com/view/64 [root@51ou.com yum.repos.d]# yum install nginxLoaded plugins: fastes ...
随机推荐
- 高精度减法用string 和 stack
#include "bits/stdc++.h" using namespace std; int main() { string a,b; while(cin >> ...
- 项目构建工具gradle
1.安装 https://gradle.org/install 2.构建一个项目 https://guides.gradle.org/creating-new-gradle-builds/ 3.bui ...
- SQL ltrim() 和 rtrim() 函数
LTRIM删除起始空格后返回字符表达式. 语法LTRIM ( character_expression ) 参数character_expression 是字符或二进制数据表达式.character_ ...
- 数据库,ADO.NET(ADO),Oledb(Odbc)和编程语言关系框架图
---恢复内容开始--- ---恢复内容结束---
- javassist示例
javassist的作用是动态生成字节码. package com.zhang; class Fighter {} public class Assist_Test { public static v ...
- Java-Runtime 类
https://www.cnblogs.com/slyfox/p/7272048.html Java-Runtime 类 Runtime 类代表着Java程序的运行时环境,每个Java程序都有一个Ru ...
- 使用HTTPS与SSL来保证安全性
原文链接:https://developer.android.com/training/articles/security-ssl.html SSL,安全套接层(TSL),是一个常见的用来加密客户端和 ...
- win10 移动热点自动关闭
解决win10移动热点自动关闭
- 《Python》 property、classmethod、staticmethod、isinstance、issubclass
一.property property是一个装饰器函数 装饰器函数的使用方法:在函数.方法.类的上面一行直接@装饰器的名字 装饰器的分类: 1.装饰函数 2.装饰方法:property 3.装饰类 i ...
- 关于hot miami的沙盒生存俯视角射击游戏
一些关卡设计元素 撞门杀 扇形视角