登入mysql官网https://www.mysql.com/downloads/,点击Community,选择MySQL on Windows,选择MySQL Installer,选择MySQL Server,然后选择自己喜欢的mysql版本。我选择5.6版本(MySQL Community Server 5.6 »),然后选择小版本,我就选择最新的5.6.38下载了。别忘了选择操作系统,在Select OS Version下拉框里选择Windows(x86,64-bit)。

  我们直接下windows的MSI安装文件,选择对应的图片后跳出下载页。这个页面提示我们说,64位跟32位其实是同一个安装包。好吧,再次点击DownLoad按钮下载,再跳出一个页面来,不管上面的注册和登陆,直接点最下面的No thanks, just start my download.。至此,九弯十八曲,我们拐了好几个页面终于下到了安装包。下一步就是运行安装包执行安装程序。

  执行安装程序后按部就班走,第一步签合同,第二步选安装类型,我按默认的来,第三步先检查后安装,检查的话检查一项就可以了,不检查直接跳过到安装也行,接着一项项安装,第四步配置数据库,一直点过去就可以了,中间设置下密码即可(默认用户是root,默认端口3306)。

  最后Finish出来表示按流程走完了安装程序,跳出一个MySQL workbench的界面,输入密码登录就可以玩MySQL了。

  如果下载的是压缩包,会麻烦一点,需要手动配置系统路径、修改密码。首先解压后把bin目录所在路径配置到系统路径Path中(比如我本地是:D:\Dev\mysql\mysql-5.7.26-winx64\bin),接着用管理员身份运行命令行界面,再次来到mysql目录下(比如我本地是D盘的mysql\mysql-5.7.26-winx64 ),通过命令执行安装和启动:

C:\WINDOWS\system32>D:

D:\>cd Dev\mysql\mysql-5.7.-winx64

D:\Dev\mysql\mysql-5.7.-winx64>mysqld -install
Service successfully installed. D:\Dev\mysql\mysql-5.7.-winx64>mysqld --initialize D:\Dev\mysql\mysql-5.7.-winx64>net start mysql
MySQL 服务正在启动 .
MySQL 服务已经启动成功。

  这时启动的mysql是自己生成的临时密码,我们应该把它改成自己的密码。首先找到临时密码,还是回到mysql所在目录(比如我本地是D盘的mysql\mysql-5.7.26-winx64)进入data目录,打开XXX.err文件(XXX是你的本机用户名),搜“root@localhost”(root是mysql系统启动默认账户),找到冒号后面的密码,用它即可登录进入mysql:

D:\Dev\mysql\mysql-5.7.-winx64>mysql -u root -p
Enter password: ************
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is
Server version: 5.7. Copyright (c) , , Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

  接着我们来修改密码并输入新密码重新进入mysql:

mysql> set password for root@localhost = password('');
Query OK, rows affected, warning (0.07 sec) mysql> quit
Bye D:\Dev\mysql\mysql-5.7.-winx64>mysql -u root -p
Enter password: ******
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is
Server version: 5.7. MySQL Community Server (GPL) Copyright (c) , , Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql>

  看下都有哪些库,如果没有test数据库,那么就建一个:

mysql> create database test;
Query OK, row affected (0.02 sec) mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| mysql |
| performance_schema |
| sys |
| test |
+--------------------+
rows in set (0.01 sec) mysql> use test
Database changed
mysql> show tables;
Empty set (0.00 sec)

  如果要停掉mysql执行net stop mysql命令即可。

64位windows下mysql安装的更多相关文章

  1. 64位linux下rpm安装mysql的5.5.55版本

    昨天同事开了个阿里云环境,让我帮他安装mysql数据库,本想着很简单的一件事,结果还是折腾了一番.坑很多,一路趟过,一个接一个,只能硬着头皮冲. 首先是下载压缩包,因为采用了rpm安装方式,所以下载的 ...

  2. Winio驱动在64位windows下无法使用的解决方法

    C#在使用WinIo的驱动开发类似按键精灵一类工具的时候,需要对相关的驱动进行注册才能正常启动,找了下资料,资料来自: http://jingyan.baidu.com/article/642c9d3 ...

  3. PyTorch在64位Windows下的Conda包(转载)

    PyTorch在64位Windows下的Conda包 昨天发了一篇PyTorch在64位Windows下的编译过程的文章,有朋友觉得能不能发个包,这样就不用折腾了.于是,这个包就诞生了.感谢@晴天14 ...

  4. 在64位windows下使用instsrv.exe和srvany.exe创建windows服务

    在64位windows下使用instsrv.exe和srvany.exe创建windows服务   在32位的windows下,包括windows7,windows xp以及windows 2003, ...

  5. [转] 64位windows下添加postgreSQL odbc数据源

    系统环境:windows7 64位 postgreSQL9.0(64bit)   ps:安装postgreSQL时确定安装了odbc驱动.   问题:点击“开始->控制面板->管理工具-& ...

  6. 在64位windows下使用instsrv.exe和srvany.exe创建windows服务[转]

    本文转自:https://www.iflym.com/index.php/computer-use/201205020001.html 在32位的windows下,包括windows7,windows ...

  7. Windows7 64位系统下无法安装网络打印机的解决方法

    背景: 公司一台HP LaserJet 1010 打印机连在一台Windows XP的电脑上,而我的是windows7 64位系统,无法安装驱动解决办法:1:去惠普官网上下载对应的64位驱动(什么Vi ...

  8. 【转】在64位windows下使用instsrv.exe和srvany.exe创建windows服务

    本文转自:https://www.iflym.com/index.php/computer-use/201205020001.html 在32位的windows下,包括windows7,windows ...

  9. 64位Windows下安装Redis教程

    转载于:http://www.itxuexiwang.com/a/shujukujishu/redis/2016/0216/104.html?1455868495 Redis对于Linux​是官方支持 ...

随机推荐

  1. 使用shiro缓存用户身份信息的时候报:java.io.NotSerializableException: org.apache.shiro.util.SimpleByteSource

    最近在使用shiro缓存用户的身份信息的时候,报了simpleByteSource不能序列化,跟进源码一看,原来这个类没有实现序列化的接口,但是我在缓存身份信息的实现又要用到这个类,解决方法:重写一个 ...

  2. 谈谈RMQ问题

    没用的话:好像好久没更博了,无聊就讲讲算法吧(主要找不到水题). 感觉针对初学者,老师教这个算法时没怎么懂,最近(大概1.2个月前吧)老师又教了lca(最近公共祖先,额,可以百度,我就不讲了,可能以后 ...

  3. quartz(7)-源码分析

    定时器启动 上图通过spring加载quartz <bean id="scheduler" class="org.springframework.schedulin ...

  4. 编写第一个Shell脚本【TLCL】

    怎样编写一个 Shell 脚本 编写一个脚本 使脚本文件可执行 把脚本放到Shell能够找到的地方 脚本文件格式 #!/bin/bash # This is our first script. ech ...

  5. cmd下进入oracle sqlplus

    1.sqlplus /nolog 2.connect sys/orcl@ORCL as sysdba 3.select sysdate from dual exit;

  6. python学习笔记(SMTP邮件发送)

    想着给框架添加邮件发送功能.所以整理下python下邮件发送功能 首先python是支持邮件的发送.内置smtp库.支持发送纯文本.HTML及添加附件的邮件 之后是邮箱.像163.qq.新浪等邮箱默认 ...

  7. spring3: 切面及通知实例 Aspectj的aop

    1.前置通知 接口: package chapter1.server; public interface IHelloService { public void sayAdvisorBefore(St ...

  8. LinuxMint Mate 安装Google拼音输入法(Fcitx)

    安装Google拼音输入法(Fcitx)$ sudo apt-get install fcitx fcitx-config-gtk fcitx-frontend-all fcitx-ui-classi ...

  9. 如何查看Windows10连接的WiFi密码

    1.找到 WiFi 图标,右击鼠标,点击 打开‘网络和internet设置’ 2.点击 1 所指图标,然后点击 2 所指图标 3.鼠标左击图标 4.点击如下图标 5.先点击 1 的图标,在勾选 2 的 ...

  10. java环信服务端注册IM代码

    下载环信api代码 https://github.com/easemob/emchat-server-examples 里面包含各种语言版本,我只下载了java版emchat-server-java ...