当前位置:网站首页>mysql57 zip文件安装
mysql57 zip文件安装
2022-06-28 07:02:00 【Seele_1018】
转载自:https://www.cnblogs.com/guardwhy/p/14906539.html
MySQL5.7 安装
1.1-Windows 上安装 MySQL
1、进入官方下载地址
下载安装MySQL5.7版本::https://dev.mysql.com/downloads/mysql/
2.选择直接下载
3.解压安装
3.1、将下载完的 zip 包解压到相应的目录,这里我将解压后的文件夹放在E:\Develop\MySQL-5.7.30下,解压文件如图所示
3.2、在该文件夹下创建 my.ini 配置文件,编辑 my.ini 配置以下基本信息:
[mysql]
# 设置mysql客户端默认字符集
default-character-set=utf8
[mysqld]
# 设置3306端口
port = 3306
# 设置mysql的安装目录
basedir=E:\\Develop\\MySQL-5.7.30
# 设置 mysql数据库的数据的存放目录(MySQL8.0+ 不需要以下配置,系统自己生成即可,否则有可能报错)
datadir=E:\\Develop\\WorkPlace\\SqlData
# 允许最大连接数
max_connections=20
# 服务端使用的字符集默认为8比特编码的latin1字符集
character-set-server=utf8
# 创建新表时将使用的默认存储引擎
default-storage-engine=INNODB
3.3、以管理员身份打开 cmd 命令行工具,进入目录:
E:
cd E:E:\Develop\MySQL-5.7.30
初始化数据库: mysqld --initialize --console

3.4、运行mysqld install,若提示 “Service successfully installed.” 表示安装成功。
4.修改密码
4.1、执行net start mysql启动MySQL
4.2、运行mysql -u root -p后根据提示输入初始密码,回车后即可登录进MySQL。
4.3、修改密码命令的格式为
修改格式:set password for [email protected] = password(‘newPassword’);
密码设置为:set password for [email protected] = password(‘root’);
输入exit后回车,再运行mysql -u root -p后就可以用新密码登录了。
5.配置环境变量
5.1、右键此电脑 >> 高级系统设置 >> 环境变量 ,新建系统变量 MYSQL_HOME,变量值是安装MySQL的根目录:
5.2、编辑系统变量 Path >> 新建 >> 将 %MYSQL_HOME%\bin 添加到尾行 >> 确定。
5.3、配置好后,不用进入MySQL安装目录,以管理员身份打开命令行后,就可以直接登录MySQL了
边栏推荐
- 我的MVVM开源项目《出行防疫App》已发布
- Freeswitch uses origin to dialplan
- Comprehensive analysis of real enterprise software testing process
- VM332 WAService. js:2 Error: _ vm. Changetabs is not a function
- MySQL installation steps - Linux configuration file JDK installation (II)
- My MVVM open source project "travel epidemic prevention app" has been released
- 2 startup, interrupt and system call
- From the beginning of redis learning to take-off, this article is all for you
- [C language] detailed explanation of C language to obtain array length
- MySQL installation steps - how to create a virtual machine under Linux (1)
猜你喜欢

Kubernetes cluster lossless upgrade practice

Yesterday, I went to a large factory for an interview and asked me to do four arithmetic operations. Fortunately, I am smart enough

Techo day Tencent technology open day, June 28 online waiting for you!

Rn7302 three-phase electric quantity detection (based on STM32 single chip microcomputer)

Freeswitch uses origin to dialplan

Pfizer's new Guankou medicine has entered the Chinese market, and the listing of relevant products of domestic pharmaceutical enterprises is just around the corner

Leetcode+ 66 - 70 high precision, two sub topics

pytorch RNN 学习笔记

Build your jmeter+jenkins+ant

Introduction to Qualcomm platform WiFi -- Wi Fi display software
随机推荐
Niubi 666, this project makes web page making as simple as building blocks
ice - 资源
VM332 WAService. js:2 Error: _ vm. Changetabs is not a function
JS of learning notes -- split(), replace(), join()
Iphone6plus enters the list of antique products netizen: I'm still using it
KMP string
Extern "C" overview
【Rust日报】2020-05-24 Rash, Rocket, Mun, Casbin
最后的二十九天
【Rust翻译】从头实现Rust异步执行器
Speech enhancement - spectrum mapping
Puge -- three basic sorting, bubbling, selection and quickness
Using interceptor and cache to complete interface anti brushing operation
推荐10个好用到爆的Jupyter Notebook插件,让你效率飞起
@RequestParam
声网 VQA:将实时互动中未知的视频画质用户主观体验变可知
力扣515.在每棵树行中找最大值
Leetcode+ 66 - 70 high precision, two sub topics
Comment la passerelle BACnet / IP recueille - t - elle les données du système central de contrôle des bâtiments?
实现这个 issue 得700块钱人民币,有人做嘛?