Huge memory usage on INSERT INTO ... SELECT
Bug #898570 reported by
Adrian Partl
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Spider for MySQL |
Fix Released
|
Medium
|
Kentoku SHIBA |
Bug Description
We have 8e9 rows in a Spider table, distributed over 4 mysql nodes.
If we now want to copy that data from one Spider table on the head
node to another Spider table (again distributed over 4 mysql nodes)
using
INSERT INTO foo SELECT * FROM huge_spider_table
the head node will use up all memory and eventually crash.
It seams, that the Spider engine first copies all the data retrieved
by the SELECT into memory and then passes that on to the new
table.
Possible resolution:
- Stream and buffer results from the huge_spider_table to the new
one, bypassing the need to have everything in memory.
- use on disk temporary table
Changed in spiderformysql: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
Fixed at 2.28.
Please try "quick_mode = 3".