当前位置: 首页 > news >正文

Centos7离线安装MySQL8

1、下载MySQL

https://downloads.mysql.com/archives/community/

2、下载完毕后,上传到Centos,解压

tar -xf mysql-8.0.33-1.el7.x86_64.rpm-bundle.tar  

3、逐条执行安装命令

rpm -ivh mysql-community-common-8.0.33-1.el7.x86_64.rpm 
rpm -ivh mysql-community-client-plugins-8.0.33-1.el7.x86_64.rpm 
rpm -ivh mysql-community-libs-8.0.33-1.el7.x86_64.rpm 
rpm -ivh mysql-community-client-8.0.33-1.el7.x86_64.rpm 
rpm -ivh mysql-community-client-plugins-8.0.33-1.el7.x86_64.rpm 
rpm -ivh mysql-community-icu-data-files-8.0.33-1.el7.x86_64.rpm 
rpm -ivh mysql-community-server-8.0.33-1.el7.x86_64.rpm 
mysqld --initialize --user=mysql
systemctl status mysqld
systemctl start mysqld
systemctl status mysqld

4、查看临时密码

cat /var/log/mysqld.log

 5、修改mysql的root密码

alter user 'root'@'localhost' identified by 'xxxxxx'

执行完后,重新登录MySQL 

quit

6、允许远程登录

mysql -uroot -p
use mysql;select host from user where user='root';update user set host = '%' where user ='root';

更新配置

flush privileges;

http://www.lryc.cn/news/116950.html

相关文章:

  • AWD攻防学习总结(草稿状态,待陆续补充)
  • 扫雷(超详解+全部码源)
  • python生成exe脚本全过程
  • 【机器学习1】什么是机器学习机器学习的重要性
  • 立即开始使用 3D 图像
  • 鸿鹄工程项目管理系统em Spring Cloud+Spring Boot+前后端分离构建工程项目管理系统em
  • 《向量数据库》——怎么安装向量检索库Faiss?
  • 学习pytorch 2 导入查看dataset
  • 三、kubeadm部署单Master节点kubernetes集群
  • js-6:typeof和instanceof的区别
  • SQL SERVER 异地备份到远程共享文件夹异常处理
  • 服务器数据恢复-RAID5上层Hyper-V虚拟机数据恢复案例
  • Easy Rules规则引擎(1-基础篇)
  • Linux 上安装部署Nacos
  • 电动机的启动
  • python性能分析,logging性能,print性能,文件写入性能对比
  • [GIN-debug] [ERROR] listen tcp: address 8080: missing port in address
  • PHP codeigniter4 搭配Nginx
  • AWS——04篇(AWS之Amazon S3(云中可扩展存储)-02——EC2访问S3存储桶)
  • .netcore下grpc概述
  • Address already in use
  • ♥ vue中$set用法详细讲解
  • 岩土工程仪器多通道振弦传感器信号转换器应用于桥梁安全监测
  • 企业权限管理(六)-订单详情
  • 基于Tars高并发IM系统的设计与实现-实战篇5
  • 水溶性Cyanine3 N3叠氮化物Cy3 azide星戈瑞
  • 客户案例 | 永续发展,低代码助力“双碳”战略历史使命
  • [保研/考研机试] KY187 二进制数 北京邮电大学复试上机题 C++实现
  • SpringBoot 热部署
  • BLE蓝牙协议栈分析