赞
踩
操作系统
安装包
安装步骤
# For advice on how to change settings please see # http://dev.mysql.com/doc/refman/5.6/en/server-configuration-defaults.html # *** DO NOT EDIT THIS FILE. It's a template which will be copied to the # *** default location during install, and will be replaced if you # *** upgrade to a newer version of MySQL. [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 # These are commonly set, remove the # and set as required. # basedir = ..... # datadir = ..... # port = ..... # server_id = ..... # 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 sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
修改红色的内容,记得路径不要写错哦,还有记得在目录下建个data文件,该文件夹用来存放数据的。
6. 输入cmd,以管理员身份运行控制台,进入MySQL路径(F:\SP\mysql-8.0.15\bin)下,运行mysqld --initialize --console命令。进行初始化,如下:
** 注意红色部分是密码啊,要记住哦!**
7. 输入cmd,以管理员身份运行控制台,进入MySQL路径(F:\SP\mysql-8.0.15\bin)下,运行mysqld install命令。安装成功后如下:
** 注意:这里需要以管理员身份运行,否则提示如下:**
8. 启动服务,net start mysql 如下
9. 接下来就是修改密码啦!毕竟生成的密码不好记!mysql -uroot -p,输入上面生成的密码!
10. 接下来输入sql 语句
ALTER USER ‘root’@‘localhost’ IDENTIFIED WITH mysql_native_password BY ‘password’;
[mysqld]
default_authentication_plugin=mysql_native_password
欢迎进入个人公众号 ,一起学习啊!
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。