Building MySQL Cluster on Windows (for Windows)

You will need:

  • CMake (at least 2.4.7)
  • Bazaar (the newer the better – 1.6 was just released – at least use that)
  • Gnu Bison
  • Visual Studio (Express works, but I’m talking about 2005 here)
  • … and all this installed on a Microsoft Windows machine.
  • … and to hate yourself, you are going to be using Windows after all.

Then, get and build it:

  1. Get the source:
    bzr branch lp:~mysql/mysql-server/mysql-5.1-telco-6.4-win
  2. Run CMake. the CMake GUI can now be used to select compile options! You’ll have to set the path “where is the source code” to where you put the source code in step 1.
  3. Hit “Configure” in CMake
  4. Select the target (i.e. the version of Visual Studio you’re going to use)
  5. Select the build options. HINT: WITH_NDBCLUSTER_STORAGE_ENGINE may be a useful one to enable
  6. Hit Configure again
  7. Hit Ok.
  8. CMAKE now generates the Visual Studio project. Use this time to drink some good scotch.
  9. Open Mysql.sln (which should launch Visual Studio)
  10. Go Build -> Build Solution (or hit F7)

Now you can go and have much whisky as this will take a few minutes. You should now have a set of built binaries for MySQL Cluster on Windows. Scary.

8 thoughts on “Building MySQL Cluster on Windows (for Windows)

  1. This is great! We’re in need of MySQL cluster on Windows (don’t ask why). Will this be an official binary supported and available on mysql.com?

  2. Awesome!

    So here’s my question about this. We currently run Windows for some .NET services. But we use MySQL for our DB. We want to implement clustering to get some redundancy. That would require us to move to 4 boxes (2 windows and 2 linux.) That’s a lot more money than just 2 boxes, each with Windows/MySQL on them. We could do the latter with MySQL clustering for Windows.

    So I’m curious of your opinion of using this build to enable MySQL clustering on Windows. Do you think it’s at a reliable enough stage to move it into business-critical production? Thanks!

  3. It would (currently) be a very bad idea to run NDB on Windows in production. I’d wait until we do a Cluster 6.4 release before moving it into production.

    But I’d certainly welcome the testing and feedback before then!

  4. Rebuild mysql cluster with source code will generate mysql cluster API include files and library files at the same time? I’d like to use mysql cluster API to develop some programs on windows, but I have not found the appropriate library files, that made me so sad! If know something, please give a hand, thanks.

  5. It’s been a long time since I developed MySQL Cluster on Windows, but the current binaries up on the MySQL web site should contain the binaries needed to build ndbapi apps.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.