How to remove database in a safe way

(Originally posted in kinja ops blog)

When you have to drop a large database, you’ll encounter some problems, mainly replication lag. Now I’ll show you how to avoid this.

What can cause replication lag when you drop a database? First, it takes some disk I/O to unlink the files, and secondly MySQL will scan through the buffer pool to see if there are pages from that database or not. On a huge (or at least big) database this could take seconds or even minutes, what means your slaves will collect lag for seconds or (of course) even minutes.

Continue reading “How to remove database in a safe way”

Share This:

Mambocollector – MySQL -> statsd data collector

(Orignally posted in kinja ops blog)

We love graphs.

Really love them. I think everyone likes graphs to collect data about the current state of their system, and needless to say, why.

Of course sometimes it is painful to create graphs, but graphite could make this process more easy, so we use them.

The graphite ecosystem makes data collection simple, when you send some data to statsd via simple udp packets it will put them to a carbon database, and graphite will draw the lines. The only thing what can make this hard, is the question about ‘How can I collect my data to send?’

Continue reading “Mambocollector – MySQL -> statsd data collector”

Share This: