Xaprb

Stay curious!

Archive for the ‘Ryan Lowe’ tag

Learn how to achieve PCI compliance with MySQL

without comments

One of my colleagues, Ryan Lowe, has just heard that his session on PCI compliance with MySQL has been accepted at the upcoming MySQL conference. Ryan is highly qualified to present this topic, and not many people can say that; I certainly can’t claim that title myself. If you’re looking to learn how to make your MySQL installation PCI-compliant, there’s also not a lot of trustworthy information online. Personally — and really, no bias just because he’s my colleague — I think this is a great session for the MySQL conference, which I sometimes thought didn’t have enough diversity of topics in past years. We need more stuff like this to give people a reason to return after they’ve gone for 2 or 3 years in a row.

Written by Xaprb

March 3rd, 2010 at 12:04 pm

Formatting mysqladmin extended-status nicely

with 3 comments

I always say that the ultimate MySQL tuning script is an expert human. To that end, I generally try to build tools that help a human be more productive with the raw information from MySQL. One of the things we look at during a performance audit is the MySQL status counters. It’s useful to look at a) absolute values and b) several incremental snapshots. I’ve written a small shell script called “mext” that can make this a little easier.

It looks like this:

baron@kanga:~$ mext -- mysqladmin ext -ri1 -c3
Aborted_clients                               1      0      0
Aborted_connects                              0      0      0
Binlog_cache_disk_use                         0      0      0
Binlog_cache_use                              0      0      0
Bytes_received                             1167     35     35
Bytes_sent                                38926   6337   6337
....

This isn’t an original idea. Ryan Lowe made a Perl version of this first. I used his version for a while, but after working on a few machines that didn’t have the necessary Perl libraries (maybe one of them didn’t even have Perl, I forget) I decided to do it in shell.

There’s an added feature. It’ll do incremental/differential/relative output for you. The mysqladmin that ships with MySQL 5.1 has a bug that stops it from iterating with -r. So the script I wrote can accept a -r option, which can then be left off the arguments to mysqladmin:

baron@kanga:~$ mext -r -- mysqladmin ext -i1 -c3

It’s kind of a generic tool that you could use with other things besides mysqladmin, but it’s also kind of tweaked for that purpose. You can get mext here.

Written by Xaprb

April 11th, 2009 at 11:41 am

Posted in Coding,SQL,Tools

Tagged with , ,