3

We're currently using EC2 with 16 EBS volumes in RAID10 configuration for our MySQL data. I know some people don't recommend to put EBS volumes to RAID but that's not what I'm concerned about at the moment. Current format is ext3, but we're experimenting with moving to xfs, given many reports that it is faster. However, we're actually experiencing a performance degradation when the partition was converted to xfs - a benchmark run with inserts, updates, selects and deletes was more than 10 seconds slower using xfs.

Any idea what could be the problem? Below is the fstab entry (really only changed ext3 to xfs). Database tables are innodb and we are using innodb_file_per_table.

/dev/mapper/vg_data-lv_data /data xfs noatime 0 0

Thanks.

ewwhite
  • 201,205

4 Answers4

1

XFS was slow on meta-data operations till 2.6.39, IIRC. Traditionally for this site you didn't mention what version of your server's kernel was. So we're only to guess now.

poige
  • 9,730
  • 3
  • 28
  • 53
1

An acquaintance working for Percona (www.percona.com) suggested using the nobarrier mount option. It sped things up a lot.

1

The XFS filesystem always requires tuning. Running a default mkfs and mount will result in so-so performance. You'll want to set your allocation group number at filesystem creation time. Disabling write barriers may make sense. Also pay close attention to your filesystem usage and mount options on the specific kernel series you're using. Some interesting defaults were recently backported.

Also check your I/O elevator settings. Take a look at some of the recommendations at: CentOS 6 doing lots more IO than CentOS 5

ewwhite
  • 201,205
0

Take a look slides from Pinterest guys: https://www.percona.com/live/mysql-conference-2015/sites/default/files/slides/all_your_iops_are_belong_to_usPLMCE2015.pdf

Few examples:

Kernel 3.13 + EXT4

4K RAID block, EXT4, kernel 3.13 Write throughput 87MB/sec 99th-percentile latency: 124ms

64K RAID block, EXT4, kernel 3.13 Write throughput 88MB/sec 99th-percentile latency: 122ms

Kernel 3.18 + XFS

4K RAID block, XFS, kernel 3.18 Write throughput 550MB/sec 99th-percentile latency: 3.7ms

64K RAID block, XFS, kernel 3.18 Write throughput 650MB/sec 99th-percentile latency: 6.2ms

Anatoly
  • 576