1. 下载数据库
wget -c 'https://cdn.mysql.com//Downloads/MySQL-8.0...'
解压
tar xvf mysql-8.0.13-1.el7.x86_64.rpm-bundle.tar

  1. 安装
    yum install mysql-community-libs-8.0.13-1.el7.x86_64.rpm
    yum install mysql-community-libs-compat-8.0.13-1.el7.x86_64.rpm
    yum install mysql-community-client-8.0.13-1.el7.x86_64.rpm
    yum install mysql-community-server-8.0.13-1.el7.x86_64.rpm

  2. 设置数据库
    初次安装没进去,在 /etc/my.cnf 中添加 skip-grant-tables, 使用 mysql -uroot 直接进入数据库,
    修改 root 账号密码:
    alter user 'root'[[[[[[[[[[[[[[[@](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)](https://learnku.com/users/8278)](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)'localhost' identified by '**';
    mysql 8.0 以后默认加密方式跟 5.7 不一样 :
    ALTER USER 'root'[[[[[[[[[[[[[[[@](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)](https://learnku.com/users/8278)](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)'localhost' IDENTIFIED BY '**' PASSWORD EXPIRE NEVER; // 修改用户永不过期
    ALTER USER 'root'[[[[[[[[[[[[[[[@](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)](https://learnku.com/users/8278)](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)'localhost' IDENTIFIED WITH mysql_native_password BY '***';// 更新一下用户的密码加密方式,修改密码
    flush privileges; // 执行完刷新权限

  3. 创建新用户
    CREATE USER smile[[[[[[[[[[[[[[[@](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)](https://learnku.com/users/8278)](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)% IDENTIFIED BY 'passowrd'; //# 创建账号密码
    GRANT ALL ON . TO smile[[[[[[[[[[[[[[[@](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)](https://learnku.com/users/8278)](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)% WITH GRANT OPTION; // 授予远程登录权限(. 远程访问所有数据)
    REVOKE all privileges ON databasename.tablename FROM 'username'[[[[[[[[[[[[[[[@](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)](https://learnku.com/users/8278)](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)'host'; // 删除某些数据权限
    flush privileges;// 刷新权限
    // 不常用的 --- 创建过期用户
    CREATE USER smile[[[[[[[[[[[[[[[@](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)](https://learnku.com/users/8278)](https://learnku.com/users/31906)](https://learnku.com/users/29000)](https://learnku.com/users/27102)](https://learnku.com/users/25661)](https://learnku.com/users/19319)](https://learnku.com/users/10240)](https://learnku.com/users/8907)% IDENTIFIED BY '***' PASSWORD EXPIRE INTERVAL 90 DAY;
    // 数据库搞定
    service mysqld start restart stop

CentOS 7.6 下安装 MySQL8.0.13相关推荐

  1. centos 下安装mysql,linux(Centos7)下安装mysql8.0.18的教程图解

    1 获取安装资源包 mysql-8.0.18-1.el7.x86_64.rpm-bundle.tar 提取码: rsif 2 在/usr/local目录下新建目录mysql8 3 将下载的资源包(my ...

  2. Linux7.5 安装mysql8.0.13教程

    centos64位Linux7.5 安装mysql8.0.13教程 注意事项提前说明: 1:吾日三省吾身,防火墙关了没?(万一安装好了的MySQL,链接不上半天没有想到是防火墙在作祟)标点符号中英文搞 ...

  3. python安装mysql数据库_windows10安装mysql-8.0.13(zip安装)~Python安装mysql

    windows10安装mysql-8.0.13(zip安装) 安装环境说明 系统版本:windows10 mysql版本:mysql-8.0.13-winx64.zip 下载地址:http://mir ...

  4. linux下安装mysql_Linux下安装mysql-8.0.20的教程详解

    ** Linux下安装mysql-8.0.20 ** 环境介绍 操作系统:CentOS 7 mysql下载地址:https://dev.mysql.com/downloads/mysql/ 下载版本: ...

  5. mysql8.0.20安装教程linux_Linux下安装mysql-8.0.20的教程详解

    ** Linux下安装mysql-8.0.20 ** 环境介绍 操作系统:CentOS 7 mysql下载地址:https://dev.mysql.com/downloads/mysql/ 下载版本: ...

  6. 如何在Linux下安装MySQL8.0

    如何在Linux下安装MySQL8.0 准备工作: mysql8.0 rpm文件 测试工具(比如 idea的database工具) 安装步骤: 1.     下载mysql的repo源,下载地址:ht ...

  7. mysql安装最后两项无响应,win10下安装mysql8.0.23 及 “服务没有响应控制功能”问题解决办法...

    win10下安装mysql 1. 官网下载mysql 网址:https://www.mysql.com/downloads/ download页面往下拉:点击下图红框: 按下图指示操作: 下载之后解压 ...

  8. win8 64 mysql下载教程_windows下安装mysql-8.0.18-winx64的教程(图文详解)

    1.下载安装包 安装包现在地址: https://dev.mysql.com/downloads/mysql/ 2.解压缩至安装目录 解压缩下载之后的zip,我这里使用的安装路径为: C:\Progr ...

  9. Linux下安装MySQL8.0的详细步骤

    Linux下安装MySQL8.0的详细步骤 第一步:下载安装配置 第二步:修改密码,并设置远程连接(为了可以在别的机器下面连接该mysql) 搞了一台云服务器,首先要干的活就是得安装数据库,在Wind ...

最新文章

  1. 使用vue的mixins混入实现对正在编辑的页面离开时提示
  2. 暴力求解法 之 枚举排列
  3. 【软考-系统架构师】计算机操作系统相关考题答案详解
  4. 【若依(ruoyi)】datetimepicker日期和时间插件
  5. 【贪心】最大连续数列的和
  6. 某道词典在线翻译JS解密,完全扣js代码解密 (小白基础篇)
  7. 鸿蒙轻内核M核源码分析:中断Hwi
  8. linux怎么查看定时任务有没有运行,怎么看crontab定时任务是否执行
  9. 【转载】深入理解Java内存模型——final
  10. python表白代码-520使用Python实现quot;我爱你”表白
  11. 安装了Python2.X和Python3.X后Python2.X IDLE打不开解决办法总结
  12. pdf打印机如何设置双面打印
  13. 电路分析题目详解(四)
  14. gif动图怎么制作?手把手教你视频转gif动图
  15. Disney Springs - 迪士尼之泉
  16. ambari hdfs 启动报错_Ambari 1.6 自动安装hadoop 2.2.0 在Ambari启动namenode时报错
  17. 活动通知html代码大全,促销活动通知范文
  18. JetsonNano国产套件成功部署YoloV5手把手图解教程
  19. Yii学习--使用Yii来建立博客
  20. matlab cell 颜色,MATLAB 的 cell 大法(单元格数组)

热门文章

  1. SharePoint 2013 InfoPath 无法保存下列表单
  2. 使用jsonp及jquery的$.ajax解决跨域问题
  3. 判断输入的数是否质数,求范围内的质数有哪些
  4. for 创建一个方法:键盘录入一个数 ,求它的 阶乘 及 阶乘的和
  5. SQL注入1-5_cookie基于base64的注入
  6. 陕西国防 c语言第三章实训三答案,C语言程序设计(上)
  7. [网络安全提高篇] 一〇六.SQL注入之手工注入和SQLMAP入门案例详解
  8. Scrapy + Redis 分布式爬取58同城北京全站二手房数据
  9. pythonscrapy爬虫_零基础写python爬虫之使用Scrapy框架编写爬虫
  10. c# vscode 配置_[VSCode插件推荐] Code Runner: 代码一键运行,支持超过40种语言