3

I want to run MySQL on Ceph, and I did the follow step to achieve my goal.

(Method one)Using Ceph RBD interface:

  1. Install MySQL and Ceph
  2. Deploy Ceph environment, create a Ceph pool and create Ceph RBD device based on Ceph pool
  3. Mount XFS on RBD device
  4. Change the MySQL data directory to the directory of RBD device.

(Method two)Using CephFS interface:

  1. Install MySQL and Ceph
  2. Deploy Ceph environment, create two Ceph pools and mount CephFS
  3. Change the MySQL data directory to the directory of CephFS.

And then I achieved the goal of running MySQL on Ceph. I didn’t modify any MySQL codes. Is it that simple ?

I read the librbd.h and libcephfs.h. If I modify the code of MySQL filesystem IO interface, is that any differences between the version of modifying the MySQL or not modifying the MySQL code ?

I thought this question a lot but didn’t figure it out. Hope getting some help. Thanks.

李昊华
  • 31
  • 2
  • 1
    Why do you want to do it? For high availability of your MySQL data? Maybe, better will be to make high-available MySQL cluster (Galera of PerconaDB)? – Max Kochubey Jul 08 '18 at 07:00

0 Answers0