MySQL Forums
Forum List  »  Memory Storage Engine

MySQL Inserting into Memory table triggers heavy disk activity
Posted by: Allan Poulsen
Date: October 16, 2019 03:55AM

I am confused. I am creating a Memory table in my Schema:

CREATE TABLE `memory_words` (
`word` varchar(128) NOT NULL ,
`COUNT` int NOT NULL,
PRIMARY KEY (`WORD`)
) ENGINE=Memory DEFAULT CHARSET=utf8MB4;

I am doing a lot of inserts into the table, for later statistics work. When monitoring the process, I see that my MySQL-server is starting a lot of writes to disk. Why? When using a Memory table, disk I/O should not be present?

The SQL for inserting (upserting) is:

INSERT INTO memory_words (word,COUNT) VALUES (_cleanstring,1) on duplicate key update COUNT=COUNT+1;

The MySQL Server is hosted on a Local Docker-Server and is mine alone, so I can rule out that the disk I/O is triggered by other than me. The server has enough resources to hold the Memory-Table.

Do I need to any config on table or server, to prevent disk I/O with Memory-tables?

Thanks in advance Allan

Options: ReplyQuote


Subject
Views
Written By
Posted
MySQL Inserting into Memory table triggers heavy disk activity
1194
October 16, 2019 03:55AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.