1067 error resolution and reflection on MySQL startup under Windows platform

Source: Internet
Author: User

I think the cause of this problem may be more than one, so collect some friends on the Internet to solve this problem for your reference, I hope you have some help. First,

1, open My.ini file, find Default-storage-engine=innodb this line, change it to Default-storage-engine=myisam.

2. Remove Ib_logfile0 and Ib_logfile1 from the data directory in the MySQL installation directory
3. Locate the Infodb directory that you specified when configuring the MySQL server to remove ibdata1

According to the My.ini file:

#*** INNODB Specific Options * * *
Innodb_data_home_dir= "d:/".
4. Restarting the service for MySQL

According to my own practice, a third step will solve the problem.

Two

Err File contents:

090417    9:02:55   innodb:error:unable to create temporary file; errno:2
090417   9:02:55 [ERROR] Plugin ' InnoDB ' init function returned ERROR.
090417   9:02:55 [ERROR] Plugin ' InnoDB ' registration as a STORAGE ENGINE failed.
090417   9:02:55 [ERROR] unknown/unsupported table Type:innodb
090417   9:02:55 [ ERROR] aborting

090417    9:02:55 [Warning] forcing shutdown of 1 plugins
090417   9:02:55 [Note] MySQL: Shutdown complete 

          after a turn over Google, Find out why you can't start: MySQL does not automatically initial tmpdir (temporary file directory) when installing, so add the following in the configuration file My.ini:

[mysqld]

#自己指定的临时文件目录

tmpdir= "D:/mysql/mysql Server 5.1/temp"

start MySQL again everything works, and some *.tmp temporary files are generated under the temp folder.

Finally, there are some questions: if it is not initialized Tmpdir, why did I not initialize the first installation, but there is no such a problem?

Three

It was a good time to manually install MySQL5.0.16 Windows service before, When you installed the service for 5.0.83 last night, you were always prompted with 1067 errors. Online someone said put My.ini under the C:\WINDOWS, but I encountered the situation is still not solve the problem. My solution is to replace the--defaults-file in the parameter with--defaults-extra-file, as follows:

mysqld--install MySQL--defaults-file=e:/ Mysql-5.0.83-win32/my.ini

instead

mysqld--install MySQL--defaults-extra-file=e:/ Mysql-5.0.83-win32/my.ini

execute mysqld --verbose--help can see the use of mysqld, There are descriptions of these two parameters.

      According to my own practice, the most likely cause of this problem is the data table storage engine (Engine, Jane In other words, the storage engine refers to the type of the table, that is, tables type

) caused by. MySQL database supports a variety of data table storage engines, can be viewed with the command: Show engines, in the MySQL configuration file My.ini can also be seen (the default is MyISAM):

# The default storage engine that would be used when create new tables when
Default-storage-engine=myisam.

the common storage engine and INNODB,INNODB have many advantages, InnoDB to MySQL table provides transaction, rollback, crash repair ability, Multiple versions of concurrency-controlled transaction security. At the same time, InnoDB is the first engine on MySQL to provide foreign key constraints, and the ability of the InnoDB storage engine to handle transactions is unmatched by other MySQL storage engines.

The difference between InnoDB and MyISAM:

tables stored in the InnoDB storage engine, the. frm that stores the table structure is stored separately from the saved table data file (IBDATA1), and the file location where the table data is stored can be set by modifying the My.ini file itself:

#*** INNODB Specific Options * * *

Innodb_data_home_dir= "d:/"

The table stored in the MyISAM storage engine consists of 3 files:. frm (the structure of the stored table) file. MYD (myoudata, stored table data) file. MYI (abbreviation for Myindex, the index of the storage table), this three files are stored in the directory where the MySQL database is installed, such as F:\ProgramData\MySQL\MySQL Server 5.1\data\databasename.

In addition, through the resolution of this problem, I realized the importance of viewing the error log, when encountered problems, we should first think of the error log should be to see, rather than go to Google or Baidu, In fact, from the error log we can get the real cause of the problem, the right remedy, in order to charm. The MySQL error log (. err) is located in the F:\ProgramData\MySQL\MySQL Server 5.1\data directory, and the file name is typically your computer name.

1067 error resolution and reflection on MySQL startup under Windows platform

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.