Installing the MySQL Transaction database (InnoDB)

Source: Internet
Author: User
Tags mysql manual

MySQL database is divided into two types, one is the traditional data table format, one is to support the transaction of the data table-type (INNODB,BDB, which is mainly based on InnoDB), I introduce the MySQL transaction processing database installation and Use methods

You have to download the MySQL max version of the installer, download the address: www.mysql.com

Install in the usual way

When the installation is complete, start mysqlbinwinmysqladmin

And then quit.

Run

Mysqlbinmydqld-nt--remove

Mysqlbinmysqld-max-nt--install

The above two lines are to remove the MySQL service that does not support transaction processing, change to support MySQL transaction processing service

Then in C: Build a ibdata directory and Iblogs directory, of course, the name can be different, remember these two names and letter, later to use, you can not build in C disk, and then, open the C:winnt or c:windows directory My.ini, in the last add: [Code]

Innodb_data_file_path = ibdata1:2000m;ibdata2:2000m

Innodb_data_home_dir = C:ibdata

Set-variable = Innodb_mirrored_log_groups=1

Innodb_log_group_home_dir = C:iblogs

Set-variable = innodb_log_files_in_group=3

Set-variable = innodb_log_file_size=30m

Set-variable = innodb_log_buffer_size=8m

Innodb_flush_log_at_trx_commit=1

Innodb_log_arch_dir = C:iblogs

Innodb_log_archive=0

Set-variable = innodb_buffer_pool_size=80m

Set-variable = innodb_additional_mem_pool_size=10m

Set-variable = innodb_file_io_threads=4

Set-variable = innodb_lock_wait_timeout=50

[/code]

which

Innodb_data_file_path = ibdata1:2000m;ibdata2:2000m

This line of 2000M can change their own 200m, to see the size of your disk, MySQL recommended 10G and above the hard disk space is best to use such settings;

The following line

Innodb_data_home_dir = C:ibdata

You can also change to your own directory, mainly to see yourself in the directory where you have just built

In accordance with the above method, you have installed the MySQL transaction database, but if you follow the method installed in the MySQL manual, the above section of the preparation to my.cnf is to go, but there will be mistakes OH

Okay, now let's try to see if the installation is complete, start Apache, or IIS, start the MySQL service in the service, open phpMyAdmin, enter: Show variables like "have_%"

If you see the following results, it means that you have successfully installed

[Code]

Variable_name Value

Have_bdb YES

Have_innodb YES

Have_isam YES

Have_raid NO

Have_symlink YES

Have_openssl NO

Have_query_cache YES

[/code]

Note: The use of the MySQL transaction method is similar to other database syntax. Here I will not say more, in addition, MySQL will be in 4.3 to implement foreign keys and subqueries, simple foreign keys already in 4.0 have been achieved, but not convenient, I believe that will do better later.

About the use of the transaction table, I have successfully implemented in my online order management system, the effect is not bad, but has not been a large number of data practice

The above article is oneself according to the practice writes out, if wants to reprint, please indicate the source and the author, also welcome everybody to discuss with me about the MySQL transaction table some questions

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.