Conversion between shared tablespace and exclusive tablespace _ MySQL

Source: Internet
Author: User
Conversion between shared tablespace and exclusive tablespace bitsCN.com

Conversion between shared and exclusive tablespaces

Innodb_file_per_table is converted using this parameter. if it is OFF, it indicates that the exclusive tablespace is used. [by default, the tablespace used is a shared tablespace]

The innodb_file_per_table value can be modified, but it does not affect the previously used shared tablespace unless it is manually modified or innodb_file_per_table = 1 is used for the shared tablespace innodb_file_per_table = 0.

Modify the data storage location of an exclusive empty tablespace

innodb_data_home_dir = "C:/mysql/data/"innodb_log_group_home_dir = "C:/mysql/data/"innodb_data_file_path=ibdata1:10M:autoextendinnodb_file_per_table=1

Parameter description:

This configuration configures a single file with an expandable size of 10 Mb, named ibdata1. No file location is provided, so it is in the MySQL data directory by default. [Data initialization settings]

Innodb_data_home_dir indicates that innodb_log_group_home_dir is the directory where the database files are stored. innodb_file_per_table indicates whether to use the shared and exclusive tablespace.

The preceding parameters must be added together.

Notes for parameters

InnoDB does not create a directory. Therefore, before starting the server, make sure that the "configured path directory" exists. This is true for any log file directory you configured. Use the mkdir command of Unix or DOS to create any required directories.

By deploying the value of innodb_data_home_dir to the data file name in the original format, and adding a slash or backslash as needed, InnoDB forms a directory path for each data file.

If the innodb_data_home_dir option is not mentioned in my. cnf, the default value is the "dot" directory./, which means the MySQL data directory.

BitsCN.com

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.