I’m returned from my 1-week vacation today and want to say - I’ve never been so productive as I was there
Blue ocean, hot sun and white sand really helped me to finish my work on the first release of one really awesome project.
Today I’m proud to announce our first public release of the Data Recovery Toolkit for InnoDB - set of tools for checking InnoDB tablespaces and recovering data from damaged tablespaces or from dropped/truncated InnoDB tables.
Today I was working on one small consulting task and our client asked for an upgrade from MySQL 5.0 to 5.1. It was pretty easy and task was successfully finished and reported to the customer… But few hours after my report I’ve got an email from customer with something like “WTF? Where is my 5.1?!”. I was shocked when I saw happily running 5.0 on their server w/o anything related to my 5.1 installation…
After some short investigation I’ve found out, that it was cpanel (dumb software for dumb system administrators) - it noticed, that installed mysql version (5.1) is not the same as it thought it should be (5.0), so without any warnings or notices it removed all 5.1 rpms and installed “brand new” 5.0.
Here I’d like to say GREAT THANKS to mysql team for such a great software which did not screwed up user’s data in such situation. But what idiots in cpanel development team decided, that is it appropriate and acceptable to perform such operations?! As an administrator and as a software developer I do not understand them - I just can’t understand such approach….
So, enough complaining - here is a piece of useful information for my readers: If you’re so unlucky to have cpanel installed on your server and you’d like to upgrade your mysql manually, then you can perform following operations:
After these small changes your cpanel will forget about mysql upgrades and you’ll be able to do what you want and not what some dumb developers decided you should do.
It’s been a long time since we’ve started this project and it is time to make a checkpoint. So, I’ve decided to release final 1.0 version and make 1.X branch stable while all serious development with deep architectural changes will be done 2.X branch (trunk at this moment).
Changes from previous release:
New version can be obtained here or from the project’s SVN repository.
Tags: mysql, master-master, replication, release, development
open-source: del.icio.us tag/open-source
Operating
linux
emulator
Windows
systems
open-source
emulate
MySQL Master-Master Replication Manager version 1.0-pre3 has been released today. Changes list is really short now:
As always, if you have any questions/suggestions, post them here or in mmm-devel mail list.
Tags: mysql, master-master, replication, release
Despite of my high load at work I decided to release mmm-1.0-pre2 today. There are some small, but critical fixes added and much more coming next week (or little bit later if mysqlconf will take more time than I think).
After the first alpha release I’ve received lots of emails, some messages in mmm-devel mail list and even some bug reports in Google Code bug tracking. One of the most asked things was documentation.
So, I decided to write some posts in this blog (sorry to non-sql-related readers) and them compose some docs for final release using these posts and comments from readers. This post will be first in mmm-series and will describe how to use mmm in simple master+master scheme where one master accept write requests and both masters accept read requests. This post will provide you with detailed instructions about MySQL setup, permissions setting, mmm installation and configuration and cluster management.
All my example configs in this article will be based on the following network infrastructure:
All servers are connected to the same switched network.
Before you’ll begin your setup, take a looks at the following list of prerequisites for each server in your cluster to be sure that you have all mentioned packages/modules/etc.
Each of mysql servers in the cluster should have iproute2 package to let mmm manage IP addresses on these servers with ip command. As for perl modules, you can run install.pl script and it’d say what do you need to add to your system before installation will be possible.
First of all, you need to setup both of your MySQL servers to replicate data from each other. Example configs are following:
my.cnf at db1 should have following options:
my.cnf at db2 should have following options:
Replication settings (db1):
Replication settings (db2):
After all these operations were made your servers will have SHOW SLAVE STATUS results like following:
Each mysql server should have one mmmd_agent running on it. To set them up you will need to install mmm as following:
After mmm installation you’ll need to configure your agents.
db1 config /usr/local/mmm/etc/mmm_agent.conf:
db1 config /usr/local/mmm/etc/mmm_agent.conf:
Now you can run mmmd_agent on each server and your servers would be ready for management with mmm.
When everything is done on mysql servers, you are ready to set up monitoring node which of course could be combined with some web-server node or another services - dedicated hardware is not required. Before configuration step you’ll need to install mmm just as it was done on mysql servers. Then you’ll need to create configuration file for mmmd_mon program which would monitor your nodes. Config file for our example scheme could be like following:
Config file for monitoring node - /usr/local/mmm/etc/mmm_mon.conf:
With this configuration file you will get 3 interface IP addresses used to “speak” with your cluster:
Before you’ll start your monitoring part of the cluster, you need to be sure what mmm_mon will be able to connect to your servers with credentials from mmm_mon.conf file (run this command on one node and, if your replication was set up correctly (you’ve already tested it, right?), another server will get this statement by replication:
When your configuration will be finished and mmmd_mon will be started, you obviously would need to take a look at mmm_control script which is small program dedicated to sending commands to mmmd_mon process and output results in nice format. To view its params info you can start it without any parameters. At this moment you can use following commands:
When your mmmd_mon script will be started first time, it will think what all servers were offline and now they came back. So, initial status of all servers will be set to AWAITING_RECOVERY and you’ll need to put both servers to ONLINE:
So, that’s it. If you have any questions or suggestions, you can leave then in comments below or post them to mmm mail list.