In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article will explain in detail how to understand the innodb_file_per_table parameter in MySQL. The content of the article is of high quality, so Xiaobian shares it with you for reference. I hope you have a certain understanding of relevant knowledge after reading this article.
When creating a table in MySQL, if innodb_file_per_table is ON, two files tablename.frm and tablename.ibd are generated.
If innodb_file_per_table is OFF, only one file tablename.frm will be generated, and the data of this table will be stored in the file ibdata*.
mysql> show variables like '%per_table%';
+---------------------------+-------+
| Variable_name | Value|
+---------------------------+-------+
| innodb_file_per_table | ON |
+---------------------------+-------+
mysql> use vast
mysql> create table testtbs(a int,b int);
mysql> insert into testtbs select 1,2;
mysql> insert into testtbs select 3,4;
[root@vast vast]# pwd
/data/mydb/vast
[root@vast vast]# ls *testtbs*
testtbs.frm testtbs.ibd
mysql> show variables like '%per_table%';
+---------------------------+-------+
| Variable_name | Value|
+---------------------------+-------+
| innodb_file_per_table | OFF |
+---------------------------+-------+
mysql> create table testtbs1(a int,b int);
mysql> insert into testtbs1 select 1,2;
mysql> insert into testtbs1 select 3,4;
[root@vast vast]# pwd
/data/mydb/vast
[root@vast vast]# ls *testtbs1*
testtbs1.frm
About how to understand MySQL innodb_file_per_table parameter to share here, I hope the above content can be of some help to everyone, you can learn more knowledge. If you think the article is good, you can share it so that more people can see it.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.