Questions tagged [innodb]

InnoDB is the main ACID-compliant Storage Engine used in MySQL.

InnoDB is the ACID-compliant Storage Engine used in MySQL. InnoDB also features the use for MVCC (Multiversion Concurrency Control) to support Transaction Isolation Levels for InnoDB. InnoDB is not a standalone database product. It has been distributed as a part of the MySQL database during its early years of InnoBase Oy as a partner with MySQL AB.

In the early days of MySQL, InnoDB was made available to MySQL as an additional transactional storage along with BDB. The company that developed InnoDB, InnoBase Oy, was purchased by Oracle in October 2005. Percona has contributed great improvements to its own Open Source version of InnoDB (XtraDB). Oracle, who eventually became the owner of MySQL via purchasing Sun, has incorporated most of those changes into InnoDB, as well adding improvements of their own. As a result, InnoDB has transformed into a more mature storage engine that handles mulitprocessing and multithreading more robustly. As of December 2010, InnoDB has become the default storage engine for MySQL 5.5.

MySQL 5.5 also has enhancements to facilitate InnoDB in engaging multiple CPUs. Those enhancements were introduced in MySQL 5.1.38 in the InnoDB Plugin only. Those enhancements have now been included with MySQL 5.5.

MySQL 5.5 also comes with new features such as Semisynchronous Replication, Multiple InnoDB Buffers Pools, plugins for user-defined authentication, performance metrics instrumentation, and more !!!

In a recent Oracle press release, one of the new features for MySQL 5.6 is to have InnoDB with FULLTEXT searching. This will be a major step forward for this storage engine as this was one of the most requested and sought after features.

The basic infrastructure of InnoDB centers around three major files

  • ibdata1
  • ib_logfile0
  • ib_logfile1

In conjunction with memory structures, ibdata1 processes info for 6 basic data structures

  • Table Data Pages
  • Table Index Pages
  • Table MetaData (List of Tablespave IDs + Misc Info)
  • MVCC Records
    • Rollback Segments
    • Undo Space
  • Double Write Buffer (Allows Background Page Writes)
  • Insert Buffer (For Collecting/Processing Changes to Secondary Indexes)

Configurations can accommodate

  • Separating Table Data and Index Pages
  • Storing ibdata1 in a Raw Disk Partition
  • Creating Multiple ibdata Files
  • Creating multiple Log Files
  • and more...

There is important cache known as the InnoDB Buffer Pool. As of MySQL 5.5, you can configure multiple buffer pool instances. Prior to MySQL 5.5, there is only one buffer pool instance.

388 questions
0
votes
1 answer

Column locking in innodb?

I know this sounds weird, but apparently one of my columns is locked. select * from table where type_id = 1 and updated_at < '2010-03-14' limit 1; select * from table where type_id = 3 and updated_at < '2010-03-14' limit 10; the first one would…
mingyeow
0
votes
1 answer

Mysql- “FLUSH TABLES WITH READ LOCK” started automatically

I would like to understand how this happened. I was running a query that would take a long time, but should not lock up any table. However, my dbs were practically down - it seems like it was being locked up by "FLUSH TABLES WITH READ LOCK" 03:21:31…
mingyeow
0
votes
1 answer

Should I upgrade memory for my dedicated server?

My memory usage hangs around 25% (swap is generally 1%) on my dedicated server and load is around 2-5. My host recommended that I upgrade from 2GB of ram to 4GB so that I can increase my innodb_buffer from the default 16MB to 2GB. My innodb table…
mk1000
  • 255
  • 1
  • 3
  • 4
0
votes
0 answers

SQL Error (1114): The table 'global_priv' is full

I can no longer add users to my database. I only get the error: SQL Error (1114): The table 'global_priv' is full I researched this issue, and the my.ini config for innodb_data_file_path did not have a cap. But I also tried setting it to 2GBs, but…
Codesmith
  • 111
  • 5
0
votes
1 answer

Kubernetes InnoDBCluster: all pods should share one PersistentVolumeClaim?

Kubernetes InnoDBCluster: all pods should share one PersistentVolumeClaim? Following: https://dev.mysql.com/doc/mysql-operator/en/mysql-operator-innodbcluster-simple-kubectl.html kubectl create namespace mysql-cluster-test kubectl create secret…
0
votes
0 answers

Unable to Recover MySQL Database [Missing FILE_CHECKPOINT]

Using MariaDB 10.7.3 via Homebrew on MacOS Monterey 12.6.1 While trying to recover the database after a system crash, I am stuck with the following situation. [Note] mysqld (server 10.7.3-MariaDB) starting as process 41828 ... [Warning] Setting…
Rawkon
  • 11
  • 3
0
votes
1 answer

MySQL + php due to high CPU usage app crashing

Just recently the application that I maintain started crashing, mysql's CPU usage is 100%... or more :) The application itself is quite old and has a lot of slow queries but before blaming it I want to check if it's not the mysql issue. I hate to…
Maarduk
  • 133
  • 6
0
votes
1 answer

ERROR 1034 (HY000): Incorrect key file for table 'mytable'; try to repair it

After upgrading mysql from 5.5 to 5.7, a compressed innodb database seems corrupted. I followed the method in this post to create a new database/table, drop the tablespace, copy the old .ibd file, then import the tablespace with ALTER TABLE mytable…
peter
  • 93
  • 13
0
votes
1 answer

mysql crashes when accessing database after upgrade from 5.5 to 5.7

After upgrading mysql from 5.5 to 5.7, one of innodb databases seems corrupted. mysqldump -u root -p mydatabase > mydatabase.sql Enter password: mysqldump: Error: 'Lost connection to MySQL server during query' when trying to dump…
peter
  • 93
  • 13
0
votes
1 answer

How to remove orphaned foreign key constraint in MySQL?

Using MySQL 5.5. I have a table for which I can't add a foreign key: ALTER TABLE `SOURCE_TABLE` ADD CONSTRAINT `ConstraintFK` FOREIGN KEY (`otherTableID`) REFERENCES `OTHER_TABLE` (`id`) ON DELETE SET NULL ON…
Mauro Molinari
  • 202
  • 2
  • 3
  • 11
0
votes
1 answer

MariaDB High CPU load after Crash

I have a problem with MariaDB 10.3.16. I was trying to convert a rather large table (26GB) from MyISAM to InnoDB and unfortunately the disk space ran out during this process. When it got full, it logged plenty messages like this: 2022-03-25 0:03:54…
Nuramon
  • 150
  • 2
  • 10
0
votes
0 answers

mysql service crash (ubuntu server)

mysql service craches and the server becomes down everyday or every two days and I do not know the reason (I am using apache and innodb). mysql error log: 2022-03-12 11:11:22 140142364764096 [Note] InnoDB: Mutexes and rw_locks use GCC atomic…
0
votes
1 answer

Failed to Import MySql database from phpMyAdmin as well as Command line

Well, I have tried to import small size database, it works. However, when I am about import a large database it shows the following error from phpMyadmin. Static analysis: 1 errors were found during analysis. Missing expression. (near "ON" at…
Krishna
  • 1
  • 2
0
votes
1 answer

Completely Disable InnoDB in MariaDB 10.6

Not really sure whether to ask this here or at dba.stackexchange.com but I figured here might be more appropriate since it's a server config issue. I have a brand new MariaDB 10.6.5 install on Ubuntu 20.04 I've used MariaDB's own repositories that…
Sledge Hammer
  • 143
  • 10
0
votes
1 answer

OPTIMIZE TABLE innodb file per table while system is running

I had an 800 GB Moodle mdl_logstore_standard_log.ibd database file. I deleted around 900 million rows in 10-15 days. The .idb file was around 800GB and still the same size after deletion. I want to optimize the table so I can fix this. Is it safe to…
1 2 3
25
26