Re: Partitioning or indexing for millions of records
Posted by:
Rick James
Date: November 30, 2013 01:30PM
> 20% of 4GB RAM(3.1GB for use)
Use:
key_buffer_size = 600M
(G = giga- = billion = 1e9; M = million = 1e6)
After changing my.ini, restart mysqld.
> every 15 minute you are going to insert 30,000 records
> batch insert statement
That is the best approach.
> INSERTs and SELECTs block each other.
To minimize blockage, use batches of 100-1000 records at a time. (Do not do 30K at once -- too much blockage, and very little speedup for the INSERT.)
> And yes we are going to purge old data also.
How long will you keep the data? Design the PARTITIONs as discussed in my link;
1 month: ~33 daily partitions
1 quarter: ~15 weekly partitions
1 year: ~14 monthly partitions
(etc).
Subject
Views
Written By
Posted
3161
November 26, 2013 05:44AM
2359
November 27, 2013 12:39PM
1888
November 28, 2013 12:40AM
1976
November 28, 2013 09:07PM
1869
November 29, 2013 04:11AM
Re: Partitioning or indexing for millions of records
1818
November 30, 2013 01:30PM
1635
December 31, 2013 11:34AM
Sorry, you can't reply to this topic. It has been closed.
This forum is currently read only. You can not log in or make any changes. This is a temporary situation.
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.