Windows 10上的MySql安装问题 [英] Issue with MySql installation on Windows 10

查看:134
本文介绍了Windows 10上的MySql安装问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

更新:已解决!这是我的解决方案:

如今,系统通常在以GPT格式化的磁盘上运行.这是因为Windows 10需要安装这样的分区.问题是MySql无法处理这种分区样式,因此会崩溃.这是我的解决方法:

Todays systems are often running on a disk which is formatted in GPT. This is because Windows 10 needs such a partition to be installed. The problem is that MySql cant deal with this partition style and so it crashes. Here is my workaround:

使用MBR格式化该VHD

Format this VHD with MBR

在新的VHD上安装MySql自定义(不要忘记创建用户 对于数据库)

Install MySql custom on your new VHD (dont forget to create a user for DB)

应该是这样! :)

我尝试在Windows 10的Dell XPS 13 9360上安装MySql.将服务器作为服务启动时,该服务无法启动.到目前为止,这个问题是众所周知的,并且有许多尝试来解决这个问题.不幸的是,这些都不适合我.这是我尝试过的:

I try to install MySql on my Dell XPS 13 9360 with Windows 10. When it comes to starting the server as a service, the service cannot start. As so far this problem is widely known and there are many attempts to solve this issue. Unfortunately non of these work for me. Here is what I tried:

  • 将innodb_flush_method = normal插入my.ini
  • 更改服务以在本地帐户中注册
  • 检查防火墙的端口规则

所以我的问题是:有人遇到同样的问题,并且知道一种使其运行的方法吗?你真的会帮助我很多:) 这是我的错误日志:

So my question: Does anybody experience the same issue and knows a way to get it running? You would help me really so much :) Here is my error log:

2017-01-23T14:11:44.458654Z 0 [Warning] option 'new': boolean value 't' wasn't recognized. Set to OFF.
2017-01-23T14:11:44.458654Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2017-01-23T14:11:44.458654Z 0 [Note] --secure-file-priv is set to NULL. Operations related to importing and exporting data are disabled
2017-01-23T14:11:44.459156Z 0 [Note] mysqld (mysqld 5.7.17) starting as process 5340 ...
2017-01-23T14:11:44.468178Z 0 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2017-01-23T14:11:44.469212Z 0 [Note] InnoDB: Uses event mutexes
2017-01-23T14:11:44.469713Z 0 [Note] InnoDB: _mm_lfence() and _mm_sfence() are used for memory barrier
2017-01-23T14:11:44.470716Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-01-23T14:11:44.471217Z 0 [Note] InnoDB: Number of pools: 1
2017-01-23T14:11:44.471719Z 0 [Note] InnoDB: Not using CPU crc32 instructions
2017-01-23T14:11:44.474727Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2017-01-23T14:11:44.481212Z 0 [Note] InnoDB: Completed initialization of buffer pool
2017-01-23T14:11:44.546889Z 0 [ERROR] InnoDB: Header page consists of zero bytes in datafile: .\ibdata1, Space ID:0, Flags: 0. Please refer to http://dev.mysql.com/doc/refman/5.7/en/innodb-troubleshooting-datadict.html for how to resolve the issue.
2017-01-23T14:11:44.548924Z 0 [ERROR] InnoDB: Corrupted page [page id: space=0, page number=0] of datafile '.\ibdata1' could not be found in the doublewrite buffer.
2017-01-23T14:11:44.550425Z 0 [ERROR] InnoDB: Plugin initialization aborted with error Data structure corruption
2017-01-23T14:11:44.771283Z 0 [ERROR] Plugin 'InnoDB' init function returned error.
2017-01-23T14:11:44.772134Z 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2017-01-23T14:11:44.772635Z 0 [ERROR] Failed to initialize plugins.
2017-01-23T14:11:44.773135Z 0 [ERROR] Aborting
2017-01-23T14:11:44.773636Z 0 [Note] Binlog end
2017-01-23T14:11:44.774138Z 0 [Note] Shutting down plugin 'CSV'
2017-01-23T14:11:44.774640Z 0 [Note] mysqld: Shutdown complete

先谢谢您!

@Bill Karwin:

@Bill Karwin :

好的,因此在删除表空间后,结果是这样的:

OK, so after removing the tablespace the result is this:

2017-01-23T15:39:39.874463Z 0 [Note] --secure-file-priv is set to NULL. Operations related to importing and exporting data are disabled
2017-01-23T15:39:39.874965Z 0 [Note] mysqld (mysqld 5.7.17) starting as process 624 ...
2017-01-23T15:39:39.880480Z 0 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2017-01-23T15:39:39.880980Z 0 [Note] InnoDB: Uses event mutexes
2017-01-23T15:39:39.881484Z 0 [Note] InnoDB: _mm_lfence() and _mm_sfence() are used for memory barrier
2017-01-23T15:39:39.882022Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-01-23T15:39:39.882986Z 0 [Note] InnoDB: Number of pools: 1
2017-01-23T15:39:39.882986Z 0 [Note] InnoDB: Not using CPU crc32 instructions
2017-01-23T15:39:39.885491Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2017-01-23T15:39:39.891024Z 0 [Note] InnoDB: Completed initialization of buffer pool
2017-01-23T15:39:39.914631Z 0 [Note] InnoDB: The first innodb_system data file 'ibdata1' did not exist. A new tablespace will be created!
2017-01-23T15:39:39.915071Z 0 [ERROR] InnoDB: redo log file '.\ib_logfile1' exists. Creating system tablespace with existing redo log files is not recommended. Please delete all redo log files before creating new system tablespace.
2017-01-23T15:39:39.916074Z 0 [ERROR] InnoDB: InnoDB Database creation was aborted with error Generic error. You may need to delete the ibdata1 file before trying to start up again.
2017-01-23T15:39:40.132668Z 0 [ERROR] Plugin 'InnoDB' init function returned error.
2017-01-23T15:39:40.132668Z 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2017-01-23T15:39:40.134090Z 0 [ERROR] Failed to initialize plugins.
2017-01-23T15:39:40.134590Z 0 [ERROR] Aborting

2017-01-23T15:39:40.135594Z 0 [Note] Binlog end
2017-01-23T15:39:40.136094Z 0 [Note] Shutting down plugin 'CSV'
2017-01-23T15:39:40.136595Z 0 [Note] mysqld: Shutdown complete


删除logdata1和0后出现新错误:


new error after deleting logdata1 and 0:

2017-01-23T15:55:22.158765Z 0 [Note] --secure-file-priv is set to NULL. Operations related to importing and exporting data are disabled
2017-01-23T15:55:22.159266Z 0 [Note] mysqld (mysqld 5.7.17) starting as process 2880 ...
2017-01-23T15:55:22.165783Z 0 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2017-01-23T15:55:22.165783Z 0 [Note] InnoDB: Uses event mutexes
2017-01-23T15:55:22.165783Z 0 [Note] InnoDB: _mm_lfence() and _mm_sfence() are used for memory barrier
2017-01-23T15:55:22.166284Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.3
2017-01-23T15:55:22.166284Z 0 [Note] InnoDB: Number of pools: 1
2017-01-23T15:55:22.166786Z 0 [Note] InnoDB: Not using CPU crc32 instructions
2017-01-23T15:55:22.169292Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2017-01-23T15:55:22.178820Z 0 [Note] InnoDB: Completed initialization of buffer pool
2017-01-23T15:55:22.202407Z 0 [Note] InnoDB: The first innodb_system data file 'ibdata1' did not exist. A new tablespace will be created!
2017-01-23T15:55:22.203383Z 0 [Note] InnoDB: Setting file '.\ibdata1' size to 12 MB. Physically writing the file full; Please wait ...
2017-01-23T15:55:22.249691Z 0 [Note] InnoDB: File '.\ibdata1' size is now 12 MB.
2017-01-23T15:55:22.263685Z 0 [Note] InnoDB: Setting log file .\ib_logfile101 size to 48 MB
2017-01-23T15:55:22.342287Z 0 [Note] InnoDB: Setting log file .\ib_logfile1 size to 48 MB
2017-01-23T15:55:22.452340Z 0 [ERROR] InnoDB: Operating system error number 87 in a file operation.
2017-01-23T15:55:22.452842Z 0 [Note] InnoDB: Some operating system error numbers are described at http://dev.mysql.com/doc/refman/5.7/en/operating-system-error-codes.html
2017-01-23T15:55:22.453346Z 0 [ERROR] InnoDB: File .\ib_logfile101: 'aio write' returned OS error 187. Cannot continue operation
2017-01-23T15:55:22.453346Z 0 [ERROR] InnoDB: Cannot continue operation.

推荐答案

找到了解决方案:

如今,系统通常在以GPT格式化的磁盘上运行.这是因为Windows 10需要安装这样的分区.问题是MySql无法处理这种分区样式,因此会崩溃.这是我的解决方法:

Todays systems are often running on a disk which is formatted in GPT. This is because Windows 10 needs such a partition to be installed. The problem is that MySql cant deal with this partition style and so it crashes. Here is my workaround:

  • 创建虚拟磁盘:此处手动
  • 使用MBR格式化此VHD
  • 在新的VHD上安装MySql自定义(不要忘记为DB创建用户)

应该是这样! :)

这篇关于Windows 10上的MySql安装问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆