Home |  MySQL Buzz |  FAQ |  Feeds |  Submit your blog feed |  Feedback |  Archive |  Aggregate feed RSS 2.0 English Deutsch Español Français Italiano 日本語 Русский Português 中文
Showing entries 1 to 27

Displaying posts with tag: failover (reset)

Tungsten University: Unleashing the Power of Tungsten Connectors
+0 Vote Up -0Vote Down
How To Configure Tungsten Connector For Load Balancing, Read/Write Splitting, Automatic Failover And Online Maintenance
MySQL Load Balancing, Read/Write Splitting, Automatic Failover And Online Maintenance
+1 Vote Up -0Vote Down
How To Configure Tungsten Connector For Load Balancing, Read/Write Splitting, Automatic Failover And Online Maintenance  Tungsten clusters use the Tungsten Connector to ensure your applications transparently connect to the master. This enables fail over and seamless switching of masters for online maintenance. However, you can do far more. Tungsten Connector allows you to make better use of
Tungsten University: Configure & provision Continuent Tungsten clusters
+1 Vote Up -0Vote Down
Are you unsure of the steps needed to get your Continuent Tungsten cluster up-and-running? In this virtual course, we will teach you how to get from a single database server to a scalable cluster, or from a brittle MySQL replication system to a transparent, manageable Tungsten cluster.  We will discuss the benefits of leveraging Continuent Tungsten clustering with MySQL, and walk you through the
Webinar Monday, Nov 5th @ 15:00 GMT - MySQL High Availability Realized
+0 Vote Up -0Vote Down
High Availability (HA) ensures all important business information is available for your application even when there is no database failure. This includes: How about when you are upgrading your database schema? What if you need to add memory to a database server or reconfigure/restart MySQL? If your apps want to read data from a MySQL slave, how can you be sure they are not reading stale data
Haute disponibilité MySQL, par Continuent
+0 Vote Up -1Vote Down
La haute disponibilité, c’est garantir aux applications un accès permanent aux données, même en cas de panne. Permanent ? Même lorsque vous mettez à jour le schéma de vos bases ? Que vous ajoutez de la RAM sur un serveur ? Que vous reconfigurez ou redémarrez MySQL ?    Comment lire les données depuis un nœud esclave avec une garantie que les données sont à jour, sans changement applicatif ?
Webinar 10/11: Multi-Master, Multi-Site MySQL Databases Made Easy with Continuent Tungsten
+0 Vote Up -0Vote Down
Cross-site databases are the next challenge facing today's MySQL-based businesses. Continuent Tungsten provides multiple options for spreading data across sites, including primary/DR, multi-master, and system-of-record approaches. Join us to learn how Continuent Tungsten enables replication, failover, and routing of transactions between sites. We cover the following topics: Introduction to
Replication and auto-failover made easy with MySQL Utilities
Employee +3 Vote Up -1Vote Down

If you’re a user of MySQL Workbench then you may have noticed a pocket knife icon appear in the top right hand corner – click on that and a terminal opens which gives you access to the MySQL utilities. In this post I’m focussing on the replication utilities but you can also refer to the full MySQL Utilities documentation.

What I’ll step through is how to uses these utilities to:

  • Set up replication from a single master to multiple slaves
  • Automatically detect the failure of the master and promote one of the slaves to be the new master
  • Introduce the old master back into the topology as a new slave and
  [Read more...]
Automated MySQL Master Failover
+1 Vote Up -0Vote Down
After the GitHub MySQL Failover incident a lot of blogs/people have explained that fully automated failover might not be the most optimal solution.

Fully automated failover is indeed dangerous, and should  be avoided if possible. But a complete manual failover is also dangerous. A fully automated manually triggered failover is probably a better solution.

A synchronous replication solution is also not a complete solution. A split-brain situation is a good example of a failure which could happen. Of course most clusters have all kinds of safe guard to prevent that, but unfortunately also safe guards can fail.

Every failover/cluster should be considered broken unless:
  • You've tested the failover scripts and procedures
  • You've tested the failover scripts and procedures under normal load
  • You've tested the failover scripts







  •   [Read more...]
    Controlled failover simplicity with MySQL
    +3 Vote Up -0Vote Down

    As part of a recent engagement, I described the relative products to manage a MySQL pair (i.e. an Active/Passive MySQL masters configuration). This included the steps to undertake a controlled failover for supporting software maintenance using manual procedures. The upcoming Effective MySQL: Replication Techniques in Depth book details each step and all conditions to review over a dozen pages. While the steps are straightforward and generally well known, scripting this for your environment takes a certain amount of work to ensure your information is correct, and application connectivity loss is kept to a minimum.

    In Continuent Tungsten (which I have just been reviewing these past few weeks), I achieved the same result with a single command.

    $ echo "switch" |
      [Read more...]
    New MySQL 5.6 Replication Utilities – mysqlfailover and mysqlrpladmin
    +3 Vote Up -0Vote Down

    With all of the new news coming out right now, it can be easy to miss or overlook some of the new features.

    While there’s been a lot of talk about MySQL 5.6 Replication, I specifically wanted to mention the new ‘mysqlfailover’ and ‘mysqlrpladmin’ utilities.

    These are two new MySQL replication utilities (results of the new Global Transaction Identifiers (GTIDs) in MySQL 5.6).

    Let me quote the MySQL 5.6 Replication article for both of these utilities:

    mysqlfailover

    “Provides continuous monitoring of the replication topology, enabling failover to a slave in the event of an outage on the master.

    The default behavior is to

      [Read more...]
    Multi-Site, Multi-Master MySQL Databases Made Easy with Tungsten - Webinar 9/22
    +1 Vote Up -0Vote Down
    Cross-site databases are the next challenge facing today's MySQL-based businesses. Continuent Tungsten enables multi-master with an innovative new architecture called System of Record that avoids data conflicts, ensures sites are ready for quick failover, and uses hardware resources efficiently.Watch this video from our 9/22/11 webcast to learn how Tungsten Enterprise enables System of Record
    Howto setup MySQL on a DRBD volume
    +2 Vote Up -0Vote Down
    One more DRBD tutorial, this time I will describe howto setup MySQL with DRBD (Distributed Replicated Block Device). Purpose This document describes how to to setup a failover system with MySQL and DRBD (Distributed Replicated Block Device). Introduction In this tutorial we will setup two Debian Linux nodes with a DRBD volume. MySQL will be [...]
    Cache pre-loading on mysqld startup
    +5 Vote Up -0Vote Down
    The following quirky dynamic SQL will scan each index of each table so that they’re loaded into the key_buffer (MyISAM) or innodb_buffer_pool (InnoDB). If you also use the PBXT engine which does have a row cache but no clustered primary key, you could also incorporate some full table scans. To make mysqld execute this on startup, create /var/lib/mysql/initfile.sql and make it be owned by mysql:mysql
    SET SESSION group_concat_max_len=100*1024*1024;
    SELECT GROUP_CONCAT(CONCAT('SELECT COUNT(`',column_name,'`) FROM `',table_schema,'`.`',table_name,'` FORCE INDEX (`',index_name,'`)') SEPARATOR ' UNION ALL ') INTO @sql FROM information_schema.statistics WHERE table_schema NOT IN ('information_schema','mysql') AND seq_in_index = 1;
    PREPARE stmt FROM @sql;
    EXECUTE stmt;
    DEALLOCATE PREPARE stmt;
    SET SESSION group_concat_max_len=@@group_concat_max_len;
    
    and in my.cnf add a line  [Read more...]
    Quest for Resilience: Multi-DC Masters
    +0 Vote Up -1Vote Down

    This is a Request for Input. Dual MySQL masters with MMM in a single datacentre are in common use, and other setups like DRBD and of course VM/SAN based failover solutions are conceptually straightforward also. Thus, achieving various forms of resilience within a single data-centre is doable and not costly.

    Doing the same across multiple (let’s for simplicity sake limit it to two) datacentres is another matter. MySQL replication works well across longer links, and it can use MySQL’s in-built SSL or tools like stunnel. Of course it needs to be kept an eye on, as usual, but since it’s asynchronous the latency between the datacentres is not a big issue (apart from the fact that the second server gets up-to-date a little bit later).

    But as those who have tried will know, having a client (application server) connection to a MySQL instance in a remote data-centre

      [Read more...]
    Installing MEM agent on a cluster on the logical host
    Employee +0 Vote Up -0Vote Down
    The goal is to have only one entry in the Enterprise Monitor Dashboard that shows the status of the MySQL instance, no matter on which physical server in runs. There are two ways to achieve this:
    • You can install the agent on both physical nodes
    • You can install the agent on a shared storage.
    In either case you have to make sure, that only one agent runs at a time. You have to integrate the agent into your cluster framework. I will not describe how this works, as it is highly dependant on your cluster framework.
    The following description assumes, that you will install the agent on both physical nodes.
  • Install the agent but DO NOT START the agent yet.

  • Edit the [agent-installdir]/etc/mysql-monitor-agent.ini
    In the [mysql-proxy] section add the following line:
    agent-host-id=[logical





  •   [Read more...]
    Installing MEM agent in a cluster on the physical hosts
    Employee +0 Vote Up -0Vote Down
    To install the MEM agent in a way that both physical servers are listed in the MEM dashboard, you have to install the agent on both physical nodes. But: Do not start the agent after the installation!There are three different IDs in MEM: agent-uuid, mysql-uuid and host-id. Usually they are generated automatically and you will never notice these IDs. For more information about the meaning of the different IDs look at this very good explanation from Jonathon Coombes.The agent stores the uuid and the hostid in a MySQL table called mysql.inventory. After a failover the other agent on the new node will notice "wrong" hostid and uuid entries in the inventory table. The agent will stop and ask you to TRUNCATE mysql.inventory. But with this procedure MEM creates a new instance, so all old data is  [Read more...]
    MySQL University session Oct 22: Dual Master Setups With MMM
    +3 Vote Up -0Vote Down

    This Thursday (October 22nd, 13:00 UTC), Walter Heck (of Open Query) will present Dual Master Setups With MMM. MMM (Multi-Master Replication Manager for MySQL) is a set of flexible scripts to perform monitoring/failover and management of MySQL master-master replication configurations (with only one node writable at any time). Session slides (PDF).

    The toolset also has the ability to read balance standard master/slave configurations with any number of slaves, so you can use it to move virtual IP addresses around a group of servers depending on whether they are behind in replication. For more
    information, see mysql-mmm.org.

    For MySQL University sessions you point your


      [Read more...]
    Dogfood: making our systems more resilient
    +0 Vote Up -0Vote Down

    This is a “dogfood” type story (see below for explanation of the term)… Open Query has ideas on resilient architecture which it teaches (training) and recommends (consulting, support) to clients and the general public (blog, conferences, user group talks). Like many other businesses, when we first started we set up our infrastructure quickly and on the cheap, and it’s grown since. That’s how things grow naturally, and is as always a trade-off between keeping your business running and developing while also improving infrastructure (business processes and technical).

    Quite a few months ago we also started investing (mostly time) in the technical infrastructure, and slowly moving the various systems across to new servers and splitting things up along the way. Around the same time, the main webserver frequently became unresponsive. I’ll spare

      [Read more...]
    Failure scenarios and solutions in master-master replication
    +2 Vote Up -0Vote Down

    I’ve been thinking recently about the failure scenarios of MySQL replication clusters, such as master-master pairs or master-master-with-slaves. There are a few tools that are designed to help manage failover and load balancing in such clusters, by moving virtual IP addresses around. The ones I’m familiar with don’t always do the right thing when an irregularity is detected. I’ve been debating what the best way to do replication clustering with automatic failover really is.

    I’d like to hear your thoughts on the following question: what types of scenarios require what kind of response from such a tool?

    I can think of a number of failures. Let me give just a few simple examples in a master-master pair:

    Problem: Query overload on the writable master makes mysqld unresponsive Do nothing.  [Read more...]
    More information about running MySQL on Open HA Cluster / Solaris Cluster
    Employee_Team +0 Vote Up -0Vote Down


    A while ago we published an interview with Detlef Ulherr and Thorsten Früauf about Solaris Cluster / OpenHA Cluster on the MySQL Developer Zone.

    We received a number of followup questions from our readers, requesting more technical background information. For example, Mark Callaghan was wondering about the following:

    • How is failure detection done?
    • How is promotion of a slave to the master done after failure detection?
    • How are other slaves failed to the new master?

    I asked Detlef to elaborate some more on the



      [Read more...]
    How to use JDBC (Connector/J) with MySQL Cluster
    Employee_Team +0 Vote Up -0Vote Down

    Last week I helped a customer setup a JBoss application against MySQL Cluster. It turns out it is not immediately obvious how you should setup our JDBC connector to do loadbalancing and failover. For instance, setting the connector up for an Master-Slave setup (with MySQL Enterprise) is well documented, but not doing the same with MySQL Cluster.

    It's not really properly documented in the manual part, but I found in the changelogs, and confirmed on IRC that to do load-balancing across the SQL nodes in MySQL Cluster, you would use a different JDBC connection string with the "loadbalance" keyword added...



      [Read more...]
    How to use JDBC (Connector/J) with MySQL Cluster
    Employee_Team +0 Vote Up -0Vote Down

    Last week I helped a customer setup a JBoss application against MySQL Cluster. It turns out it is not immediately obvious how you should setup our JDBC connector to do loadbalancing and failover. For instance, setting the connector up for an Master-Slave setup (with MySQL Enterprise) is well documented, but not doing the same with MySQL Cluster.

    It's not really properly documented in the manual part, but I found in the changelogs, and confirmed on IRC that to do load-balancing across the SQL nodes in MySQL Cluster, you would use a different JDBC connection string with the "loadbalance" keyword added...



      [Read more...]
    How to use JDBC (Connector/J) with MySQL Cluster
    Employee_Team +0 Vote Up -0Vote Down

    Last week I helped a customer setup a JBoss application against MySQL Cluster. It turns out it is not immediately obvious how you should setup our JDBC connector to do loadbalancing and failover. For instance, setting the connector up for an Master-Slave setup (with MySQL Enterprise) is well documented, but not doing the same with MySQL Cluster.

    It's not really properly documented in the manual part, but I found in the changelogs, and confirmed on IRC that to do load-balancing across the SQL nodes in MySQL Cluster, you would use a different JDBC connection string with the "loadbalance" keyword added...



      [Read more...]
    Building mysql-proxy-0.6.0 on CentOS-5.2
    +0 Vote Up -0Vote Down

    I recently needed to configure mysql failover on some of our test machines. Thanks to Sheeri’s helpful blog entry which provides a simple failover lua script, configuring failover is a simple matter. However, the machines are running centos-5.2 and centos doesn’t provide an rpm for mysql-proxy. This blog entry describes how to build your own.

    The latest mysql-proxy (0.6.1) is apparently not backward-compatible with 0.6.0 and earlier. It incorrectly handles the case when one of the backend machines is down. Instead of just marking it as down, it errors out completely. This makes it rather difficult to use it for failover scenarios. People have complained about this for a while. Bugs

      [Read more...]
    MySQL Replication Tips And Tricks
    +0 Vote Up -0Vote Down

    Until recently, I was a student employee at the Oregon State University Open Source Lab. My career there ended, like many, with that painful process known as graduation. I got invaluable experience at the lab, not the least of which being the knowledge gained as their main (only) database administrator. One of my great pleasures in that position, was learning how to configure MySQL replication and manage clusters of replicating database servers. Even the simple case of a single master and a single slave has its edge cases.

    read more

    Simple MySQL Proxy Failover
    +0 Vote Up -0Vote Down

    mysql-proxy defaults to round-robin load balancing. There are fancy tricks around to get mysql-proxy to balance connections based on how many idle connections there are in a proxy-based connection pool.

    But there is no code that I found that would simply load balance based on “always go to one server, go to another server only when the first server is down.”

    Well, I spent way too long figuring this out today, again running into the problem where the manual hasn’t been updated. I have indeed made a Forge snippet of this code, but it does not hurt to post it here.

    This was in fact taken from

      [Read more...]
    High Performance MySQL, Second Edition: Replication, Scaling and High Availability
    +0 Vote Up -0Vote Down

    Continuing in the tradition, which I hope has been as helpful to you as it has been to me, I'm opening the floor for suggestions on chapter 9 of the upcoming High Performance MySQL, Second Edition. Unlike the other chapters for which I've listed outlines, this one isn't substantially written yet. It's in detailed outline form at this point (a tactic that has worked very well for us so far -- I'll write about that someday).

    I'm trying to get feedback much earlier in this chapter's lifecycle, for several reasons. Two of the most important are that this is one of the first chapters I've had a chance to really take from scratch, and the chapters I haven't written from scratch have been harder to organize, as you've probably seen from the last few outlines I posted. There's a lot of value in working top-down on this deep encyclopedia-style material.

    Read on for the outline and more thoughts I just can't keep to myself.

    Showing entries 1 to 27

    Planet MySQL © 1995, 2013, Oracle Corporation and/or its affiliates   Legal Policies | Your Privacy Rights | Terms of Use

    Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.