This article describes how to correctly install MySQL transaction database (InnoDB). We all know that MySQL (the best combination with PHP) databases are mainly divided into two types, one is a more traditional data table format, and the other is a data table format that supports transaction processing (InnoDB and BDB, with InnoDB as the primary ).
Next I will introduce how to install and use MySQL (the best combination with PHP) Transaction processing database.
Download the installation program for MySQL (the best combination with PHP) max, www. MySQL (the best combination with PHP). com
Install MySQL as usual
After installation, start MySQL (the best combination with PHP) binWinMySQL (the best combination with PHP) admin
Exit again
Run
MySQL (the best combination with PHP) binmydqld-nt -- remove
MySQL (the best combination with PHP) binMySQL (the best combination with PHP) d-max-nt -- install
The above two lines remove the MySQL (the best combination with PHP) service that does not support transaction processing, and change to the service that supports MySQL (the best combination with PHP) transaction processing.
Then, create an ibdata directory and an iblogs directory under c:. Of course, the names can be different. Remember these two names and drive letters and they will be used later. You can also choose not to create a c disk. Then, open my. ini, add at the end: the following content is the program 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
Where
- innodb_data_file_path = ibdata1:2000M;ibdata2:2000M
You can change the 200 m in this line to m, depending on the capacity of your disk. MySQL (the best combination with PHP) recommends that you use this setting for hard disk space of 10 Gb or more;
The following line
- innodb_data_home_dir = c:ibdata
You can also change it to your own directory, mainly to see where the directory you just created is
According to the above method, you have installed MySQL (the best combination with PHP) transaction database, but if you follow MySQL (the best combination with PHP) install the method in the manual and put the above section into my. if cnf is used, errors may occur.
Now, let's see if the installation is complete. Start apache (the most popular WEB server platform on Unix), or iis, and start MySQL (the best combination with PHP) in the service) open phpmyadmin and enter: SHOW variables like "have _ %"
If you see the following result, it indicates that the installation is successful.
The above content is an introduction to the installation of MySQL transaction database (InnoDB). I hope you will have some gains.