File formats for Xtradb/innodb

Source: Internet
Author: User
Tags compact

This is the official manual for mariadb: The translation of Xtradb/innodb File format.

Original:https://mariadb.com/kb/en/library/xtradbinnodb-file-format/
I submit it to MARIADB official manual:https://mariadb.com/kb/zh-cn/xtradbinnodb-file-format/

Currently, XTRADB/INNODB supports two formats of storage files: Antelope (antelope) and Barracuda (Barracuda) (the name of the animal, and the first letter from the front to the back of the arrangement, the end of this article also mentions 26 file formats, all animal names named). innodb_file_formatthe format of the file can be set through the server variable. The default setting is Antelope. The file format between MySQL 5.5.0 and 5.5.6 is default to Barracuda, but this format may cause problems with replication (replication) in the event of an upgrade, so the default format in MARIADB is always set to antelope.

The system table space uses the Antelope file format and cannot be changed. For this purpose, the variables need to be set in order for the user table to use the Barracuda format innodb_file_per_table .

MariaDB Starting with 10.0

Starting with MARIADB 10.0, you can see the file format you are using from the table information Schema innodb_sys_tables.

Compatibility

Each tablespace is marked with the file format ID of the table it is using most recently. All versions of Xtradb/innodb can read tables in older file formats. However, you cannot read a table that updates some formats. For this reason, the format of the tablespace is checked every time Xtradb/innodb opens a table, and the new file format is found using the Times error.

(Original: Each tablespace was tagged with the ID of the most recent file format used by one of its tables. All versions of XTRADB/INNODB can read tables this use an older file format. However, it can not be read from the more recent formats. For this reason, each time xtradb/innodb opens a table it checks the tablespace's format, and returns an error if a newer Format is used.)

You can skip the innodb_file_format_check check by setting a variable. Note, however, that when an unknown format is found, Xtradb/innodb attempts to repair the table, thereby corrupting the table. This can happen innodb_file_format_check when a server crashes after a variable is disabled, or when you use Fast stop service (fast shutdown).

To downgrade from Barracuda format to Antelope format, you can ALTER TABLE set the ROW_FORMAT value of the table to support Antelope by using a statement. This rebuilds the index.

Tables in the Antelope format can work correctly on MARIADB and under version 5.5 of MySQL.

Note that the tablespace is marked to support the lowest file format for the row format used. Therefore, even if Barracuda is enabled, table formats are marked as Antelope if the row format used is compact or redundant.

Antelope

Antelope is the original file format for InnoDB, supports compact and redundant row formats, but does not support dynamic or compressed row formats.

Barracuda

Barracuda is an updated InnoDB file format that supports compact, redundant, dynamic, and compressed line formats. Tables with blob or text data types can greatly benefit from the dynamic row format.

Format for the future

Future XTRADB/INNODB may use the new file format. Each format has its own name, and their identifier ID is from 0-25. These names have been figured out, all based on the alphabetical order of animal names: Antelope, Barracuda, Cheetah, Dragon, Elk, Fox, Gazelle, Hornet, Impala, Jaguar, Kangaroo, Leop ARD, Moose, Nautilus, Ocelot, porpoise, quail, Rabbit, Shark, Tiger, Urchin, Viper, Whale, Xenops, yak, and Zebra.

Back to Linux series article outline: http://www.cnblogs.com/f-ck-need-u/p/7048359.html
Back to Site Architecture series article outline: http://www.cnblogs.com/f-ck-need-u/p/7576137.html
Back to Database series article outline: http://www.cnblogs.com/f-ck-need-u/p/7586194.html
Reprint Please specify source: http://www.cnblogs.com/f-ck-need-u/p/8613039.html

Note: If you think this article is not bad please click on the lower right corner of the recommendation, your support can inspire the author more enthusiasm for writing, thank you very much!

File formats for Xtradb/innodb

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.