Backup and Recovery Manager Release Notes

Taxonomy upgrade extras: 
  • Backup and Recovery Manager 2.3.2 Release Notes, Release Date: 10 July 2025
  • Backup and Recovery Manager 2.3.1 Release Notes, Release Date: 12 August 2024
  • Backup and Recovery Manager 2.3.0 Release Notes, Release Date: 25 June 2024
  • Backup and Recovery Manager 2.2.5 Release Notes, Release Date: 23 February 2022
  • Backup and Recovery Manager 2.2.4 Release Notes, Release Date: 26 July 2021
  • Backup and Recovery Manager 2.2.3 Release Notes, Release Date: 13 January 2021
  • Backup and Recovery Manager 2.2.2 Release Notes, Release Date: 8 October 2020
  • Backup and Recovery Manager 2.2.1 Release Notes, Release Date: 5 August 2019
  • Backup and Recovery Manager 2.2.0 Release Notes, Release Date: 25 July 2019
  • Backup and Recovery Manager 2.1.0 Release Notes, Release Date: 22 February 2019
  • Backup and Recovery Manager 2.0.0 Release Notes, Release Date: 27 June 2018
  • Backup and Recovery Manager 1.2.5 Release Notes, Release Date: 1 May 2017
  • Backup and Recovery Manager 1.2.4 Release Notes, Release Date: 12 January 2017
  • Backup and Recovery Manager 1.2.3 Release Notes, Release Date: 1 October 2016
  • Backup and Recovery Manager 1.2.2 Release Notes, Release Date: 29 May 2015
  • Backup and Recovery Manager 1.2.1 Release Notes, Release Date: 18 January 2015
  • Backup and Recovery Manager 1.2.0, Release Date: 24 September 2014
  • Backup and Recovery Manager 1.1.1, Release Date: 4 September 2014
  • Backup and Recovery Manager 1.1.0, Release Date: 11 August 2014
  • Backup and Recovery Manager 1.0.4, Release Date: 15 April 2014
  • Backup and Recovery Manager 1.0.3, Release Date: 3 April 2014
  • Backup and Recovery Manager 1.0.2, Release Date: 10 December 2013
  • Backup and Recovery Manager 1.0.1, Release Date: 4 November 2013
  • Backup and Recovery Manager 1.0, Release Date: 30 September 2013
  • Backup and Recovery Manager 0.4, Release Date: 30 March 2011
  • Backup and Recovery Manager 0.3.6, Release Date: 23 January 2011
  • Backup and Recovery Manager 0.3.5, Release Date: 22 January 2011
  • Backup and Recovery Manager 0.3.4, Release Date: 21 November 2010
  • Backup and Recovery Manager 0.3.3, Release Date: 21 November 2010
  • Backup and Recovery Manager 0.3.2, Release Date: 14 November 2010
  • Backup and Recovery Manager 0.3.1, Release Date: 14 November 2010
  • Backup and Recovery Manager 0.3, Release Date: 13 November 2010
  • Backup and Recovery Manager 0.2.7, Release Date: 12 August 2010
  • Backup and Recovery Manager 0.2.6, Release Date: 12 August 2010
  • Backup and Recovery Manager 0.2.5, Release Date: 12 August 2010
  • Backup and Recovery Manager 0.2.4, Release Date: 12 August 2010
  • Backup and Recovery Manager 0.2.3, Release Date: 19 January 2010
  • Backup and Recovery Manager 0.2.2, Release Date: 7 January 2010
  • Backup and Recovery Manager 0.2.1, Release Date: 31 December 2009
  • Backup and Recovery Manager 0.2, Release Date: 24 December 2009
  • Backup and Recovery Manager 0.1.1, Release Date: 18 July 2008
  • Backup and Recovery Manager 0.1, Release Date: 18 July 2008

MariaDB/MySQL Environment MyEnv 3.0.0 has been released

FromDual has the pleasure to announce the release of the new version 3.0.0 of its popular MariaDB, MySQL and PostgreSQL multi-instance environment MyEnv.

FromDual Performance Monitor 2.2.1 has been released

FromDual has the pleasure to announce the release of the new version 2.2.1 of its popular Database Performance Monitor for MariaDB, Galera Cluster, MySQL and PostgreSQL fpmmm.

What is the quickest way to load data into the database?

We had some really exciting problems to solve for the last customer! Especially because the database wasn’t exactly small.

Marko Mäkelä mentioned you on MDEV-38779

Taxonomy upgrade extras: 

[~oli], thank you for your report. There already was an existing report MDEV-38671 about mostly the same, namely that the {{innodb_buffer_pool_size}} cannot be increased anymore when MariaDB Server has been started with the default settings.

MariaDB has broken the concept of dynamically configurable buffer pools!

Taxonomy upgrade extras: 

Problem description

MySQL introduced the dynamically configurable InnoDB buffer pool with 5.7.5 in September 2014 (here and here):

How much space does NULL need?

The last time I consulted a customer, he came up to me beaming with joy and said that he had taken my advice and changed all the primary key columns from BIGINT (8 bytes) to INT (4 bytes) and that had made a big difference! His MySQL 8.4 database is now 750 Gbyte smaller (from 5.5 Tbyte). Nice!

Someone is deleting my shared memory segments!

Taxonomy upgrade extras: 

When we work with PostgreSQL under our myEnv, we regularly get shared memory segment errors. Example:

Load CSV files into the database

Recently, I wanted to display the places of residence of the members of my club on a map for a personal gimmick (IGOC members). I knew the addresses of the club members. But not the coordinates of their places of residence.

MariaDB/MySQL Environment MyEnv 2.1.1 has been released

FromDual has the pleasure to announce the release of the new version 2.1.1 of its popular MariaDB, Galera Cluster and MySQL multi-instance environment MyEnv.

MariaDB Honeypot

Taxonomy upgrade extras: 

In our MariaDB advanced training courses, which we hold approximately every two months, we use machines that are directly exposed to the Internet with a public IP address. Warning: You should NEVER expose a database directly to the Internet without protection! Typically, it takes less than 72 hours (3 days) before we are exposed to the first external access attempts.

How does Galera Cluster behave with many nodes?

Recently I had the opportunity to have a lot of Linux systems (VMs with Rocky Linux 9) from one of our regular Galera Cluster trainings all to myself for a week. And MariaDB 11.4.4 with Galera Cluster was already installed on the machines.

Model v2 slightly improves results

Taxonomy upgrade extras: 

We have improved our model (see v2) so the results are a bit better/more accurate now.

Playing with MariaDB Vector for initial AI tests

Taxonomy upgrade extras: 

Artificial intelligence (AI) and vector databases are on everyone’s lips these days. Since MariaDB will soon be coming onto the market with vector database functionality, as a database consultant I thought it was about time I got to grips with the subject so that I have at least a hint of what it’s all about…

Partial physical database restore for MariaDB and MySQL

Taxonomy upgrade extras: 

What is it about?

When describing backup and restore scenarios, a full backup and a full restore of the database instance (mariadbd/mysqld) are usually assumed. This means that the entire database instance, including all databases (schemas), is backed up and restored.

Shrinking the InnoDB system tablespace

Taxonomy upgrade extras: 

One feature that really excited me in the new MariaDB 11.4 LTS release is the shrinking of the system tablespace (ibdata1). I have been eagerly waiting for this feature since around 2006 and now it has finally arrived with MariaDB 11.4. Actually, this feature has been available since MariaDB 11.2 IR (June 2023).

Migration Problem mysql 5.7 to mariadb/galera

Taxonomy upgrade extras: 

Hi dcz01

No it is not solved… It is closed and “not a bug”… I try to intervene

Migration Problem mysql 5.7 to mariadb/galera

Taxonomy upgrade extras: 

Hi Oli, Thanks for your answer. The problem is already open and solved but not for me and its still not working: https://jira.mariadb.org/browse/MDEV-28172

Possibly a bug

Taxonomy upgrade extras: 

Hello dcz01

I would say, this is probably a bug. I can reproduce it on my system (MySQL 5.7 Master and MariaDB 10.6 Galera Cluster).

Migration from mysql 5.7 to MariaDB 10.5 with Galera 4 Problems

Taxonomy upgrade extras: 

Hi, we are migrating some old mysql 5.7 servers to new mariadb 10.5 machines with new galera 4 and we’re doing the normal way of migration:

How to downgrade MariaDB or MySQL

Taxonomy upgrade extras: 

On this page we have summarised information about downgrading a MariaDB/MySQL database. We do not cover migrating from MySQL to MariaDB or vice versa. For migrations (sidegrade) please look here: MySQL - MariaDB migration and here: Migration between MySQL/Percona Server and MariaDB.

FromDual Ops Center 1.2.2 for MariaDB and MySQL databases has been released

FromDual is pleased to announce the release of the new version 1.2.2 of the popular FromDual Ops Center focmm, a Graphical User Interface (GUI) for MariaDB, MySQL and compatible databases.

Ops Center Release Notes

Taxonomy upgrade extras: 
  • Ops Center 1.2.2 Release Notes, Release Date: 25 April 2024
  • Ops Center 1.2.1 Release Notes, Release Date: 7 Februray 2023
  • Ops Center 1.2.0 Release Notes, Release Date: 17 January 2023
  • Ops Center 1.1.0 Release Notes, Release Date: 7 May 2021
  • Ops Center 1.0.0 Release Notes, Release Date: 7 May 2020
  • Ops Center 0.9.3 Release Notes, Release Date: 18 February 2020
  • Ops Center 0.9.2 Release Notes, Release Date: 13 August 2019
  • Ops Center 0.9.1 Release Notes, Release Date: 7 May 2019
  • Ops Center 0.9.0 Release Notes, Release Date: 16 April 2019
  • Ops Center 0.3.0 Release Notes, Release Date: 13 January 2016
  • Ops Center 0.2.0 Release Notes, Release Date: 29 May 2014
  • Ops Center 0.1.0 Release Notes, Release Date: 02 January 2014
  • Ops Center 0.0.1 Release Notes, Release Date: 01 January 2014

MariaDB's parallel replication to catch up

Due to an application error, our replication stopped for 5 days (over Easter). After the problem was solved, the replication was supposed to catch up, which turned out to be very slow. All the usual tricks (innodb_flush_log_at_trx_commit, sync_binlog, etc.) had already been exhausted. So we tried our hand at parallel replication of the MariaDB server.

Building MariaDB Server from the sources

Taxonomy upgrade extras: 

Recently I had to test a new MariaDB feature that was developed at our request (MDEV-33782). To test this feature I had to build the MariaDB server myself from source, which I have not done for a long time. So a new challenge, especially with CMake

dbstat for MariaDB (and MySQL)

Table of contents

An idea that I have been thinking about for a long time and have now, thanks to a customer, finally tackled is dbstat for MariaDB/MySQL. The idea is based on sar/sysstat by Sebastien Godard:

MariaDB/MySQL Environment MyEnv 2.1.0 has been released

FromDual has the pleasure to announce the release of the new version 2.1.0 of its popular MariaDB, Galera Cluster and MySQL multi-instance environment MyEnv.

MyEnv Release Notes

Taxonomy upgrade extras: 
  • MyEnv 3.0.0 Release Notes, Release Date: 23 March 2026
  • MyEnv 2.1.1 Release Notes, Release Date: 12 December 2025
  • MyEnv 2.1.0 Release Notes, Release Date: 28 February 2024
  • MyEnv 2.0.3 Release Notes, Release Date: 2 July 2021
  • MyEnv 2.0.2 Release Notes, Release Date: 17 January 2019
  • MyEnv 2.0.1 Release Notes, Release Date: 3 October 2018
  • MyEnv 2.0.0 Release Notes, Release Date: 15 March 2018
  • MyEnv 1.3.1 Release Notes, Release Date: 3 August 2016
  • MyEnv 1.3.0 Release Notes, Release Date: 31 January 2016
  • MyEnv 1.2.2 Release Notes, Release Date: 12 October 2015
  • MyEnv 1.2.1 Release Notes, Release Date: 27 July 2015
  • MyEnv 1.2.0 Release Notes, Release Date: 18 April 2015
  • MyEnv 1.1.4 Release Notes, Release Date: 11 February 2015
  • MyEnv 1.1.3 Release Notes: Skipped, see v1.1.4, Release Date: 30 January 2015
  • MyEnv 1.1.2 Release Notes, Release Date: 23 October 2014
  • MyEnv 1.1.1 Release Notes, Release Date: 8 September 2014
  • MyEnv 1.1.0 Release Notes, Release Date: 23 August 2014
  • MyEnv 1.0.5 Release Notes, Release Date: 13 June 2014
  • MyEnv 1.0.4 Release Notes, Release Date: 29 April 2014
  • MyEnv 1.0.3 Release Notes, Release Date: 25 April 2014
  • MyEnv 1.0.2 Release Notes, Release Date: 11 December 2013
  • MyEnv 1.0.1 Release Notes, Release Date: 5 November 2013
  • MyEnv 1.0 Release Notes, Release Date: 4 October 2013
  • MyEnv 0.4 Release notes: none, Release Date: 30 March 2011
  • MyEnv 0.3.6 Release notes: none, Release Date: 23 January 2011
  • MyEnv 0.3.5 Release notes: none, Release Date: 22 January 2011
  • MyEnv 0.3.4 Release notes: none, Release Date: 21 November 2010
  • MyEnv 0.3.3 Release notes: none, Release Date: 21 November 2010
  • MyEnv 0.3.2 Release notes: none, Release Date: 14 November 2010
  • MyEnv 0.3.1 Release notes: none, Release Date: 14 November 2010
  • MyEnv 0.3 Release notes: none, Release Date: 13 November 2010
  • MyEnv 0.2.7 Release notes: none, Release Date: 12 August 2010
  • MyEnv 0.2.6 Release notes: none, Release Date: 12 August 2010
  • MyEnv 0.2.5 Release notes: none, Release Date: 12 August 2010
  • MyEnv 0.2.4 Release notes: none, Release Date: 12 August 2010
  • MyEnv 0.2.3 Release notes: none, Release Date: 19 January 2010
  • MyEnv 0.2.2 Release notes: none, Release Date: 7 January 2010
  • MyEnv 0.2.1 Release notes: none, Release Date: 31 December 2009
  • MyEnv 0.2 Release notes: none, Release Date: 24 December 2009
  • MyEnv 0.1.1 Release notes: none, Release Date: 18 July 2008
  • MyEnv 0.1 Release notes: none, Release Date: 18 July 2008

We build a data warehouse from the General Query Log

Taxonomy upgrade extras: 

The design of a data warehouse differs from relational design. Data warehouses are often designed according to the concept of the star schema.

FromDual Performance Monitor for MariaDB 2.1.0 has been released

FromDual has the pleasure to announce the release of the new version 2.1.0 of its popular Database Performance Monitor for MariaDB and Galera Cluster fpmmm.

InnoDB Deadlock on SELECT? Not possible! Or Is It?

Taxonomy upgrade extras: 

Translated by deepl.com

Introduction

Two points in advance:

  1. A deadlock is a state in which two different transactions are no longer able to continue working because each transaction holds a lock that the other transaction would need. Because both transactions are now waiting for the other transaction to release their locks, neither transaction will release their respective locks. And that would last forever. To avoid this, the MariaDB instance intervenes and kills the transaction that has done less work. The application then receives a deadlock error message of this type:

Upgrading MariaDB to the pre-latest minor release

Taxonomy upgrade extras: 

Scenario: MariaDB Community Server is release every 3 months. The exact date is not known but it is typically about 2 to 3 weeks after the MySQL/Oracle CPU.

FromDual Ops Center 1.2.1 for MariaDB, MySQL and compatible databases has been released

FromDual has the pleasure to announce the release of the new version 1.2.1 of its popular FromDual Ops Center focmm, a Graphical User Interface (GUI) for MariaDB, MySQL and compatible databases.

FromDual Ops Center 1.2.0 for MariaDB, MySQL and compatible databases has been released

FromDual has the pleasure to announce the release of the new version 1.2.0 of its popular FromDual Ops Center focmm, a Graphical User Interface (GUI) for MariaDB, MySQL and compatible databases.

Comparing Optimizer Results

A while ago I read a paper about Optimizer Benchmarks: How Good Are Query Optimizers, Really? by Viktor Leis from Fakultät für Informatik of the Technische Universität München.

Migration of your data from one database to another

Taxonomy upgrade extras: 

Before you consider migrating your data from MySQL to another database you have to know which objects have to be migrated.

Graphical User Interfaces (GUI) for MariaDB and MySQL

Taxonomy upgrade extras: 

If you do not feel at home on the command line, you may prefer to use a graphical user interface (GUI). These also have advantages, for example when displaying data or structures, or they can simplify and therefore speed up work processes.

Filter in WHERE Clause versus Filter in ON clause

Sometimes SQL developers ask me if there is a difference between putting the Filter in the WHERE Clause and putting the Filter in the ON Clause and if yes, what the difference is. To explain it the best I have stolen a little example (Source at the end):

Linux Container with Incus for focmm unit testing

Currently we are in the testing phase of the next release of our Ops Center (focmm). This testing is quite complex because it includes testing the interaction of various different components like a MariaDB Galera Cluster, a Galera Load Balancer, a virtual IP, etc.

For real MySQL materialized views, try LeapDB

Taxonomy upgrade extras: 

I used to maintain Flexviews, but I ported it to use a native MySQL syntax. Now CREATE INCREMENTAL MATERIALIZED VIEW … is a reality. Inner join and all aggregation functions are supported. Check out http://www.leapdb.com

FromDual Performance Monitor for MariaDB 2.0.0 has been released

FromDual has the pleasure to announce the release of the new version 2.0.0 of its popular Database Performance Monitor for MariaDB and Galera Cluster fpmmm.

MariaDB MaxScale Load Balancer with Master/Master Replication

For this how-to we were working with a MariaDB 10.6.5 database server and the newest MariaDB MaxScale 6.3.0 (aka 2.6) load balancer/proxy.

Streaming backup with MariaDB Backup

Taxonomy upgrade extras: 

Because the original MariaDB documentation is a little bit sparse about this topic here are some notes about how to do a streaming MariaDB backup:

One thought about scaling applications

Taxonomy upgrade extras: 

Are containers so popular because application developers do not know how to write multi-threaded applications well? With containers you can circumvent this problem a bit. You ramp up man single threaded applications in containers and thus get a multi-threaded behaviour.
Databases ARE already multi-threaded. So no need to containerize them.

Sharding do-it-yourself

Taxonomy upgrade extras: 

As already mentioned earlier, we roughly have a hand full of customers which are playing with the though of sharding solutions. They typically have many different customers (clients, tenants) and the number of customers becomes so huge (thousands to millions) that one machine cannot cope with the load any more.

Containers and databases

Taxonomy upgrade extras: 

In the last months we got more and more requests for supporting MariaDB/MySQL/Galera Cluster in (mostly Docker) containers.

Sharding solutions

Taxonomy upgrade extras: 

Once in a year or so we get a request of a customer about MariaDB/MySQL sharding solutions. So here we have a list of sharding solutions we are currently aware of:

Learning from the Bugs Database

This week I came across an old known issue reported in May 2010: Master/Slave Replication with binlog_format = ROW and tables without a Primary Key is a bad idea! Especially if these tables are huge.

MariaDB Deadlocks

Taxonomy upgrade extras: 

We get ever and ever again customer requests concerning Deadlocks. First of all, Deadlocks are usually an application problem, not a database problem! The database itself manifests the application problem with the following message which is sent to the application as an error:

Anonymous PL/SQL block

Taxonomy upgrade extras: 

Is this not just a simple an Anonymous PL/SQL Block?

BEGIN NOT ATOMIC

Taxonomy upgrade extras: 

I believe that the infinite loop example is just standard SQL. The only problem is that, in this context, BEGIN means START TRANSACTION. But you can use BEGIN NOT ATOMIC instead. A nice feature contributed by Antony Curtis.

MariaDB Devroom at FOSDEM 2022 CfP is now open

Taxonomy upgrade extras: 

Also in 2022 there will be a FOSDEM (Free and Open source Software Developers’ European Meeting) on 5 and 6 February 2022. This time again online from Brussels (Belgium).

MariaDB Connection ID

The MariaDB Connection ID exists since long ago. So why bother about the Connection ID? Because it is interesting and you can do some interesting things with the Connection ID like tracking statements in your connections and find where they come from your application code.

GRA_XXX_YYY.log

Taxonomy upgrade extras: 

XXX means Thread ID (= Connection ID) and YYY wsrep transaction sequence number (wsrep_last_committed?):

MariaDB / MySQL Advanced training end of October 2021

Taxonomy upgrade extras: 

From 25 to 29 October 2021 (calendar week 43) we will have another MariaDB / MySQL advanced training in the Linuxhotel in Essen (Germany). The training is in German and will take place on-site (3G!). There are still some places free!

Upgrade of Galera Cluster takes more than 1 year

Taxonomy upgrade extras: 

We currently have the situation that a customer cannot upgrade its hyper-consolidated Galera Cluster for more than a year because various different applications cannot, are not willing to or do not have the time to test against the newer version.

Automated MariaDB restore tests

Taxonomy upgrade extras: 

Nearly everybody does backups. But nobody needs backups! What everybody wants and needs is a working restore not a working backup…

MariaDB Foreign Key Constraint example

Taxonomy upgrade extras: 

Foreign Key Constraints are used to model a parent/child relation in an entity relationship (ER) model:

Monitoring your MariaDB database with SNMP

Taxonomy upgrade extras: 

Table of Contents

What is SNMP?

A customer recently had the question if an how his MariaDB database can be easily monitored with SNMP?

MariaDB/MySQL Environment MyEnv 2.0.3 has been released

FromDual has the pleasure to announce the release of the new version 2.0.3 of its popular MariaDB, Galera Cluster and MySQL multi-instance environment MyEnv.

Query on target list

Taxonomy upgrade extras: 

Hello Leo

Thank you for your question. What did you try so far? Or where did you stuck? Can you show us the query you have created so far?

Help with Query

Taxonomy upgrade extras: 

Hello,

Thank you for this great blog post.We use suitecrm and we are having issues creating a query.

Data Warehouse Design

Taxonomy upgrade extras: 

This is my cheat sheet for dimensional modelling design techniques of a data warehouse (DWH) according to Kimball/Ross.

Query performance comparison between MariaDB ColumnStore and other Storage Engines

Storage Engines like InnoDB, Aria and MyISAM are Row Stores. They store rows one after the other in blocks or even directly in a single file (MyISAM). On the other hand a Column Store like MariaDB ColumnStore stores all the same attributes (columns) of the rows together in chunks.

Galera Load Balancer SystemD Unit file

Taxonomy upgrade extras: 
#
# /etc/systemd/system/glbd.service
#

[Unit]
Description=Galera Load Balancer Service
After=network.target

[Service]
#
# adjust the EnvironmentFile variable for your distribution
#
# On Redhat and derivatives it should be /etc/sysconfig/glbd.conf
#
# On Debian  and derivatives it should be /etc/default/glbd.conf
#
EnvironmentFile=/etc/sysconfig/glbd.conf
Type=simple
ExecStart=/usr/sbin/glbd --daemon --threads $THREADS --max_conn $MAX_CONN $OTHER_OPTIONS --control $CONTROL_ADDR $LISTEN_ADDR $DEFAULT_TARGETS

[Install]
WantedBy=multi-user.target

The Galera Load Balancer Configuration file

Taxonomy upgrade extras: 
#
# This is a configuration file for glbd service script
#
# On Red Hat and derivatives it should be placed in /etc/sysconfig/glbd.conf
#
# On Debian  and derivatives it should be placed in /etc/default/glbd.conf
#
# All settings besides LISTEN_ADDR are optional.
#

# Address to listen for client connections at. Mandatory parameter.
# To bind to all interfaces only port should be specified.
#LISTEN_ADDR="0.0.0.0:3306"

# Address for controlling connection. Mandatory part is port.
# If not specified control socket will not be opened
#CONTROL_ADDR="127.0.0.1 8081"

# Control FIFO name. It is opened always. glbd will refuse to start if
# this file already exists.
#CONTROL_FIFO="/var/run/glbd.fifo"

# Number of threads (connection pools) to use. It is always a good idea
# to have a few per CPU core.
#THREADS="4"

# Maximum connections. System open files limit will be modified to accommodate
# at least that many client connections provided sufficient privileges.
# Normally you should set it if you plan to go above 500.
# 3 x max_connections = 3 * 151 = 453
#MAX_CONN="450"

# Target servers for client connections, space separated.
# Target specification: IP[:PORT[:WEIGHT]] (WEIGHT and PORT optional)
# WEIGHT defaults to 1, PORT defaults to LISTEN_ADDR port.
#DEFAULT_TARGETS="192.168.0.1:3306:1 192.168.0.2:3306:1 192.168.0.3:3306:1"

# Other glbd options if any as they would appear on the command line.
# --least --round --single --random --source
#OTHER_OPTIONS="--round"

FromDual Ops Center for MariaDB, MySQL and compatible databases 1.1.0 has been released

FromDual has the pleasure to announce the release of the new version 1.1.0 of its popular FromDual Ops Center focmm, a Graphical User Interface (GUI) for MariaDB, MySQL and compatible databases.

InnoDB NUMA interleave with MariaDB

Taxonomy upgrade extras: 

InnoDB NUMA interleave with MariaDB also read here.

Limiting MySQL tmpdir size

Taxonomy upgrade extras: 

Today a customer gave me the idea of using a separate file as a volume for limiting the MySQL tmpdir size. On some not so well set-up Linux systems the MySQL tmpdir is located under /tmp which is the same mount point as / (root). This can lead to troubles in case the tmpdir is filled up with implicit temporary MyISAM tables which fills up the / (root) directory of the O/S as well.

MariaDB Enterprise Server vs. MariaDB Community Server

MariaDB Enterprise Platform

The MariaDB Enterprise Platform is available on-premises and on the MariaDB SkySQL DBaaS (Cloud database platform). MariaDB Enterprise Platform consists of:

Do not trust other peoples benchmarks!

Because they do NOT reflect your problems.

One of our customers upgraded last month from MariaDB 10.2 to MariaDB 10.5. In the same change he also converted all his data warehouse (DWH)/BI tables from MyISAM to Aria. An all this, naturally, without testing. And it miserably failed! And then we were under heavy time pressure to make things working again…

MariaDB configuration analysis

Taxonomy upgrade extras: 

If we do customers database configuration analysis we check on one side if the most important MariaDB server system variables (innodb_buffer_pool_size, …) are set appropriately but also if some MariaDB server system variables are configured completely wrong.

MariaDB or MySQL, that is the question

Taxonomy upgrade extras: 

Many customers come to us and ask us whether to use MariaDB or MySQL. The answer is not so simple. FromDual is a neutral and vendor independent MariaDB/MySQL consulting company. So we should not have (in the meaning of neutral) a clear preference. For us internally we have chosen our strategy according to some clearly defined criteria. But what we have chosen for us is not necessarily the right choice for you.

Recover DDL from .frm file out of MariaDB full backup

Taxonomy upgrade extras: 

We just came today across the mysqlfrm utility which helps to extract the DDL statement from the .frm file. This is exactly what is needed to automatize and thus simplify the partial restore from MariaDB full backup.

MariaDB sql_mode = 'oracle'

Taxonomy upgrade extras: 

MariaDB has some time ago introduced or reused the sql_mode = 'oracle'. What they basically try to do is to implement a subset of the Oracle PL/SQL language. Because we receive more and more request from customers about MariaDB’s Oracle PL/SQL it is worth investigating a bit more in this feature and summarize the state of the art of this topic in this article.

MySQL 8.0 vs. MariaDB

Taxonomy upgrade extras: 

In MySQL 8 the MySQL Data Dictionary was placed inside the InnoDB Storage Engine. This has some impact on multi-tenant applications:

MariaDB Galera Cluster with Corosync/Pacemaker VIP

Sometimes customers want to have a very simple Galera Cluster set-up. They do not want to invest into machines and build up the know-how for load balancers in front of the Galera Cluster.

Effect of conversion

Taxonomy upgrade extras: 

Thank you very much for your reply. I have not found an error in my conversion process. My DB is in latin1 and I am going to convert to utf8 or utf8mb4. I was unsure if the conversion would in its self cause errors in the text and binary data already present in the DB. You have, I believed, answered that. It should not. Your examples are interesting. I will need to study them to understand them better.

Effect of conversion

Taxonomy upgrade extras: 

Hello Hal

I do not really get your question. Do you have a good and reproducible example for your question?

question on effect of conversion

Taxonomy upgrade extras: 

Can altering the table character set to utf8mb4 cause error or special characters to appear in existing text or binary (blob) data. That is when ALTER TABLE test CONVERT TO CHARACTER SET utf8mb4 is executed will existing latin1 text be converted properly. Perhaps this is a mute point as I believe latin1 is part of UTF8MB4, but I am not sure.

Keep your Galera Cluster up and running by all means

Taxonomy upgrade extras: 

We see quite often customers complaining that their Galera Cluster is not stable and “crashes” from time to time. As always one has to investigate before rating.

Partial restore on MySQL or PXC

Taxonomy upgrade extras: 

The receipt above seems also to work with Percona Xtrabackup:

Galera Cluster Release Notes

Taxonomy upgrade extras: 

Source: Github: codership / documentation

Codership Blog for Galera Cluster with release announcements.

Window functions

Taxonomy upgrade extras: 

Some of my colleagues mentioned Window Functions. Maybe it works. But I fear that window functions are not fast because they do some materialization in between? I have to test...

Databases are standardized but in detail they behave different

Taxonomy upgrade extras: 

For a fancy application we want to query a chunk of rows from a table and therefore we need the minimum and the maximum of the Primary Key of these rows.
Because InnoDB is an Index Organized Table or Index Clustered Table we know that this access will use the Primary Key. But to be sure and to be compliant with the standard (and compatible) we use and ORDER BY on the Primary Key.

Handler_read_first

Taxonomy upgrade extras: 

We got some feedback from Paul Campbell about Handler_read_first:

Thought you might like to know that you can get do this without a full index scan (in 5.7 at least) with a query for SELECT MIN(pkey), only the first key is read in this instance. SELECT MAX(pkey) will do the same for Handler_read_last.

MariaDB Push Replication

Taxonomy upgrade extras: 

Table of Contents

How to make MariaDB Pull Replication as secure as possible

A normal MariaDB Replication is a Pull Replication. This means that a Slave connects to its Master and gathers or better requests Binary Log information from the Master and applies them in a streaming way.

VSZ behaviour with MariaDB MEMORY tables

Taxonomy upgrade extras: 

We recently had the situation that a customer complained about the Oom killer terminating the MariaDB database instance from time to time. The MariaDB database configuration was sized quit OK (about 50% of RAM was used for the database) but they did not have swap configured.

MariaDB memory_used

Taxonomy upgrade extras: 

An inside view from the MariaDB database instance can be received with:

Use Mirror Router instead

Taxonomy upgrade extras: 

I just got a note from Markus Makela with the following suggestion:

Traffic mirroring with MariaDB MaxScale

Taxonomy upgrade extras: 

Recently we had the case that a customer claimed that MariaDB 10.3 Binary Log is using 150% more space on disk than MySQL 5.7 Binary Log. Because I never observed something similar, but to be honest, I did not look to intensively for this situation, we had to do some clarifications.

MariaDB Galera Cluster Upgrade Path

Taxonomy upgrade extras: 

Because we conduct many customers in MariaDB Galera Cluster upgrades and because these customers sometimes have pretty old MariaDB Galera Cluster set-ups I think it is good to have a rough MariaDB Galera Cluster Upgrade Path.

A note about the described problem

Taxonomy upgrade extras: 

Hi Oli,

I think that it could be worth mentioning that in MariaDB 10.5, the described problem should no longer exist, thanks to https://jira.mariadb.org/browse/MDEV-19747 removing the code. Also, in older MariaDB versions, https://jira.mariadb.org/browse/MDEV-23720 disables the feature by default.

How to force InnoDB Buffer Pool flushing

InnoDB tries to keep pages in Buffer Pool to be fast. If a page is changed by a DML statement (INSERT, UPDATE, DELETE) this change will be done in InnoDB Buffer Pool and not directly on disk. But those changed InnoDB pages residing in InnoDB Buffer Pool must be flushed sooner or later to disk to become persistent. This is done by the InnoDB background writer thread(s) (default 4).

Upgrading from MariaDB 10.4 to MariaDB 10.5 Galera Cluster

Because upgrading from MariaDB 10.4 to MariaDB 10.5 (non-clustered) seems not to be a problem
[ 1
] we take the challenge and try to create a receipt based on the MariaDB 10.3 to MariaDB 10.4 Galera Cluster upgrade documentation
[ 3
]:

Partial Table or Schema restore from mariabackup full backup

For me it was for a long time not clear if a mariadb-backup full backup can be used to do partial table or schema restores. Now we faced this challenge with a customer. So time to try it out…

MariaDB MaxScale Configuration Variables

Table of Contents

Global Options

VariableVersionsValuesDefaultUnitComment
threads1.4 2.32.42.5{ <n> | auto }1thread 
thread_stack_size 2.2   <n>  Ignored and deprecated in 2.3
rebalance_period    2.5<n>0second 
rebalance_threshold    2.5<n>20delta load 
rebalance_window    2.5<n>10second 
auth_connect_timeout1.42.22.32.4 <n>3second 
auth_read_timeout1.42.22.32.4 <n>1secondDeprecated in 2.5
auth_write_timeout1.42.22.32.4 <n>2secondDeprecated in 2.5
query_retries  2.32.42.5<n>1timeAdded in 2.1.10, disabled by default until 2.3.0
query_retry_timeout  2.32.42.5 5  
passive  2.32.42.5 false  
ms_timestamp1.4 2.32.42.5{ 0 | 1 }0- 
skip_permission_checks  2.32.42.5{ 0 | 1 }0  
syslog1.4 2.32.42.5{ 0 | 1 }1- 
maxlog1.4 2.32.42.5{ 0 | 1 }1- 
log_to_shm1.4    { 0 | 1 }0-Deprecated and ignored in 2.3.0 and newer
log_warning1.4 2.32.42.5{ 0 | 1 }1- 
log_notice1.4 2.32.42.5{ 0 | 1 }1- 
log_info1.4 2.32.42.5{ 0 | 1 }0- 
log_debug1.4 2.32.42.5{ 0 | 1 }0- 
log_warn_super_user    2.5 false  
log_messages        Deprecated, use log_notice instead
log_trace        Deprecated, use log_info instead
log_augmentation1.4 2.32.42.5{ 0 | 1 }0- 
log_throttling  2.32.42.5{ <n>, <n>, <n> }10, 1000, 10000time, millisecond, millisecond 
logdir1.4 2.32.42.5<dirpath>/tmp/- 
datadir1.4 2.32.42.5<dirpath>/home/user/maxscale_data/- 
libdir1.4 2.32.42.5<dirpath>/home/user/lib64/- 
cachedir1.4 2.32.42.5<dirpath>/tmp/maxscale_cache/- 
piddir1.4 2.32.42.5<dirpath>/tmp/maxscale_cache/- 
execdir1.4 2.32.42.5<dirpath>/usr/local/bin/- 
connector_plugindir  2.32.42.5<dirpath>/usr/lib/plugin/  
persistdir  2.32.42.5<dirpath>/var/lib/maxscale/maxscale.cnf.d/  
module_configdir  2.32.42.5<dirpath>/var/lib/maxscale/  
language1.4 2.32.42.5<dirpath>/home/user/lang/- 
query_classifier  2.32.42.5<classifier>qc_sqlite  
query_classifier_cache_size  2.32.42.5<n>15% of system Memorybyte 
query_classifier_args  2.32.42.5    
substitute_variables  2.32.42.5{ true | false }false  
sql_mode  2.32.42.5{ default | oracle }default  
local_address  2.32.42.5<IP address>*  
users_refresh_time  2.32.42.5<n>30second 
user_refresh_interval   2.42.5<n>0second 
retain_last_statements  2.32.42.5<n>0statement 
dump_last_statements  2.32.42.5{ on_error | on_close | never }never- 
session_trace  2.32.42.5<n>0statement 
writeq_high_water  2.32.42.5    
writeq_low_water  2.32.42.5    
load_persisted_configs  2.32.42.5{ 0 | 1 }1  
max_auth_errors_until_block   2.42.5<n>10  
debug    2.5    
admin_host  2.32.42.5<IP address>127.0.0.1  
admin_port  2.32.42.5<n>8989  
admin_auth  2.32.42.5 1  
admin_ssl_key  2.32.42.5    
admin_ssl_cert  2.32.42.5    
admin_ssl_ca_cert  2.32.42.5    
admin_enabled  2.32.42.5{ 0 | 1 }   
admin_gui    2.5 1  
admin_secure_gui    2.5    
admin_log_auth_failures   2.42.5{ 0 | 1 }1  
admin_pam_readwrite_service   2.42.5    
admin_pam_readonly_service   2.42.5    

Service Options

VariableVersionsValuesDefaultUnitComment
type1.4 2.32.42.5service - 
router1.4 2.32.42.5{ readconnroute | readwritesplit | schemarouter | binlogrouter } - 
router_option1.4 2.32.42.5{ slave | master,slave } - 
filters1.4 2.32.42.5{ counter | QLA } - 
targets    2.5{ server | service, ... }   
servers1.4 2.32.42.5{ <server1>, <server2>, ... } - 
cluster   2.42.5<name>   
user1.4 2.32.42.5{ <username> } - 
passwd1.4 2.32.42.5{ <password> } - 
enable_root_user1.4 2.32.42.5{ 0 | 1 }0- 
localhost_match_wildcard_host1.4 2.32.4 { 0 | 1 }0 Deprecated and ignored.
version_string1.4 2.32.42.5<string>5.5.5-10.0.0 MaxScale <MaxScale version>  
weightby1.4 2.32.4 <server_weight>  Deprecated in 2.3 and removed in 2.5, use rank instead
auth_all_servers1.4 2.32.42.5{ 0 | 1 }0  
strip_db_esc1.4 2.32.42.5{ 0 | 1 }0  
optimize_wildcard1.4  2.4 { 0 | 1 }0  
retry_on_failure1.4 2.3  { 0 | 1 }1 Ignored by 2.4 and removed in the future.
log_auth_warnings1.4 2.32.42.5{ 0 | 1 }0  
connection_timeout1.4 2.32.42.5<n> second 
max_connections  2.32.42.5<n> connection 
max_retry_interval 2.22.32.4 <n>3600second 
session_track_trx_state  2.32.42.5 false Only supported by MariaDB 10.3 and newer
retain_last_statements  2.32.42.5    
connection_keepalive    2.5<n>300  
net_write_timeout   2.42.5 0second 

Routing Modules

ReadConnRoute

For (weighted) load balancing.

SQL Query Tuning - Performance

Taxonomy upgrade extras: 

How could the following SQL queries be improved performance wise and otherwise and can you also explain why your change is more optimal?

Creating synthetic data sets for tuning SQL queries

When it comes to SQL Query tuning with customers we often get the slow running SQL query and possibly, in good cases, also the table structure. But very often, for various reasons, we do not get the data.

Kernel Documentation

Taxonomy upgrade extras: 

And this is what the Linux kernel documentation says about it: https://www.kernel.org/doc/Documentation/networking/bonding.txt

MyISAM locking and who is the evil?

Taxonomy upgrade extras: 

Yes, I know, MyISAM is deprecated and unofficially discontinued by the vendors. But we still have from time to time customers using MyISAM and even evangelize for MyISAM…

Good explanation for bond interfaces

Taxonomy upgrade extras: 

802.3ad bond interface have show high RX dropped packets

I found a god explanation for dropped packages on bonded interfaces: [ 1 ]

Solutions

Taxonomy upgrade extras: 

I have described 3 different ways to "solve" the problem above:

PageCleaners issue

Taxonomy upgrade extras: 

only Problem statement, where is the solution to this issue of Page Cleaners?

MariaDB and MySQL package holding or locking

Repositories from your favourite Linux distribution and from your favourite database software vendor get regular package updates. If you do periodic system upgrades (for example every 2 weeks as we do) you get the newest packages of a release series.
Unfortunately recently the software vendors started not only to fix bugs in new releases but also to introduce new features. And when you fix bugs or introduce new stuff new bugs might appear.
To avoid being hit unexpectedly by new bugs you do not want to upgrade untested software. To achieve this you want to keep/not upgrade some important packages. For example the MariaDB or MySQL server package.
This package pinning is called package version lock on CentOS and Redhat and package holding on Debian and Ubuntu.

MariaDB SQL Error Log Plugin

Taxonomy upgrade extras: 

When you are for too long in business you think you know already everything and you are getting lazy. This happened to me again a few weeks ago. A customer asked me about the SQL Error Log Plugin. First I though he was talking about the MariaDB Error Log or the General Query Log. But then I have learned that there is something “new” I did not know yet…

FromDual Ops Center File Transfer

With the FromDual Ops Center file transfer tool you can easily upload files from your personal computer to the focmm machine, download files from the focmm machine to your personal computer or transfer files from the focmm machine to any of your database machines or between them. This feature is made for importing, exporting or transferring data from, to or between your different database instances. For example to copy a production schema to a testing database instance.

Centralized Crontab with FromDual Ops Center

One of the tools of FromDual Ops Center for MariaDB and MySQL is the centralized crontab for all of your database machines. Instead of maintaining various different crontabs on different machines you can manage them now in one place within the Ops Center.

WMware snapshots or Veeam backups

Taxonomy upgrade extras: 

We have found a strong correlation between VMware snapshots and Veeam backups and those dropped packets.

InnoDB full-text index corruption

In a recent customer engagement we experienced a lot of corrupted (normal) indexes and also corrupted full-text indexes on InnoDB tables in a Galera Cluster (v10.4.13).

Increase file limit of a running process

Taxonomy upgrade extras: 

Asking stupid questions and googling for them is fun some times…

New Warning: P_S Metadata Lock instrumentation is disabled

Taxonomy upgrade extras: 

With this new version of fpmmm you probably get a new warning in your fpmmm error log:

FromDual Performance Monitor for MariaDB 1.2.0 has been released

FromDual has the pleasure to announce the release of the new version 1.2.0 of its popular Database Performance Monitor for MariaDB and Galera Cluster fpmmm.

Other example

Taxonomy upgrade extras: 

Trx # 86153878218 exists in both Galera Cluster conflics which are 46 seconds apart (= long running transaction?). Table `rt3`.`Tickets` seems to be involved in both cases. One should investigate also in this query or transaction we cannot see here...

Stupid Error Messages

Taxonomy upgrade extras: 

Very often I see some stupid error messages as a (power-)user. I do not know if this is because of lazy developers or managers not having enough focus on more useful error messages.

FromDual Ops Center for MySQL and compatible databases 1.0.0 has been released

FromDual has the pleasure to announce the release of the new version 1.0.0 of its popular FromDual Ops Center focmm, a Graphical User Interface (GUI) for MySQL and compatible databases.

See also SElinux

Taxonomy upgrade extras: 
cd /var/log
ll -d -Z mysql* mysql/*
mkdir mysql
chown mysql: mysql
semanage fcontext -a -t mysqld_db_t "/var/log/mysql/(/.*)?"
restorecon -Rv /var/log/mysql
ll -d -Z mysql* mysql/*

And Non-standard database set up with SELinux

Testing Logrotate

Taxonomy upgrade extras: 
/usr/sbin/logrotate /etc/logrotate.conf

Shutdown with MySQL 8

Taxonomy upgrade extras: 

On StackExchange for Database Administrators I recently have seen a question which attracted my interest.

InnoDB Deadlock Detector

Taxonomy upgrade extras: 

The InnoDB deadlock detector was rewritten in MySQL 5.7.1, in a merge commit that does not mention any WL or bug number, nor any reviewer. I did not review those changes, and I cannot say whether the algorithmic complexity of the deadlock checker was reduced. Possibly the rewrite replaced procedural recursion with iteration over a data structure that explicitly represents a stack.

FromDual Performance Monitor Release Notes

Taxonomy upgrade extras: 
  • fpmmm 2.2.1 Release Notes, Release Date: 13 February 2026
  • fpmmm 2.2.0 Release Notes, Release Date: 4 September 2025 → see v2.2.1
  • fpmmm 2.1.0 Release Notes, Release Date: 5 December 2023
  • fpmmm 2.0.0 Release Notes, Release Date: 18 May 2022
  • fpmmm 1.2.0 Release Notes, Release Date: 11 June 2020
  • fpmmm 1.1.0 Release Notes, Release Date: 17 December 2019
  • fpmmm 1.0.2 Release Notes, Release Date: 7 March 2019
  • fpmmm 1.0.1 Release Notes, Release Date: 9 February 2017
  • fpmmm 1.0.0 Release Notes, Release Date: 2 October 2016
  • fpmmm 0.10.9 Release Notes, Release Date: 17 August 2016
  • fpmmm 0.10.6 Release Notes, Release Date: 2 August 2016
  • fpmmm 0.10.5 Release Notes, Release Date: 31 July 2015
  • fpmmm 0.10.4 Release Notes, Release Date: 16 May 2015
  • fpmmm 0.10.3 Release Notes, Release Date: 1 May 2015
  • fpmmm 0.10.2 Release Notes, Release Date: 30 April 2015
  • fpmmm 0.10.1 Release Notes, Release Date: 19 April 2015
  • fpmmm 0.10.0 Release Notes, Release Date: 16 April 2015
  • fpmmm 0.9.3 Release Notes, Release Date: 24 May 2014
  • fpmmm 0.9.2 Release Notes, Release Date: 18 April 2014
  • fpmmm 0.9.1 Release Notes, Release Date: 9 April 2013
  • fpmmm 0.9 Release Notes, Release Date: 2 April 2012
  • fpmmm 0.8.1 Release Notes, Release Date: 24 January 2012
  • fpmmm 0.8 Release Notes, Release Date: 22 December 2011
  • fpmmm 0.7.2 Release Notes, Release Date: 2 December 2011
  • fpmmm 0.7.1 Release Notes, Release Date: 13 June 2011
  • fpmmm 0.7 Release Notes, Release Date: 10 June 2011
  • fpmmm 0.6 Release Notes, Release Date: 1 April 2011
  • fpmmm 0.5 Release Notes, Release Date: 20 February 2011
  • fpmmm 0.4 Release Notes, Release Date: 16 August 2010
  • fpmmm 0.3.3 Release Notes, Release Date: 13 August 2010
  • fpmmm 0.3.2 Release Notes, Release Date: 12 August 2010
  • fpmmm 0.3.1 Release Notes, Release Date: 12 August 2010
  • fpmmm 0.3 Release Notes, Release Date: 7 May 2010
  • fpmmm 0.2.1 Release Notes, Release Date: 6 May 2010
  • fpmmm 0.2 Release Notes, Release Date: 6 May 2010
  • fpmmm 0.1 Release Notes, Release Date: 6 May 2010

innodb_deadlock_detect - Rather Hands off!

Recently we had a new customer who has had from time to time massive database problems which he did not understand. When we reviewed the MySQL configuration file (my.cnf) we found, that this customer had disabled the InnoDB Deadlock detection (innodb_deadlock_detect).

MariaDB/MySQL Stored Language Examples

MariaDB/MySQL Stored Language is called SQL/PSM.
There are 4 different types of Stored Language: Stored Procedures, Stored Functions, Triggers and Events.

FromDual is 10 years old

Taxonomy upgrade extras: 

On 1 March 2020 FromDual became 10 years old! Sincere thanks are given to all our customers, partners and interested person for their support and good cooperation in the last 10 years. And we would be pleased to advise and support you again competently in the coming 10 years.

InnoDB Page Cleaner intended loop takes too long

Recently we migrated a database system from MySQL 5.7 to MariaDB 10.3. Everything went fine so far just the following message started to pop-up in the MariaDB Error Log File with the severity Note:

FromDual Ops Center for MariaDB and MySQL 0.9.3 has been released

FromDual has the pleasure to announce the release of the new version 0.9.3 of its popular FromDual Ops Center focmm, a Graphical User Interface (GUI) for MariaDB and MySQL.

Architecture and Design decisions

Taxonomy upgrade extras: 

When it comes to MariaDB/MySQL Database consulting engagements we often see, that our customers are very confused by many different technologies advertised to them.

FromDual Performance Monitor for MariaDB and MySQL 1.1.0 has been released

FromDual has the pleasure to announce the release of the new version 1.1.0 of its popular Database Performance Monitor for MariaDB, MySQL and Galera Cluster fpmmm.

fpmmm Version is old

Taxonomy upgrade extras: 

You are using an old version of the FromDual Performance Monitor for MariaDB and MySQL (fpmmm). Please consider using a more recent version.

InnoDB Log Buffer is too small for large transactions

Your InnoDB Redo Log Buffer is too small for large transactions. Make the InnoDB Redo Log Buffer (innodb_log_buffer_size) bigger if you have enough RAM available to avoid additional I/O.
1 Mibyte is good for databases with small transactions. 8 Mibyte is good for medium size transactions. 64 MiByte is good for large transactions.

MariaDB PL/SQL Examples

Table of Contents

Before you start

SQL> SET SESSION sql_mode='ORACLE';

Infinite Loop Example

DELIMITER /

BEGIN

LOOP
  SELECT 'Hello world from MariaDB anonymous PL/SQL block!';
END LOOP; 

END;
/

DELIMITER ;

Migration from MySQL 5.7 to MariaDB 10.4

Up to version 5.5 MariaDB and MySQL can be considered as “the same” databases. The official wording at those times was “drop-in-replacement”. But now we are a few years later and times and features changed. Also the official wording has slightly changed to just “compatible”.
FromDual recommends that you consider MariaDB 10.3 and MySQL 8.0 as completely different database products (with some common roots) nowadays. Thus you should work and act accordingly.

MariaDB Log Rotation

Modern Linux Systems have a mechanism called logrotate to rotate different log files.

FromDual Recovery Manager (rman) with progress indicator

Since version 2.1.0 the FromDual Recovery Manager (rman) for MariaDB and MySQL has also a progress indicator for the restore of logical backups made with mysqldump. This feature was implemented because of the numerous requests of FromDual rman users who were not happy with the default mysql behavior.

MariaDB and MySQL Character Set Conversion

Table of Contents

Introduction

Recently we had a consulting engagement where we had to help the customer to migrate from latin1 Character Set to utf8mb4 Character Set. In the same MySQL consulting engagement we considered to upgrade from MySQL 5.6 to MySQL 5.7 as well
[ Lit.
]. We decided to split the change in 2 parts: Upgrading to 5.7 in the first step and converting to uft8mb4 in the second step. There were various reasons for this decision:

FromDual Ops Center for MariaDB and MySQL 0.9.2 has been released

FromDual has the pleasure to announce the release of the new version 0.9.2 of its popular FromDual Ops Center for MariaDB and MySQL focmm.

SuiteCRM / SugarCRM Cheat Sheet

Taxonomy upgrade extras: 

Table of Contents

  1. Find id of record to unlink.
SQL> SET @uid = 'f232e8d0-9b82-20f7-7c35-5c1a5ce94e0a';
  1. Find entry in Target List table:
SQL> SELECT plp.id, plp.related_type, plp.date_modified, plp.deleted
     , pl.name
  FROM prospect_lists_prospects AS plp
  JOIN prospect_lists AS pl ON plp.prospect_list_id = pl.id
 WHERE plp.related_id = @uid
;
  1. Update entry in Target List table:
SQL> START TRANSACTION;
SQL> UPDATE prospect_lists_prospects
   SET deleted = 1
 WHERE related_id = @uid
   AND id = '5b3047b2-3b45-1a6e-e6fb-5d3fe1efa93b'
;
Query OK, 1 row affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0
SQL> COMMIT;

Find Target Lists of Target/Prospect

Result:

Enable General Query Log per Connection in MariaDB

The General Query Log in MariaDB is a Log (file or table) that logs every statement sent from the Application to the MariaDB Database Server from the Connect Command to the Quit Command. A simple example you can find here:

MariaDB sys Schema

Taxonomy upgrade extras: 

The story goes on here.

MariaDB sys Schema

Taxonomy upgrade extras: 

The MySQL sys Schema is a cool thing and was mostly developed by Mark Leith and Jesper Wisborg Krogh from Oracle/MySQL. The sys Schema is based on the somehow cryptic MySQL PERFORMANCE_SCHEMA which was developed by Oracle/MySQL as well.

MariaDB sys Schema

Taxonomy upgrade extras: 

I could not resist! I have forked the MySQL sys Schema on GitHub.

Kernel version 3.5 and newer: disables swappiness

Taxonomy upgrade extras: 
  • swappiness can have a value between 0 and 100.
  • swappiness=0:
    • Kernel version 3.5 and newer: disables swappiness.
    • Kernel version older than 3.5: avoids swapping processes out of physical memory for as long as possible.
  • swappiness=1:
    • Kernel version 3.5 and over: minimum swappiness without disabling it entirely.
  • swappiness=100:
    • Tells the kernel to aggressively swap processes out of physical memory and move them to swap cache.

Source: How do I configure swappiness?

Oops! - That SQL Query was not intended... Flashback

It is Saturday night at 23:19. Time to go to bed after a hard migration day. Just a last clean-up query before finishing: Tap tap tap. Enter! - Oops!

A different opinion

Taxonomy upgrade extras: 

Why does Linux swap out pages when I have many pages cached and vm.swappiness is set to 0? Shouldn’t cached pages get resized and no swapping should occur?

Do not underestimate performance impacts of swapping on NUMA database systems

Taxonomy upgrade extras: 

If your MariaDB or MySQL database system is swapping it can have a significant impact on your database query performance! Further it can also slow down your database shutdown and thus influence the whole reboot of your machine. This is especially painful if you have only short maintenance windows or if you do not want to spend the whole night with operation tasks.

PERFORMANCE_SCHEMA in newer MariaDB releases

Taxonomy upgrade extras: 

PERFORMANCE_SCHEMA is invented/developed by Oracle/MySQL. So for MariaDB it is a foreign component and not supported too well...

Dropped Tables with FromDual Backup Manager

Taxonomy upgrade extras: 

Some applications have the bad behaviour to CREATE or DROP tables while our FromDual Backup Manager (bman) backup is running.

FromDual Ops Center for MariaDB and MySQL 0.9.1 has been released

FromDual has the pleasure to announce the release of the new version 0.9.1 of its popular FromDual Ops Center for MariaDB and MySQL focmm.

FromDual Ops Center for MariaDB and MySQL 0.9 has been released

Caution: We have introduced an evil bug which prohibits installation of focmm. Sorry! Somehow it did pass our QA. To fix this bug update file lib/Upgrade.inc on Line 1965 as follows:

MariaDB Prepared Statements, Transactions and Multi-Row Inserts

Last week at the MariaDB/MySQL Developer Training we had one participant asking some tricky questions I did not know the answer by heart.

Understanding InnoDB - Buffer Pool Flushing

InnoDB Page Cleaner Thread

The InnoDB Page Cleaner Thread is an InnoDB background thread that flushes dirty pages from the InnoDB Buffer Pool to disk. Prior MySQL 5.6 this action was performed by the InnoDB Master Thread.

MySQL - MariaDB migration

Table of Contents

More and more MySQL users want to switch from MySQL/Percona Server to MariaDB over time or, more rarely, the other way around. This is mostly caused by the change of the default in the Linux Distributions (RHEL/CentOS 7, SLES 12, Debian 8) to MariaDB.
Up to MySQL/MariaDB 5.5 everything was quite easy, both Branches claim to be a drop-in replacement of each other. But after the separation into different forks (MariaDB 10.0 ff. vs. MySQL 5.6 ff.) we expect more and more problems migrating from one branch to the other what we call sidegrade.
Percona Server code is genetically closer to MySQL than MariaDB. So we expect to see less problems on this sidegrade.

Uptime of a MariaDB Galera Cluster

Taxonomy upgrade extras: 

A while ago somebody on Google Groups asked for the Uptime of a Galera Cluster. The answer is easy… Wait, no! Not so easy… The uptime of a Galera Node is easy (or not?). But Uptime of the whole Galera Cluster?

Linux system calls of MySQL process

We had the problem today that a MySQL Galera Cluster node with the multi-tenancy pattern caused a lot of system time (sy 75%, load average about 30 (you really must read this article by Brendan Gregg, it is worth it!)) so we wanted to find what system calls are being used to see what could cause this issue (to verify if it is a TOC or a TDC problem:

MariaDB and MySQL Database Consolidation

Taxonomy upgrade extras: 

We see at various customers the request for consolidating their MariaDB and MySQL infrastructure. The advantage of such a measure is clear in the first step: Saving costs! And this request comes typically from managers. But what we unfortunately see rarely is to question this request from the IT engineering perspective. Because it comes, as anything in life, with some “costs”. So, saving costs with consolidation on one side comes with “costs” for operation complexity on the other side.

FromDual Performance Monitor for MariaDB and MySQL 1.0.2 has been released

FromDual has the pleasure to announce the release of the new version 1.0.2 of its popular Database Performance Monitor for MariaDB, MySQL, Galera Cluster and Percona Server fpmmm.

MariaDB and MySQL consulting by plane

Since January 2019 FromDual tries to contribute actively a little bit against global warming too.

MySQL Enterprise Backup Support Matrix

MySQL Enterprise Backup (MEB) is a bit limited related to support of older MySQL versions. So you should consider the following release matrix:

FromDual Enterprise Tools License

The FromDual Enterprise Tools are licensed under a FromDual commercial license. The one exception is MyEnv which is licensed under GPLv2.

Upgrade MySQL 5.7 to MySQL 8.0

Taxonomy upgrade extras: 

Early adopters of our customers are considering to upgrade to MySQL 8.0. To be prepared we have created a check-list:

MariaDB/MySQL Environment MyEnv 2.0.2 has been released

FromDual has the pleasure to announce the release of the new version 2.0.2 of its popular MariaDB, Galera Cluster and MySQL multi-instance environment MyEnv.

To NULL, or not to NULL, that is the question!

As we already stated in earlier articles in this blog
[1 and 2
] it is a good idea to use NULL values properly in MariaDB and MySQL.

Re: MariaDB indexing of NULL values

Taxonomy upgrade extras: 

Yes, I am aware that this is not a NULL issue. I hope my blog did not tell that this is be cause of NULL.

MariaDB indexing of NULL values

Taxonomy upgrade extras: 

Hello,

Just wanted to say that the post misses the point. The problem is not NULL values as such. the problem is:

UNDO logs in InnoDB system tablespace ibdata1

Taxonomy upgrade extras: 

We see sometimes at customers that they have very big InnoDB system tablespace files (ibdata1) although they have set innodb_file_per_table = 1.

MariaDB indexing of NULL values

Taxonomy upgrade extras: 

In the recent MariaDB DBA advanced training class the question came up if MariaDB can make use of an index when searching for NULL values… And to be honest I was not sure any more. So instead of reading boring documentation I did some little tests:

MariaDB/MySQL Environment MyEnv 2.0.1 has been released

FromDual has the pleasure to announce the release of the new version 2.0.1 of its popular MariaDB, Galera Cluster and MySQL multi-instance environment MyEnv.

MariaDB and MySQL swap analysis

Taxonomy upgrade extras: 
# free
              total        used        free      shared  buff/cache   available
Mem:       16106332     3914228      367072      296508    11825032    11441608
Swap:      31250428      182924    31067504

# cat /proc/meminfo | grep ^Swap
SwapCached:        10056 kB
SwapTotal:      31250428 kB
SwapFree:       31067504 kB

# for file in /proc/*/status ; do
  awk '/VmSwap|Name/{
    if ( $2 != "0" )
      printf $2 " " $3
  }END{ print ""}' $file
done | grep kB | sort -k 2 -n -r

mysqld 29988 kB
plasmashell 19096 kB
kwin_x11 13444 kB
Xorg 13328 kB
krunner 11200 kB
knotes 5768 kB
kded5 5016 kB
korgac 4760 kB
kglobalaccel5 3288 kB
kwalletd 3148 kB
kaccess 3148 kB
polkit-kde-auth 2704 kB
xembedsniproxy 2660 kB
akonadi_control 2652 kB
kwalletd5 2616 kB
python 2572 kB
kactivitymanage 2508 kB
klauncher 2352 kB
kdeinit5 2324 kB
ksmserver 2256 kB
python 1480 kB
pulseaudio 1312 kB
sddm-helper 1172 kB
baloo_file 1172 kB
kscreen_backend 1132 kB
mission-control 1104 kB
python 992 kB
TeamDrive.bin 772 kB
sddm 772 kB
akonadiserver 616 kB
systemd 504 kB
at-spi2-registr 488 kB
systemd 472 kB
kwrapper5 468 kB
dbus-launch 400 kB
dbus-launch 396 kB
(sd-pam) 364 kB
dbus-daemon 328 kB
(sd-pam) 300 kB
at-spi-bus-laun 264 kB
obexd 260 kB
ssh-agent 252 kB
dbus-daemon 216 kB
gnome-keyring-d 212 kB
dbus-daemon 200 kB
gpg-agent 104 kB
startkde 100 kB
skypeforlinux 64 kB
start_kdeinit 60 kB
apache2 32 kB
apache2 32 kB
apache2 32 kB
apache2 32 kB
apache2 32 kB
apache2 32 kB

# sudo smem --totals --sort=swap
  PID User     Command                         Swap      USS      PSS      RSS
...
 1500 root     /usr/sbin/apache2 -k start        32     5616     9534    23740 
10469 www-data /usr/sbin/apache2 -k start        32      136     1421     9848 
10470 www-data /usr/sbin/apache2 -k start        32      132     1418     9848 
10471 www-data /usr/sbin/apache2 -k start        32      132     1418     9848 
10472 www-data /usr/sbin/apache2 -k start        32      132     1418     9848 
10473 www-data /usr/sbin/apache2 -k start        32      132     1418     9848 
 2111 oli      /usr/lib/x86_64-linux-gnu/l       60       40       43      548 
 2291 oli      /usr/share/skypeforlinux/sk       60    73920    80765   106312 
 1957 oli      /bin/sh /usr/bin/startkde        100        8       54     1576 
 2050 oli      /usr/bin/gpg-agent --daemon      104      256      278     1924 
 2056 oli      /usr/bin/dbus-daemon --fork      200     1740     1820     4480 
 1951 oli      /usr/bin/gnome-keyring-daem      212      704      887     5768 
 2132 oli      /usr/bin/dbus-daemon --conf      216      712      806     3924 
 2052 oli      /usr/bin/ssh-agent /usr/bin      252      204      209      908 
 2315 oli      /usr/lib/bluetooth/obexd         260     1084     1345     7936 
 2127 oli      /usr/lib/at-spi2-core/at-sp      264      536      625     5700 
 1228 sddm     (sd-pam)                         300     1412     1728     3036 
 1476 sddm     /usr/bin/dbus-daemon --fork      328       56      143     2748 
 1946 oli      (sd-pam)                         364     1216     1615     3132 
 1475 sddm     dbus-launch --autolaunch 61      396        8       28     2252 
 2055 oli      /usr/bin/dbus-launch --exit      400        8       24     2160 
 1223 sddm     /lib/systemd/systemd --user      444      432      995     4376 
 1937 oli      /lib/systemd/systemd --user      448      404      971     4400 
 2144 oli      kwrapper5 /usr/bin/ksmserve      468        4      102     6356 
 2134 oli      /usr/lib/at-spi2-core/at-sp      488      268      343     5776 
 2223 oli      akonadiserver                    616    11196    11401    21988 
 1129 root     /usr/bin/sddm                    724      716      963    11848 
 2277 oli      ./TeamDrive.bin autostart        772   352656   353309   365768 
 2298 oli      python /usr/bin/hp-systray       992     4904     7157    15340 
 2162 oli      /usr/lib/telepathy/mission-     1104     1196     1540     8640 
 2166 oli      /usr/lib/x86_64-linux-gnu/l     1132      696      973    15148 
 1934 root     /usr/lib/x86_64-linux-gnu/s     1172      352      802    10996 
 2177 oli      /usr/bin/baloo_file             1172    74356    74784    90584 
 2208 oli      /usr/bin/pulseaudio --start     1312     4520     4897    10672 
 2299 oli      python /usr/bin/hp-systray      1480     3152     5448    11184 
 2146 oli      /usr/bin/ksmserver              2256     5024     6013    34104 
 2115 oli      kdeinit5: Running...            2324      264      748    15492 
 2116 oli      klauncher [kdeinit5] --fd=9     2352     1256     1997    21712 
 2154 oli      /usr/bin/kactivitymanagerd      2472     4588     5337    29772 
 2284 oli      python /usr/bin/hp-systray      2572    15216    18372    37452 
 1956 oli      /usr/bin/kwalletd5 --pam-lo     2616     5272     6454    37400 
 2219 oli      /usr/bin/akonadi_control        2652     2048     2450    23964 
 2195 oli      /usr/bin/xembedsniproxy         2660      968     1405    23600 
 2190 oli      /usr/lib/x86_64-linux-gnu/l     2704     1172     1703    26716 
 1954 oli      /usr/bin/kwalletd --pam-log     3144     1180     1601    12784 
 2124 oli      /usr/bin/kaccess                3148      708     1110    21276 
 2151 oli      /usr/bin/kglobalaccel5          3288     1316     1799    25164 
 2203 oli      /usr/bin/korgac -session 10     4760     1384     2093    28576 
 2118 oli      kded5 [kdeinit5]                5016    77440    78828   107932 
 2217 oli      /usr/bin/knotes -session 10     5768     7048     8467    41744 
 2179 oli      /usr/bin/krunner               11200    16276    19166    55272 
 1148 root     /usr/lib/xorg/Xorg -noliste    13316    31464    45953    68016 
 2167 oli      kwin_x11 -session 106368656    13444    35972    39318    76556 
 2186 oli      /usr/bin/plasmashell --shut    19096    90608    94701   135284 
 2224 oli      /usr/sbin/mysqld --defaults    29988   148588   148624   151832 
-------------------------------------------------------------------------------
  170 14                                     150808  4085792  4318525  6436312 

# sudo smem --totals --sort=swap | grep -e mysql -e Command
  PID User     Command                         Swap      USS      PSS      RSS 
 6903 mysql    /home/mysql/product/mariadb        0   191000   191071   194964 
16937 mysql    /home/mysql/product/mysql-8        0   358812   358865   362364 
17480 mysql    /home/mysql/product/mysql-5        0   271420   273310   278692 
28484 root     grep -e mysql -e Command           0      352      395     2404 
29071 mysql    /bin/sh bin/mysqld_safe --d        0      152      227     1724 
29326 mysql    /home/mysql/product/mysql-5        0   506848   508747   514268 
 2224 oli      /usr/sbin/mysqld --defaults    29988   148588   148624   151832 

Cool new features in FromDual Backup and Recovery Manager 2.0.0

A while ago we released our FromDual Backup and Recovery Manager (brman) 2.0.0 for MariaDB and MySQL. So what are the new cool features of this new release?

Bug about CONSTANT

Taxonomy upgrade extras: 

MariaDB Bug number 16476: https://jira.mariadb.org/browse/MDEV-16476. Seems like it will be fixed soon…?

Select Hello World FromDual with MariaDB PL/SQL

MariaDB 10.3 was released GA a few weeks ago. One of the features which interests me most is the MariaDB Oracle PL/SQL compatibility mode.

Special MySQL and MariaDB trainings 2018 in English

Due to a strong customer demand FromDual offers 2018 two extra MySQL/MariaDB trainings with its Training partner The Linuxhotel in Essen (Germany). Those trainings are in English.

MariaDB at FromDual

Taxonomy upgrade extras: 

FromDual as a neutral and vendor independent database service company also provides various services for the MariaDB database.

MySQL sys Schema in MariaDB 10.2

Taxonomy upgrade extras: 

MySQL has introduced the PERFORMANCE_SCHEMA (P_S) in MySQL 5.5 and made it really usable in MySQL 5.6 and added some enhancements in MySQL 5.7 and 8.0.

MariaDB 10.2 New Features - Slides available

Taxonomy upgrade extras: 

The Chemnitz Linux Days 2018 in Chemnitz (Germany) 10/11 March 2018 are over for more than a week now and IMHO it was a huge success.

MySQL Environment MyEnv 2.0.0 has been released

FromDual has the pleasure to announce the release of the new version 2.0.0 of its popular MySQL, Galera Cluster and MariaDB multi-instance environment MyEnv.

Advanced MySQL Enterprise Training by FromDual

Taxonomy upgrade extras: 

Due to the increasing demand FromDual has developed an Advanced MySQL Enterprise Training for DBAs and DevOps. After testing this training extensively with some selected customers last year we offer this MySQL Enterprise Training in 2018 for a broader audience.

MySQL 8.0.4-rc is out

Taxonomy upgrade extras: 

Yesterday MySQL 8.0.4-rc came out. The Release Notes are quite long.
But caution: Do a BACKUP before upgrading…

Advanced MySQL and MariaDB training in Cologne 2018

Taxonomy upgrade extras: 

End of February, from February 26 to March 2 (5 days), FromDual offers an additional training for DBAs and DevOps: our most visited Advanced MySQL and MariaDB training.

Oracle releases MySQL security vulnerability fixes 2018-01

Taxonomy upgrade extras: 

As in every quarter of the year Oracle has released yesterday its recommendation for the MySQL security updates. This is called, in Oracle terminology, Critical Patch Update (CPU) Advisory.

Galera Cluster and Antivirus Scanner on Linux

Taxonomy upgrade extras: 

Today we had to investigate in a very strange behaviour of IST and SST on a MariaDB Galera Cluster.

First Docker steps with MySQL and MariaDB

Taxonomy upgrade extras: 

The Docker version of the distributions are often quite old. On Ubuntu 16.04 for example:

MariaDB Master/Master GTID based Replication with keepalived VIP

Important: FromDual does NOT recommend to use an automated VIP failover technology as described below for a MariaDB/MySQL Master/Master Replication. In such a topology we recommend a manual VIP failover with prepared scripts!

Galera Load Balancer the underestimated wallflower

There are some pretty sophisticated Load Balancers for Galera Clusters setups out in the market (ProxySQL, MaxScale, HAproxy, …). They have many different exotic features. You can nearly do everything with them. But this comes at the cost of complexity. Non of them is simple any more.

Solution: Slow Queries not using Indexes

Taxonomy upgrade extras: 

There are 2 different ways to solve this task.

The first way is by enabling the variable log_queries_not_using_indexes (MariaDB/MySQL). This can be done eigther online:

Solution: SELECT Query with LAST_INSERT_ID()

Taxonomy upgrade extras: 

The query is so evil/slow because it does a Full Index Scan (FIS). Other call this operation also a Index Fast Full Scan (IFFS). This is much too much work for the result wanted (the value of the AUTO_INCREMENT column).

Find evil developer habits with log_queries_not_using_indexes

Recently I switched on the MariaDB slow query logging flag log_queries_not_using_indexes just for curiosity on one of our customers systems:

Storing BLOBs in the database

Taxonomy upgrade extras: 

We have sometimes discussions with our customers whether to store LOBs (Large Objects) in the database or not. To not rephrase the arguments again and again I have summarized them in the following lines.

MySQL Enterprise Backup Incremental Cumulative and Differential Backup

Preparing the MySQL Enterprise Administrator Training I found that the MySQL Enterprise Backup Incremental Backup is not described very well. Thus I tried it out and wrote down this how-to:

How the Lack of a Primary Key May Effectively Stop the Slave

Taxonomy upgrade extras: 

Most (relational) DBAs and DB application developers know the concept of a primary key (“PK”) and what it is good for. However, much too often one still encounters table definitions without a PK. True, the relational theory based on sets does not need a PK, and all operations (insert, select, update, delete) can also be done on tables for which no PK was defined. If performance doesn’t matter (or the data volume is small, a typical situation in tests), the lack of a PK does not immediately cause negative consequences.

Hello.

Taxonomy upgrade extras: 

Hello. Do you check my configuration?

Log file

Taxonomy upgrade extras: 

Your log file does not show any reason:

6644:2017-03-08 23:13:02.115 - INFO: FromDual Performance Monitor for MySQL and MariaDB (fpmmm) (1.0.1) run started. 6644:2017-03-08 23:13:02.809 - DBG : /usr/bin/zabbix_sender –zabbix-server

My suggestion is that the

Taxonomy upgrade extras: 

My suggestion is that the fpmmm when user with zabbix agent dot have enough time to complete all cycle. Zabbix show me “Timeout while executing a shell script.” on FromDual.MySQL.check variable.

Fixes and suggestions

Taxonomy upgrade extras: 

Hello hranitel

Thanks for your comments.

to 1) it will be fixed in next release in fact it is already fixed in rev763.

Hello, thank you for reply.

Taxonomy upgrade extras: 

Hello, thank you for reply.

  1. About additional “\n” - in myEnv.inc file, in the end 2 empty lines.
  2. Problem was in zabbix-agentd.conf. FPMMM need more time to run. So I add “Timeout=30” variable, to fix the problem

Also, set in php.ini variables_order = “EGPCS” for all server(i don’t have dedicated server for mysql) is not good idea. So i changed first string of fpmmm.php to this #!/usr/bin/php -d variables_order=EGPCS

fpmmm agentd died

Taxonomy upgrade extras: 

Hello Vadim

Thank you for your suggestion. I am pretty sure that the empty line is not the problem. But I admit that it is a bug and it will be fixed in the next release (in fact it is already fixed in our internal revision 763). But it is IMHO not critical and will not affect your work.

fpmmm & Zabbix

Taxonomy upgrade extras: 

Hello,

I installed fpmmm 1.0.1 to my system and try to start it with zabbix-agent (UserParameter=FromDual.MySQL.check,/opt/fpmmm/bin/fpmmm --config=/etc/fpmmm/fpmmm.conf). Trigger fpmmm Agent is down not working, and all data update with 10 minutes interval or doesn’t update at all.

MySQL and MariaDB authentication against pam_unix

Taxonomy upgrade extras: 

The PAM authentication plugin is an extension included in MySQL Enterprise Edition (since 5.5) and in MariaDB (since 5.2).

Solved problem

Taxonomy upgrade extras: 

I somehow solved my problem : might not be optimal, but it just works :

FromDual Performance Monitor for MySQL and MariaDB 1.0.1 has been released

FromDual has the pleasure to announce the release of the new version 1.0.1 of its popular Database Performance Monitor for MySQL, MariaDB, Galera Cluster and Percona Server fpmmm.

Is your MySQL software Cluster ready?

When we do Galera Cluster consulting we always discuss with the customer if his software is Galera Cluster ready. This basically means: Can the software cope with the Galera Cluster specifics?

MySQL replication with filtering is dangerous

From time to time we see in customer engagements that MySQL Master/Slave replication is set-up doing schema or table level replication filtering. This can be done either on Master or on Slave. If filtering is done on the Master (by the binlog_{do|ignore}_db settings), the binary log becomes incomplete and cannot be used for a proper Point-in-Time-Recovery. Therefore FromDual recommends AGAINST this approach.

Reset MySQL 5.7 password on macOS over the command line

Taxonomy upgrade extras: 

This one is for all MySQL-DBA’s, which are working on macOS. Since the Apple OS has a rather peculiar way of starting and stopping MySQL, compared to Linux, you can run into some issues. These problems occur especially, if you have no access to the GUI.

systemd and sudo

Taxonomy upgrade extras: 

This script probably will not work on Linux systems with systemd (CentOS 7, Ubuntu 16.04, etc.). Systemd cages a process and it seems like sudo rules do not apply any more for a process started with systemd. We are investigating in this…

systemd and sudo

Taxonomy upgrade extras: 

This script probably will not work on Linux systems with systemd (CentOS 7, Ubuntu 16.04, etc.). Systemd cages a process and it seems like sudo rules do not apply any more for a process started with systemd. We are investigating in this…

Non-standard database set up with SELinux

Taxonomy upgrade extras: 

What is SELinux?

The Security-Enhanced Linux is an extension to the Linux Kernel, made by the NSA (National Security Agency). It implements Mandatory Access Controls (MAC), which allow an administrator to define, how applications and users can access resources on a system.

MySQL and MariaDB variables inflation

Taxonomy upgrade extras: 

MySQL is well known and widely spread because of its philosophy of Keep it Simple (KISS).

New Features in MySQL and MariaDB

Taxonomy upgrade extras: 

As you probably know MySQL is an Open Source product licensed under the GPL v2. The GPL grants you the right to not just read and understand the code of the product but also to use, modify AND redistribute the code as long as you follow the GPL rules.

FromDual Performance Monitor for MySQL and MariaDB 1.0.0 has been released

FromDual has the pleasure to announce the release of the new version 1.0.0 of its popular Database Performance Monitor for MySQL, MariaDB, Galera Cluster and Percona Server fpmmm.

Multi-Instance set-up with MySQL Enterprise Server 5.7 on RHEL 7 with SystemD

In our current project the customer wants to install and run multiple MySQL Enterprise Server 5.7 Instances on the same machine (yes, I know about virtualization (we run on kvm), containers, Docker, etc.). He wants to use Redhat Enterprise Linux (RHEL) 7 which brings the additional challenge of SystemD. So mysqld_multi is NOT an option any more.

Enterprise Server vs Community Server packages

Taxonomy upgrade extras: 

I found out that we were wrong in this. We have taken RHEL6 MySQL RPM packages instead of RHEL7 packages. This is the reason why the installation was not smooth (but it worked) and why still old sysV init scripts were used.

EditLine vs ReadLine

Taxonomy upgrade extras: 

I was informed that nowadays MySQL Enterprise Server and MySQL Community Server use both EditLine (since MySQL 5.6?).

What are the differences between MySQL Community and MySQL Enterprise Server 5.7

The MySQL Server itself

The differences between the MySQL Community Server and the MySQL Enterprise Server 5.7 are as follows as claimed by Oracle:

MySQL 5.7.16 behaves diefferntly thant MySQL 5.7.15

Taxonomy upgrade extras: 

With 5.7.15 we had some strange installation errors which disappeared with 5.7.16. Further we found, that 5.7.15 still uses SysV init scripts and 5.7.16 has switched to SystemD…

How to build your own RPM repository for MySQL Enterprise Server 5.7 on RHEL 7

Prepare the RPM repository server

Install the software to create a RPM repository server (on an Ubuntu web server):

How to Install MySQL Enterprise Server 5.7 on Red Hat Enterprise Linux 7

If you have already Red Hat Enterprise Linux 7 (RHEL 7) or CentOS 7 in use you probably found out, that it is not that easy to install MySQL Enterprise Server because there are already pre-installed MariaDB 5.5 libraries:

The same for the MySQL 5.7 Community Server

Taxonomy upgrade extras: 

The same should apply for the MySQL 5.7 Community Server…

How to move InnoDB-Logfiles on a Galera Cluster

Taxonomy upgrade extras: 

Somebody recently asked, what they had to do, if they wanted to move their InnoDB-Logfiles back to the datadir. As a challenge, the servers were part of a Galera Cluster.

Show overmounted files

Taxonomy upgrade extras: 

Another idea we discussed (but does not fit to the problem) is lost space due to over-mounted directories. If you have some files in this directory they are not shown any more (= hidden) because they are over-mounted but they are still there an used space.

Deleted files still (growing) on disk

Taxonomy upgrade extras: 

For this phenomenon, the relevant documentation is here: deleting files. Close to the top, see this sentence:

Beware of large MySQL max_sort_length parameter

Taxonomy upgrade extras: 

Today we had a very interesting phenomena at a customer. He complained that MySQL always get some errors of the following type:

FromDual Performance Monitor for MySQL and MariaDB 0.10.6 has been released

FromDual has the pleasure to announce the release of the new version 0.10.6 of its popular Database Performance Monitor for MySQL, MariaDB, Galera Cluster and Percona Server fpmmm.

MySQL Environment MyEnv 1.3.1 has been released

FromDual has the pleasure to announce the release of the new version 1.3.1 of its popular MySQL, Galera Cluster, MariaDB and Percona Server multi-instance environment MyEnv.

Multiple MySQL Instances on a Single Machine

Taxonomy upgrade extras: 

Typically, on a single machine (be it a physical or a virtual one) only a single MySQL instance (process) is running. This is perfectly ok for all those situations where a single instance is sufficient, like for storing small amounts of data (RedHat using MySQL for postfix, KDE using it for akonadi, …), as well as those where a dedicated machine per MySQL instance is appropriate (high CPU load, memory fully loaded, availability requirements).

Temporary tables and MySQL STATUS information

Taxonomy upgrade extras: 

When analysing MySQL configuration and status information at customers it is always interesting to see how the applications behave. This can partially be seen by the output of the SHOW GLOBAL STATUS command. See also Reading MySQL fingerprints.

Why is varchar(255) not varchar(255)?

Taxonomy upgrade extras: 

Recently I was working on a clients question and stumbled over an issue with replication and mixed character sets. The client asked, wether it is possible to replicate data to a table on a MySQL slave, where one column had a different character set, than the column in the same table on the master.

MySQL spatial functionality - points of interest around me

Taxonomy upgrade extras: 

This week I was preparing the exercises for our MySQL/MariaDB for Beginners training. One of the exercises of the training is about MySQL spatial (GIS) features. I always tell customers: “With these features you can answer questions like: Give me all points of interest around me!”

Why you should take care of MySQL data types

Taxonomy upgrade extras: 

A customer reported last month that MySQL does a full table scan (FTS) if a query was filtered by a INT value on a VARCHAR column. First I told him that this is not true any more because MySQL has fixed this behaviour long time ago. He showed me that I was wrong:

How to become a certified DBA

Taxonomy upgrade extras: 

I recently managed to get my certification as MySQL 5.6 DBA, and was asked to write a blog about it, because I had trouble getting the informations I needed.

Differences between MySQL and MariaDB

Taxonomy upgrade extras: 
  • max_user_connections Can be changed online in MySQL. Cannot be changed in MariaDB if value was set to 0.
  • PERFORMANCE_SCHEMA is enabled in MySQL 5.6 and 5.7 by default. In MariaDB disabled by default.
  • Replication incompatibilities from MariaDB (Master) to MySQL (Slave)
  • MariaDB 10.2.0 still contains XtraDB 5.6. So MySQL 5.7 features cannot be used.
  • MariaDB 10.2 Window Functions are missing in MySQL 5.7
  • SHOW PROCESSLIST has additional column Progress in MariaDB.
  • Progress indication in: mysqldump --progress-reports (default on) for MariaDB.
  • MariaDB 10.0 on CentOS 7 uses still SysV init script. MySQL 5.6 on CentOS 7 uses SystemD init script.
  • binlog_row_image is implemented in MySQL 5.6 and does not exist in MariaDB 10.0.
  • MariaDB 10.1 and older (containing XtraDB 5.6) does not provide flexible/general tablespaces yet which where introduced by MySQL 5.7.
  • EXPLAIN FOR CONNCECTION does exist in MySQL 5.7 and does not exist in MariaDB 10.1 or 10.2.

Other sources

MariaDB 10.2 Window Function Examples

MariaDB 10.2 has introduced some Window Functions for analytical queries.

Define preferred SST donor for Galera Cluster

Taxonomy upgrade extras: 

One of our customers recently ran into a problem, where he wanted to have a preferred donor for SST, whenever a node came up. The problem was, that the node did not come up, when the preferred donor was not running.

Past and Future Conferences, and Talks Around MySQL

Taxonomy upgrade extras: 

Time flies, and my blogging frequency is quite low. More frequent would be better, but knowing myself I’ll rather not promise anything ;-)

Verification of the formula

Taxonomy upgrade extras: 

Yesterday we did a first real life test of the formulas and the predictions of all 3 methods where quite congruent… So I personally trust them!

Galera Cache sizing

Taxonomy upgrade extras: 

To synchronize the data between the Galera Cluster and a new or re-entering Galera node Galera Cluster uses 2 different mechanisms:

FPMMM Agent: got TERM signal

Taxonomy upgrade extras: 

MySQL Performance Monitor agent gets a TERM signal from time to time:

On Files, the Space They Need, and the Space They Take

Taxonomy upgrade extras: 

or

xfs Users, Take Care!

Recently, we had a customer ask: Why do many files holding my data take up vastly more space than their size is? That question may sound weird to you, but it is for real, and the customer’s observation was correct. For a start, let’s make sure we are using the same terms.

Hello DBStarter

Taxonomy upgrade extras: 

Hello DBStarter

First of all a few things:

  • About MariaDB documentation: I would say the MariaDB documentation is not too bad compared to other open source project documentation or even enterprise software documentation. But its far from being brilliant.

FOSDEM 2016 - MySQL slides about PERFORMANCE_SCHEMA available

The FOSDEM 2016 in Brussels (Belgium) January 29/30 is over and was very interesting and IMHO a big success.

MySQL Environment MyEnv 1.3.0 has been released

FromDual has the pleasure to announce the release of the new version 1.3.0 of its popular MySQL, Galera Cluster, MariaDB and Percona Server multi-instance environment MyEnv.

Replication in a star

Taxonomy upgrade extras: 

Most of you know, that it is possible to synchronize MySQL and MariaDB servers using replication. But with the latest releases, it is also possible to use more than just two servers as a multi-master setup.

MariaDB maintenance tasks

Taxonomy upgrade extras: 

Hello together, sorry for the placement of this thread in this MySQL generalls topic. Was not sure where to post :/ I try to understand how to maintenance a database in the MariaDB World. But to be honest i have never seen before a bad technical documentation like from MariaDB. I located tasks like using ANALYZE TABLES or OPTIMIZE TABLE. Are there any other maintenance task that a DBA should operate? Some keywords explicit to MariaDB would be enough, please no general answers like reindexing or defragmenting. Thanks. Kind Regards from Germany.

binlog_rows_query_log_events

Taxonomy upgrade extras: 

Hi oli

Since MySQL 5.6.2 there is a new MySQL variable called binlog_rows_query_log_events. If you enable this variable MySQL will write the original SQL statements into the binary logs. More information about this variable you can find here:

How to Get a Galera Cluster Into Split Brain

Taxonomy upgrade extras: 

“Split Brain” is the term commonly used for a cluster whose nodes have different contents, rather than identical as they should have. Typically, a “split brain” situation is the DBA’s nightmare, and the Galera software is designed to avoid it. Galera is very successful in that avoidance, and it needs some special steps by the DBA to achieve “split brain”. Here is how to do it - or, for most DBAs, what to avoid doing to not get a split-brain cluster.

MySQL Binary Log and original SQL statement

Taxonomy upgrade extras: 

Hello all

we use MySQL binary logging with binlog_format = row. With mysqlbinlog -v binary-log.000001 we can see proximately how the original query looked like. But this is a transformation from row events into pseudo SQL statements.

MySQL Binary Log Filter does not work

Problem

We use the following binary log filter for filtering out some schemata.

Migration of SQLite to MySQL

Taxonomy upgrade extras: 

In my first Blog ever, I am going to cover the migration of a SQLite-Database to MySQL. The Tool used is MySQL-Workbench, which you can Download from the MySQL website. In this particular case, it is about the upgrade of mocenter 0.2 to 0.3.

MySQL Environment MyEnv 1.2.2 has been released

FromDual has the pleasure to announce the release of the new version 1.2.2 of its popular MySQL, Galera Cluster, MariaDB and Percona Server multi-instance environment MyEnv.

MySQL Replication Slave is lagging more and more

Problem

My MySQL Replication Slave is lagging more and more and I have no clue why. This happens since last weekends application change. I see that one Core is running at 100% user time but the I/O system is nearly completely idle. Any help is appreciated!

FromDual Performance Monitor for MySQL and MariaDB 0.10.5 has been released

FromDual has the pleasure to announce the release of the new version 0.10.5 of its popular Database Performance Monitor for MySQL, MariaDB, Galera Cluster and Percona Server fpmmm.

Change: Port needed

Taxonomy upgrade extras: 

With Galera version 25.3.10, the “garbd” daemon would not start unless I appended the port number (default: 4567) to the IP addresses of the cluster nodes.
The failure symptom was that an exception “gu::NotSet” was thrown, without any helpful information what it was really missing.

Max_used_connections per user/account

How many connections can be opened concurrently against my MySQL or MariaDB database can be configured and checked with the following command:

MySQL Environment MyEnv 1.2.1 has been released

FromDual has the pleasure to announce the release of the new version 1.2.1 of its popular MySQL, Galera Cluster, MariaDB and Percona Server multi-instance environment MyEnv.

InnoDB plugin is enabled

Taxonomy upgrade extras: 

InnoDB plugin is enabled.

InnoDB Log File size is too small

The InnoDB Log File (innodb_log_file_size) size is possibly too small.
Choosing a too small InnoDB Log File size can have significant write performance impacts.

InnoDB Foreign Key error detected

MySQL (InnoDB, PBXT, NDB, TokuDB) support Foreign Keys to show relatations between tables. Those relations can be enforced through Foreign Key Constraints.

InnoDB Force Recovery is enabled

Taxonomy upgrade extras: 

InnoDB Force Recovery (innodb_force_recovery) is enabled. This mode should be used for data recovery purposes only. It prohibits writing to the data.

InnoDB Flush Log at Transaction Commit

InnoDB Flush Log at Transaction Commit is set to a values != 1. This can lead to a loss of committed transactions in case of a power failure or an unclean shutdown of your database.

InnoDB Deadlock detected

Taxonomy upgrade extras: 

You got an InnoDB Deadlock. Please talk to your development department to fix this problem. Deadlocks are an application problem!

InnoDB Buffer Pool Instances is too small

If you are using MariaDB/MySQL 5.5 and newer you should use several InnoDB Buffer Pool Instances for performance reasons.
Some rules to size InnoDB Buffer Pool instances are:

MySQL Replication Slave with corrupt Relay Logs

Problem

MySQL Replication Slave stuck because its disk run full. After restarting the Slave MySQL replication was broken with the following error:

Binlog format MIXED with filtering

Binlog format MIXED changes the binary log format (ROW or STATEMENT) depending on the queries (deterministic or not). This makes it impossible to define 100% correctly working binary log filter rules.

Flush time is set

If the variable flush_time is set to a non-zero value, all tables are closed (and flushed) every flush_time seconds to disk. This can cause unnecessary and high I/O spikes.

Table definition cache too small

The number of table definitions (SHOW CREATE TABLE<br>G) that can be stored in the table definition cache (table_definition_cache). If you have a large number of tables (
> 400) in your database instance, you should consider a larger table definition cache to increase your database throughput and decrease your query latency.
The command SELECT COUNT(*) FROM information_schema.tables; shows you how many tables and thus table definitions you have. The global status Open_table_definitions is the current amount of open table definitions.

Table open cache too small

The Table Open Cache (table_open_cache or old name table_cache) is a cache to store file handles for all threads. The actual value of cache entries can be seen with the global status of open tables (Open_tables).
Increasing table_open_cache increases the number of file descriptors (open_files_limit) that MySQL requires.
You can check whether you need to increase the Table Open Cache by checking Open_tables and Opened_tables. If the value of Opened_tables is large and you do not use FLUSH TABLES often (which just forces all tables to be closed and reopened), then you should increase the value of the table_open_cache variable.

Limitations of Galera Cluster

Taxonomy upgrade extras: 

If and how to use Galera Cluster for MySQL has been described already by many others…

InnoDB Flush Method has changed

The InnoDB Flush Method has changed. This can have an impact on InnoDB write Performance.

The Upcoming Leap Second

Taxonomy upgrade extras: 

The press, be it the general daily newspaper or the computer magazines, is currently informing the public about an upcoming leap second, which will be taken in the night from June 30 to July 1 at 00:00:00 UTC. While we Europeans will enjoy our well-deserved sleep then, this will be at 5 PM (17:00) local time on June 30 for Califormia people, and during the morning of July 1 for people in China, Japan, Korea, or Australia. (Other countries not mentioned for the sake of brevity.) This is different from last time, when the leap second was taken in the night from Saturday to Sunday (2012-July-1 00:00:00 UTC), so it was a weekend everywhere on the globe.

Search with special characters

Taxonomy upgrade extras: 

How can I search the following string in a text field: ‘%newline,tabluator,b)%’?

SQL search for special characters

Taxonomy upgrade extras: 

The following example should work for you:

CREATE TABLE spec(txt VARCHAR(255));

How is a correct MariaDB/MySQL backup done?

Taxonomy upgrade extras: 

You find many different possibilities how to do a MariaDB/MySQL backup with mariadb-dump/mysqldump. But which one is the correct one?

FromDual Performance Monitor for MySQL and MariaDB 0.10.4 has been released

FromDual has the pleasure to announce the release of the new version 0.10.4 of its popular Database Performance Monitor for MySQL, MariaDB, Galera Cluster and Percona Server fpmmm.

Controlling worldwide manufacturing plants with MySQL

A MySQL customer of FromDual has different manufacturing plants spread across the globe. They are operated by local companies. FromDuals customer wants to maintain the manufacturing receipts centralized in a MySQL database in the Head Quarter in Europe. Each manufacturing plant should only see their specific data.

FromDual Performance Monitor for MySQL and MariaDB 0.10.1 has been released

FromDual has the pleasure to announce the release of the new version 0.10.1 of its popular Database Performance Monitor for MySQL, MariaDB, Galera Cluster and Percona Server fpmmm.

MySQL Environment MyEnv 1.2.0 has been released

FromDual has the pleasure to announce the release of the new version 1.2.0 of its popular MySQL, Galera Cluster, MariaDB and Percona Server multi-instance environment MyEnv.

Galera and tables without a Primary Key

Taxonomy upgrade extras: 

We finally got the results. The table does NOT have a Primary Key and/or an index on lSessionId:

Logging Galera Cluster conflicts

We typically suggest our customers to use our MySQL/Galera Cluster my.cnf configuration template to avoid MySQL configuration and performance problems.

Galera Cluster last inactive check and VMware snapshots

Taxonomy upgrade extras: 

From time to time we see at Galera Cluster customer engagements the following, for me scary, warning in the MySQL error log:

Rename MySQL Partition

Taxonomy upgrade extras: 

Before I forget it and have to search again here a short note about how to rename a MySQL Partition:

mpm run overpasses older one

Taxonomy upgrade extras: 

This error is NOT serious. It happens, when one MPM run overpasses an older one or when you start a second run manually.

Nagios and Icinga plugins for MySQL/MariaDB released

FromDual is pleased to announce the release of a new version 1.0.0 of the Nagios and Icinga plugins for MySQL, MariaDB, Percona Server and Galera Cluster.

MySQL Enterprise Incremental Backup simplified

MySQL Enterprise Backup (MEB) has the capability to make real incremental (differential and cumulative?) backups. The actual releases are quite cool and you should really look at it…

mpm/fpmmm module

Taxonomy upgrade extras: 

Hi burps

In Zabbix we have “hosts”. In MPM a host is either a server (DBSERVER01) or a MySQL Instance (mysqld).

Creating Event Handlers with MySQL Enterprise Monitor

MySQL Enterprise Monitor (MEM) has by default no Event Handlers created and activated. These Event Handlers you have to define yourself according to your needs.

MySQL Environment MyEnv 1.1.4 has been released

FromDual has the pleasure to announce the release of the new version 1.1.4 of its popular MySQL, Galera Cluster, MariaDB and Percona Server multi-instance environment MyEnv.

mpm configuration

Taxonomy upgrade extras: 

Hi,

I have trouble to understand the settings of the different sections :
[default
],
[db_server
]…

Nagios and Icinga plugins for MySQL 1.0.0 have been released

FromDual has the pleasure to announce the release of the new version 1.0.0 of its widely used Nagios and Icinga plugins for MySQL, Galera Cluster, MariaDB and Percona Server.

Linuxtag: Knowledge and People - and New Colleagues?

Taxonomy upgrade extras: 

At FromDual, we are currently preparing for our participation in the “Chemnitzer Linux-Tage” in March.
While we don’t yet know whether the programme committee accepted our proposed talks, we will have a booth and hope for interesting exchanges with others from the MySQL, database, Linux, … world. Of course, we will also mention that we are looking for additional colleagues - there are so many tasks that we need more people to handle them all. (In case you got curious, look here: http://www.fromdual.com/mysql-dba-2014-12-de )

Download MySQL Enterprise Features

MySQL provides some great enterprise features beside the MySQL Server. The ones we are asked the most at customers are:

MySQL table Point-in-Time-Recovery from mysqldump backup

Sometimes we face the situation where we have a full MySQL database backup done with mysqldump and then we have to restore and recover just one single table out of our huge mysqldump file.
Further our mysqldump backup was taken hours ago so we want to recover all the changes on that table since our backup was taken up to the end.

Later Findings ...

Taxonomy upgrade extras: 

… show that this is expected behavior:

  • Galera will replicate a DDL statement first, before it gets executed locally.
  • Local execution will fail, because the "super" privilege is a global one, it cannot be granted for a specific database "db.*" but only for all of them "*.*"
  • Of course, execution on the other nodes will fail in the same way.
So: While it looks ugly, it is nothing to worry about.

Introducing Myself: Jörg Brühe

Taxonomy upgrade extras: 

For some time already, FromDual’s “Our Team” page lists me, and it even reveals that I joined in September, 2014. Also for some time, the list of FromDual blogs contains an entry “Jörg’s Blog”, but it doesn’t lead to any entries. It is high time to fix this and create entries, starting with an introduction of myself.

Impacts of max_allowed_packet size problems on your MySQL database

We recently run into some troubles with max_allowed_packet size problems during backups with the FromDual Backup/Recovery Manager and thus I investigated a bit more in the symptoms of such problems.

max_open_files

Taxonomy upgrade extras: 

Hello oli,

every user/process on a UNIX system has some user limits. There are some soft (S) and hard (H) user limits. Soft limits a user can change himself up to the hard limits.

Could not increase number of max_open_files

Hello all, on some Linux systems I get the following warning during my MySQL database start-up:

Warning user entry ignored in MySQL error log

Taxonomy upgrade extras: 

Hello all,

I am getting some MySQL warnings in the error log during the start-up:

skip_name_resolve

Taxonomy upgrade extras: 

Hello oli,

it looks like you have enabled skip_name_resolve in your my.cnf.
This prevents MySQL to do (DNS) host lookups. If you have created some users with explicit host names MySQL wants to tell you now that you cannot use these users any more with this configuration. Example:

innodb_checkpoint_age in plain MySQL?

Taxonomy upgrade extras: 

In Percona Server we have a STATUS variable indicating roughly possible recovery time:

InnoDB Checkpoint age

Taxonomy upgrade extras: 

Looking at Percona Server source code we can find the following:

Support policy for MariaDB, MySQL and PostgreSQL

Table of Contents

Lifetime Support Matrix for MariaDB Releases

Major versionGA dateLTSSupport end
MariaDB Database 5.1February 2010xFebruary 2015
MariaDB Database 5.2November 2010xNovember 2015
MariaDB Database 5.3February 2012xMarch 2017
MariaDB Database 5.5April 2012xMarch 2020
MariaDB Database 10.0March 2014xMarch 2019
MariaDB Database 10.1October 2015xOctober 2020
MariaDB Database 10.2May 2017xMay 2022
MariaDB Database 10.3May 2018xMay 2023
MariaDB Database 10.4June 2019xJune 2024
MariaDB Database 10.5June 2020xJune 2025
MariaDB Database 10.6July 2021xJuly 2026
MariaDB Database 10.7 1February 2022February 2023
MariaDB Database 10.8May 2022May 2023
MariaDB Database 10.9August 2022August 2023
MariaDB Database 10.10November 2022November 2023
MariaDB Database 10.11February 2023xFebruary 2028
MariaDB Database 11.0 4June 2023June 2024
MariaDB Database 11.1August 2023August 2024
MariaDB Database 11.2November 2023November 2024
MariaDB Database 11.3 5February 2024RR
MariaDB Database 11.4May 2024xMay 2029
MariaDB Database 11.5August 2024RR
MariaDB Database 11.6November 2024RR
MariaDB Database 11.7February 2025RR
MariaDB Database 11.8June 2025xJune 2030
MariaDB Database 12.0June 2025RR
MariaDB Database 12.1August 2025RR
MariaDB Database 12.2November 2025RR
MariaDB Database 12.3expected Q1 2026xQ1 2031

1 MariaDB Announces New Innovation Release Model

Avoid temporary disk tables with MySQL

Taxonomy upgrade extras: 

For processing SELECT queries MySQL needs some times the help of temporary tables. These temporary tables can be created either in memory or on disk.

Making HAProxy High Available for MySQL Galera Cluster

After properly installing and testing a Galera Cluster we see that the set-up is not finished yet. It needs something in front of the Galera Cluster that balances the load over all nodes.
So we install a load balancer in front of the Galera Cluster. Typically nowadays HAProxy is chosen for this purpose. But then we find, that the whole Galera Cluster is still not high available in case the load balancer fails or dies. So we need a second load balancer for high availability.
But how should we properly failover when the HAProxy load balancer dies? For this purpose we put a Virtual IP (VIP) in front of the HAProxy load balancer pair. The Virtual IP is controlled and failovered with Keepalived.

failed MySQL DDL commands and Galera replication

Taxonomy upgrade extras: 

We have recently seen a case where the following command was executed on a Galera Cluster node:

How to recover deleted tablespace?

Sometimes, MySQL tablespace file(s) might be deleted by mistake, e.g. delete the shared tablespace (ibdata1) or an individual tablespace (table_name.ibd).

Things you should consider before using GTID

Taxonomy upgrade extras: 

Global Transaction ID (GTID) is one of the major features that were introduced in MySQL 5.6 which provides a lot of benefits. I have talked about the GTID concept, implementation and possible troubleshooting at Percona Live London 2014, you can download the slides from our presentations repository or from my session at Percona Live.

Galera Cluster and XA Transactions

Taxonomy upgrade extras: 

A few weeks ago, we received an interesting Galera Cluster support case from one of our customers that the application is not working well and they face a lot of troubles in their Galera Cluster setup.

MySQL Environment MyEnv 1.1.2 has been released

FromDual has the pleasure to announce the release of the new version 1.1.2 of its popular MySQL, Galera, MariaDB and Percona Server multi-instance environment MyEnv.

Get rid of wrongly deleted InnoDB tables

Taxonomy upgrade extras: 

Precaution: Before you try this out on your production system do a BACKUP first! FromDual Backup Manager can help you with this.

socat dependency is also missing

Taxonomy upgrade extras: 
dpkg --force-all -i socat_1.7.2.3-1_amd64.deb

Ugly way to install MySQL Galera Cluster 5.6 on Ubuntu 14.04

Taxonomy upgrade extras: 

I wanted to install MySQL Galera Cluster 5.6 on the new Ubuntu 14.04 with provided packages. It was a bit tricky to make it work.

Query Cache and table names with special characters

Taxonomy upgrade extras: 

We found that there were similar problems with table names with a dash/minus in the name (e.g. `table-name`).
This seems to be fixed in MySQL 5.6.9 and 5.7.0. See bugs #55556, #62237 and #64821.

How to install multiple MySQL instances on a single host using MyEnv?

We have been asked several times by MySQL users about how to install multiple MySQL instances on a single host.
Typically, this is required when testing different MySQL versions or MySQL servers (MySQL server, Percona server and MariaDB server) while no available resources are available.
Sometimes, it is even required to install multiple MySQL instances on a single production server.

Migration between MySQL/Percona Server and MariaDB

This week, we did some migrations from MariaDB 10.0 to Percona Server 5.6 at the IT department of a big German bank.

Comparing MySQL, MariaDB and Percona Server

Taxonomy upgrade extras: 
MySQLPerconaMariaDB
CompanyOracle Corp.
(former MySQL AB)
Percona LLCMariaDB Corp.
(former SkySQL)
FromDual supportOk-icon.pngOk-icon.pngOk-icon.png
GA versions5.5, 5.65.5, 5.65.5, 10.0
Galera Clustersupportedsupportedsupported
LicenseGPL, commercial (OEM!)GPLGPL, LGPL, BSD
AncestryMother of allBranch of actual releaseFork of MySQL 5.5
Storage EnginesArchive, Blackhole, CSV, Federated (disabled), InnoDB (default), Memory, MyISAMArchive, Blackhole, CSV, Federated (disabled), InnoDB (default), Memory, MyISAM, TokuDBArchive, Aria (crash-safe MyISAM), Blackhole, Cassandra, CSV, FederatedX, InnoDB (default), Memory, MyISAM, OQGraph (Graph-SE), TokuDB
Storage Engine enforcementyes
Fulltext searchMyISAM: yes
InnoDB: yes
MyISAM: yes
InnoDB: yes
MyISAM: yes
Aria: yes
InnoDB: yes, Sphinx-SE
Partitionsavailableavailableavailable
PluginsAuth, Auth Socket, MemcacheD, SemiSync ReplAuth PAM, Auth Socket, Handlersocket, MemcacheD, SemiSync ReplAuth PAM, Auch Socket, Connect SE, Handlersocket, Sequence, Sphinx, Spider, QueryCache Info, SemiSync Repl
MemcacheDavailable
virtual ColumnsSince 5.7.6since 5.2
Performance
GeneralAll 3 branches/forks have roughly the same performance. They mostly distinguish in features not in performance.
PERFORMANCE_SCHEMAenabled (5.6)enabled (5.6), userstatsenabled (10.0)
Thread Pool5.5, commercial plugin5.5 and 5.65.1 - 5.3 (old), 5.5 (new)
DML EXPLAIN5.65.6?
JSON EXPLAIN5.65.6?
Optimizer Trace5.65.6?
Table eliminationavailable
Security
Rolessince 10.0.5
Password expirationsince 5.6since 5.6since 10.0?
Password validationPlugin since 5.6.6Plugin since 5.6Worklog, comes in 10.1/10.2
Password complexitycommercial?
PAM AuthenticationMySQL 5.5, commercial pluginsince 5.5since 5.2
Backupmysqldump, mysqlbackupmysqldump, XtraBackupmysqldump, XtraBackup
Audit Plugin5.5 a, b
MyAfee Audit Plugin
5.5 and 5.6
MyAfee Audit Plugin
5.5
MyAfee Audit Plugin
Slow Query Logavailableavailable, improvedavailable
Replication
Master/SlaveOk-icon.pngOk-icon.pngOk-icon.png
multi-Source ReplicationMySQL 5.7-labsunknownMariaDB 10.0
parallel ReplicationMySQL 5.6 (per Schema)Percona 5.6 (per Schema)MariaDB 10.0 (per Instance!)
GTIDMySQL styleMySQL styleMariaDB style (incompatibility!)
MySQLPerconaMariaDB

MySQL Environment MyEnv 1.1.1 has been released

FromDual has the pleasure to announce the release of the new version 1.1.1 of its popular MySQL, MariaDB and Percona Server multi-instance environment MyEnv.

MySQL Environment MyEnv 1.1.0 has been released

FromDual has the pleasure to announce the release of the new version 1.1.0 of its popular MySQL, MariaDB and Percona Server multi-instance environment MyEnv.

Load of cache file failed. rc=1301

Taxonomy upgrade extras: 

Hello earl86

can you please set Debug = 4 in the mpm.conf and send us the output?

mpm monitor a server having Multiple database instances bug

Taxonomy upgrade extras: 

I used mpm to monitor a server which having 3 mysql database instance.I keep getting the below errors in the FromDual log file: 30666:2014-08-18 19:24:50.378 - INFO: FromDual Performance Monitor for MySQL (0.9.3) run started. 30666:2014-08-18 19:24:50.378 - INFO: FromDualMySQLagent::setAgentLock 30666:2014-08-18 19:24:50.378 - WARN: Agent Lock file /tmp/FromDualMySQLagent.lock already exists. 30666:2014-08-18 19:24:50.378 - WARN: Another agent with PID 30625 (our PID is 30666) is running. We will abort now. 30666:2014-08-18 19:24:50.378 - INFO: gRemoveLockFile is not set. 30666:2014-08-18 19:24:50.378 - INFO: FromDual Performance Monitor for MySQL run finshed (rc=1316). 711:2014-08-18 18:32:10.461 - INFO: writeDataToCacheFile::writeDataToCacheFile 712:2014-08-18 18:32:10.461 - INFO: FromDualMySQLagent::clearCacheFile 712:2014-08-18 18:32:10.461 - INFO: sendData::sendData 712:2014-08-18 18:32:10.461 - INFO: writeDataToCacheFile::writeDataToCacheFile 711:2014-08-18 18:32:10.462 - INFO: FromDualMySQLagent::checkConnectionToZabbixServer 712:2014-08-18 18:32:10.463 - INFO: FromDualMySQLagent::checkConnectionToZabbixServer 711:2014-08-18 18:32:10.468 - INFO: sendCachedData::sendCachedData 712:2014-08-18 18:32:10.468 - INFO: sendCachedData::sendCachedData 711:2014-08-18 18:32:10.472 - ERR : Load of cache file failed. rc=1301 712:2014-08-18 18:32:10.472 - ERR : Load of cache file failed. rc=1301 711:2014-08-18 18:32:10.473 - INFO: Processing module mysql for section mysql2 finished. 712:2014-08-18 18:32:10.473 - INFO: Processing module mysql for section mysql2 finished. 711:2014-08-18 18:32:10.473 - INFO: Processing module myisam for section mysql2 now… 712:2014-08-18 18:32:10.473 - INFO: Processing module myisam for section mysql2 now… 711:2014-08-18 18:32:10.476 - INFO: FromDualMySQLmyisam::processMyisamInformation 712:2014-08-18 18:32:10.476 - INFO: FromDualMySQLmyisam::processMyisamInformation 711:2014-08-18 18:32:10.477 - INFO: FromDualMySQLagent::getGlobalVariables 712:2014-08-18 18:32:10.477 - INFO: FromDualMySQLagent::getGlobalVariables 711:2014-08-18 18:32:10.487 - INFO: FromDualMySQLagent::getGlobalStatus 712:2014-08-18 18:32:10.488 - INFO: FromDualMySQLagent::getGlobalStatus 711:2014-08-18 18:32:10.498 - INFO: sendData::sendData 711:2014-08-18 18:32:10.498 - INFO: writeDataToCacheFile::writeDataToCacheFile 712:2014-08-18 18:32:10.498 - INFO: sendData::sendData 712:2014-08-18 18:32:10.498 - INFO: writeDataToCacheFile::writeDataToCacheFile 711:2014-08-18 18:32:10.499 - INFO: FromDualMySQLagent::checkConnectionToZabbixServer 712:2014-08-18 18:32:10.499 - INFO: FromDualMySQLagent::checkConnectionToZabbixServer 711:2014-08-18 18:32:10.505 - INFO: sendCachedData::sendCachedData 712:2014-08-18 18:32:10.505 - INFO: sendCachedData::sendCachedData 711:2014-08-18 18:32:10.509 - ERR : Load of cache file failed. rc=1301 711:2014-08-18 18:32:10.509 - INFO: sendData::sendData 711:2014-08-18 18:32:10.510 - INFO: writeDataToCacheFile::writeDataToCacheFile 712:2014-08-18 18:32:10.510 - ERR : Load of cache file failed. rc=1301 712:2014-08-18 18:32:10.510 - INFO: sendData::sendData 712:2014-08-18 18:32:10.510 - INFO: writeDataToCacheFile::writeDataToCacheFile 711:2014-08-18 18:32:10.511 - INFO: FromDualMySQLagent::checkConnectionToZabbixServer 712:2014-08-18 18:32:10.511 - INFO: FromDualMySQLagent::checkConnectionToZabbixServer 711:2014-08-18 18:32:10.516 - INFO: sendCachedData::sendCachedData 712:2014-08-18 18:32:10.517 - INFO: sendCachedData::sendCachedData 711:2014-08-18 18:32:10.521 - ERR : Load of cache file failed. rc=1301 711:2014-08-18 18:32:10.521 - INFO: Processing module myisam for section mysql2 finished. 712:2014-08-18 18:32:10.521 - ERR : Load of cache file failed. rc=1301 711:2014-08-18 18:32:10.522 - INFO: Processing module innodb for section mysql2 now… 712:2014-08-18 18:32:10.522 - INFO: Processing module myisam for section mysql2 finished. 712:2014-08-18 18:32:10.522 - INFO: Processing module innodb for section mysql2 now… 711:2014-08-18 18:32:10.533 - INFO: FromDualMySQLinnodb::processInnodbInformation Are there any suggestions on how to fix this? this is myql conf:
# All MySQL databases here
# Try to avoid section names with spaces!
[mysql1
]
# This MUST match Hostname in Zabbix! Type = mysqld MysqlHost = 192.168.1.10 MysqlPort = 3306 Modules = mysql myisam innodb master slave PidFile = /tmp/mysqld1.pid
[mysql2
]
# This MUST match Hostname in Zabbix! Type = mysqld MysqlHost = 192.168.1.20 MysqlPort = 3306 Modules = mysql myisam innodb slave PidFile = /tmp/mysqld2.pid
[mysql3
]
# This MUST match Hostname in Zabbix! Type = mysqld MysqlHost = 192.168.1.30 MysqlPort = 3306 Modules = mysql myisam innodb slave PidFile = /tmp/mysqld3.pid Thank you!

gethostbyname

Taxonomy upgrade extras: 

Hello poorx7,

I see, that you are using an old version of mpm: 0.9.2 the current version is 0.9.3 which you can download from here.

Galera Cluster VS PXC VS MariaDB Galera Cluster - Benchmarking

Taxonomy upgrade extras: 

It is not clear for many MySQL users that Percona XtraDB Cluster (PXC) and MariaDB Galera Cluster depend on the same Galera library i.e used in Galera Cluster for MySQL which is provided by Codership team:

FromDual invites MySQL community to company meeting 2014 in Barcelona

Taxonomy upgrade extras: 

FromDual holds its annual company meeting this year in Barcelona, Spain.

try it DEBUG

Taxonomy upgrade extras: 

I use the debug.conf is : [debug] Debug = 4 Type = mysqld Modules = server LogFile = /usr/local/mpm/FromDualMySQLagent.log

removeAgentLock

Taxonomy upgrade extras: 

Hello poorx7,

The got TERM signal means that the process was hanging too long somewhere and the next start of mpm killed this one.

removeAgentLock and how to fix it(Version 0.9.2and0.9.3)

Taxonomy upgrade extras: 

If I chose full Modules for MPM,FromDualMySQLagent.log will post this error

FromDual: Tools for MySQL and Galera - Backup - Monitoring - Operations

FromDual tools provide valuable additional functionality which facilitate and optimize daily operations of your MySQL databases. Since our last newsletter a lot of things have changed in the FromDual tools.

FromDual Performance Monitor for MySQL 0.9.3 has been released

FromDual has the pleasure to announce the release of the new version 0.9.3 of its popular Database Performance Monitor for MySQL, Galera Cluster, MariaDB and Percona Server fpmmm.

RE: EMPTY TRANSACTIONS CAN BE DANGEROUS

Taxonomy upgrade extras: 

If you used the combination of Percona tools (pt-table-checksum and pt-table-sync) - as I mentioned - to get the data synchronized after injecting an empty transaction and starting the slave you won’t face that problem. Otherwise, yes this could be dangerous if that slave promoted to be master AND the other slaves didn’t replicate that transaction yet or when you take a database backup from that slave as well.

Empty transactions can be dangerous

Taxonomy upgrade extras: 

Inserting an empty transaction can be dangerous. Another server might request that transaction from that server and then it gets an empty transaction with the same GTID as the original one. So this is only safe for slaves which will never become a master or if all possible slaves already have processed this gtid.

Replication Troubleshooting - Classic VS GTID

Taxonomy upgrade extras: 

In previous posts, I was talking about how to set up MySQL replication, Classic Replication (based on binary logs information) and Transaction-based Replication (based on GTID). In this article I’ll summarize how to troubleshoot MySQL replication for the most common issues we might face with a simple comparison how can we get them solved in the different replication methods (Classic VS GTID).

MySQL 5.5 and 5.6 ?!

Taxonomy upgrade extras: 

Just to confirm, the above channel failover steps are valid in Galera Cluster for both MySQL versions 5.5 and 5.6. Enjoy!!

Replication channel failover with Galera Cluster for MySQL

Sometimes it could be desirable to replicate from a Galera Cluster to a single MySQL slave or to an other Galera Cluster. Reasons for this measure could be:

When active, FromDUal casuses zabbix agent to bug

Taxonomy upgrade extras: 

I installed FROMDUAL on a mysql server and when i active it causes zabbix agent to switch between unreachable and reachable every 5 minutes. When i disable FROMDUAL it starts to work fine. I also lose data when FROMDUAL is active, CPU data, memory usage, and more. Any clue to solve this? Thank you

Zabbix_agent unreachable after installing FromDual

Taxonomy upgrade extras: 

Hello, i installed FromDual on a MySQL 5.6 and made it work fine sending data. But now every 5 minutes i get the message of the Zabbix_agent unreachable in that server. Agent is working fine and network too. I get this error on Zabbix log: 2916:20140618:125301.324 Zabbix agent item “FromDual.MySQL.check” on host “HOST” failed: first network error, wait for 5 seconds 2931:20140618:125309.359 Zabbix agent item “FromDual.MySQL.check” on host “HOST” failed: another network error, wait for 5 seconds 2931:20140618:125314.491 resuming Zabbix agent checks on host “HOST”: connection restored Anyone can help me solving this? Thank you

MySQL Environment MyEnv 1.0.5 has been released

FromDual has the pleasure to announce the release of the new version 1.0.5 of its popular MySQL, MariaDB and Percona Server multi-instance environment MyEnv.

GTID In Action

Taxonomy upgrade extras: 

In a previous post I was talking about How to Setup MySQL Replication using the classic method (based on binary logs information). In this article I’ll go through the transaction-based replication implementation using GTID in different scenarios.

Deadlock mysql

Taxonomy upgrade extras: 

Furthermore, I noticed more than 700 files created BY ZABBIX in /tmp on only masters. They are named like : DeadlockMessage.tmp.17145 & ForeignKeyMessage.tmp.11416

COMMIT!

Taxonomy upgrade extras: 

Kalasha,

Since autocommit is disabled, did you issue “COMMIT” after inserting those records ? If not, then you have to either enable autocommit or commit your DML statements manually (issue “COMMIT” or execute DDL statement)

MYSQL TOTAL RECORD COUNT ISSUE

Taxonomy upgrade extras: 

HI Team,

The issue is due to autocommit mode is set to off in MySQL and tranasaction level is repeatable read. Due to this we are not able to view the latest record count. It shows only the records committed when i logged in the mysql.

An example

Taxonomy upgrade extras: 

4187:2014-06-03 16:06:51.934 - INFO: FromDual Performance Monitor for MySQL (0.9.3) run started. 4187:2014-06-03 16:06:51.934 - INFO: FromDualMySQLagent::setAgentLock 4187:2014-06-03 16:06:51.934 - INFO: Read configuration from /usr/local/mysql_performance_monitor/etc/FromDualMySQLagent.conf


4187:2014-06-03 16:06:53.350 - ERR : got TERM signal. Cleaning up stuff an exit (rc=1). 4187:2014-06-03 16:06:53.351 - INFO: FromDualMySQLagent::removeAgentLock 4187:2014-06-03 16:06:53.351 - INFO: FromDual Performance Monitor for MySQL run finshed (rc=1).

wrong number of rows

Taxonomy upgrade extras: 

Can you repeat this at the command line? This is such a basic problem that I expect that it has nothing to do with MySQL but with your environment/application/set-up or testing method…

Check interval

Taxonomy upgrade extras: 

An mpm agent run should not be started before the previous has ended. To make this sure we have some internal checks (and a kill). So the interval should be bigger than the duration of a (the longest) run. Typically we run mpm every 10 seconds and that is fine in most of the cases. But our biggest DB is around 250 Gbyte. So I am wondering why your runs take much longer. Should be visible by the timestamps of the log (debug) file where most of the time is spent.

MySQL Total Record count issue

Taxonomy upgrade extras: 

Hi Team, I am using MySQL 5.6 in production server (hosted at AWS). After inserting records online its commited in database, but while executing select count(
*) from table_name i am getting the latest count. After exiting from mysql and again login i am able to view the latest count. Transaction isolation in mysql is repeatable-read (both in global and status variables) Kindly help to fix this issue

Enlarge update interval

Taxonomy upgrade extras: 

Maybe by postponing the interval between two checks, it could be better ? I noticed it’s happening only on huge databases

TERM signal

Taxonomy upgrade extras: 

As mentioned earlier (now with a nicer error message) somebody or something is killing the actual mpm agent job. This is typically a next mpm agent job who has to wait too long for the actual one. The question is more: Why is the first one lasting for so long…

Great !

Taxonomy upgrade extras: 

Hi ! Looks like it’s working for the master module.

bug in master module found and fixed

Taxonomy upgrade extras: 

The following fixes in the file lib/FromDualMySQLmaster.pm should do the job:

Any solution ?

Taxonomy upgrade extras: 

So what’s the fix to apply ? Thanks !

binlog_ignore_filter in master module broken

Taxonomy upgrade extras: 

Thanks, got it:

hostnameX FromDual.MySQL.master.Binlog_ignore_filter 1400661892

Here are the output of this

Taxonomy upgrade extras: 

Here are the output of this command: hostnameX FromDual.MySQL.master.Binlog_position 1400661892 232071 hostnameX FromDual.MySQL.master.Slave_count 1400661892 0 hostnameX FromDual.MySQL.master.Binlog_event_count 1400661892 0 hostnameX FromDual.MySQL.master.Binlog_total_size 1400661892 407016903 hostnameX FromDual.MySQL.master.Binlog_ignore_filter 1400661892 hostnameX FromDual.MySQL.master.Binlog_count 1400661892 8 hostnameX FromDual.MySQL.master.Binlog_do_filter 1400661892 tableX hostnameX FromDual.MySQL.master.Binlog_number 1400661892 682 hostnameX FromDual.MySQL.master.Binlog_avg_event_size 1400661892 0 hostnameX FromDual.MySQL.master.Binlog_file 1400661892 mysql-bin.000682

Cache file broken

Taxonomy upgrade extras: 

I think I see what went wrong. Can you please send me the first 10 lines of the file /tmp/FromDualAgentCache.hostnameX.cache:

MPM Module Master

Taxonomy upgrade extras: 

Hello,

Here is the log when I’m adding the module master. My latest data are at 10:40 on Zabbix UI.

MPM Start

Taxonomy upgrade extras: 

Thanks to a UserParameter I guess:

UserParameter=FromDual.MySQL.check,/usr/local/mysql_performance_monitor/FromDualMySQL agent.pl /usr/local/mysql_performance_monitor/etc/FromDualMySQLagent.conf

exit with rc=1

Taxonomy upgrade extras: 

I see… The only part in the code where exit code 1 can be reached is the signal TERM trap. Either somebody killed the process or mpm killed a long running former mpm process automatically. How do you start mpm agent?

Debug for instability

Taxonomy upgrade extras: 

Hello, This debug is when the MPM stops after some hours of work. I’ll send the debug for the module master after.

Master module ist missing

Taxonomy upgrade extras: 

It looks like you did not enable the master module: INFO: Modules for section hostnameX: mpm server process mysql innodb slave

My debug log

Taxonomy upgrade extras: 

5698:2014-05-15 13:55:33.212 - INFO: FromDual Performance Monitor for MySQL (0.9.2) run started. 5698:2014-05-15 13:55:33.226 - INFO: FromDualMySQLagent::setAgentLock 5698:2014-05-15 13:55:33.227 - INFO: Read configuration from /usr/local/mysql_performance_monitor/etc/FromDualMySQLagent.conf 5698:2014-05-15 13:55:33.227 - INFO: Sections found: default, hostnameX 5698:2014-05-15 13:55:33.227 - INFO: Reading default section 5698:2014-05-15 13:55:33.227 - DBG : ZabbixServer - ipAddrX 5698:2014-05-15 13:55:33.227 - DBG : Modules - process mysql myisam innodb 5698:2014-05-15 13:55:33.227 - DBG : LogFile - /var/log/zabbix/FromDualMySQLagent.log 5698:2014-05-15 13:55:33.227 - DBG : Type - mysqld 5698:2014-05-15 13:55:33.227 - DBG : Password - ************ 5698:2014-05-15 13:55:33.227 - DBG : Disabled - false 5698:2014-05-15 13:55:33.227 - DBG : Username - db_user 5698:2014-05-15 13:55:33.227 - DBG : Debug - 4 5698:2014-05-15 13:55:33.227 - DBG : TimeShift - 0 5698:2014-05-15 13:55:33.227 - DBG : Socket - /var/lib/mysql/mysql.sock 5698:2014-05-15 13:55:33.227 - DBG : CacheFileBase - /tmp/FromDualAgentCache 5698:2014-05-15 13:55:33.227 - DBG : AgentLockFile - /tmp/FromDualMySQLagent.lock 5698:2014-05-15 13:55:33.227 - DBG : MysqlPort - 3306 5698:2014-05-15 13:55:33.228 - DBG : Hash - 5698:2014-05-15 13:55:33.228 - DBG : ZabbixServerPort - 10051 5698:2014-05-15 13:55:33.228 - DBG : Methode - https 5698:2014-05-15 13:55:33.228 - DBG : ClusterLog - /var/lib/mysql-cluster/ndb_1_cluster.log 5698:2014-05-15 13:55:33.228 - DBG : MaaS - off 5698:2014-05-15 13:55:33.228 - DBG : PidFile - 5698:2014-05-15 13:55:33.228 - DBG : Url - https://support.fromdual.com/maas/receiver.php 5698:2014-05-15 13:55:33.233 - DBG : MysqlHost - 127.0.0.1 5698:2014-05-15 13:55:33.233 - INFO: Processing section default now 5698:2014-05-15 13:55:33.233 - INFO: Processing section hostnameX now 5698:2014-05-15 13:55:33.234 - DBG : The defaults parameters of this configuration file are: 5698:2014-05-15 13:55:33.234 - DBG : ZabbixServer - ipAddrX 5698:2014-05-15 13:55:33.234 - DBG : Modules - process mysql myisam innodb 5698:2014-05-15 13:55:33.234 - DBG : LogFile - /var/log/zabbix/FromDualMySQLagent.log 5698:2014-05-15 13:55:33.234 - DBG : Type - mysqld 5698:2014-05-15 13:55:33.234 - DBG : Password - ************ 5698:2014-05-15 13:55:33.234 - DBG : Disabled - false 5698:2014-05-15 13:55:33.234 - DBG : Username - db_user 5698:2014-05-15 13:55:33.234 - DBG : Debug - 4 5698:2014-05-15 13:55:33.234 - DBG : TimeShift - 0 5698:2014-05-15 13:55:33.234 - DBG : Socket - /var/lib/mysql/mysql.sock 5698:2014-05-15 13:55:33.234 - DBG : MysqlPort - 3306 5698:2014-05-15 13:55:33.234 - DBG : AgentLockFile - /tmp/FromDualMySQLagent.lock 5698:2014-05-15 13:55:33.234 - DBG : CacheFileBase - /tmp/FromDualAgentCache 5698:2014-05-15 13:55:33.235 - DBG : Hash - 5698:2014-05-15 13:55:33.235 - DBG : ZabbixServerPort - 10051 5698:2014-05-15 13:55:33.235 - DBG : Methode - https 5698:2014-05-15 13:55:33.235 - DBG : ClusterLog - /var/lib/mysql-cluster/ndb_1_cluster.log 5698:2014-05-15 13:55:33.235 - DBG : MaaS - off 5698:2014-05-15 13:55:33.235 - DBG : PidFile - 5698:2014-05-15 13:55:33.235 - DBG : Url - https://support.fromdual.com/maas/receiver.php 5698:2014-05-15 13:55:33.235 - DBG : MysqlHost - 127.0.0.1 5698:2014-05-15 13:55:33.235 - DBG : The parameters of section hostnameX are: 5698:2014-05-15 13:55:33.235 - DBG : MysqlPort - 3306 5698:2014-05-15 13:55:33.235 - DBG : Type - mysqld 5698:2014-05-15 13:55:33.235 - DBG : Modules - mpm server process mysql innodb slave 5698:2014-05-15 13:55:33.235 - DBG : The combined (default + section) parameters for section hostnameX are: 5698:2014-05-15 13:55:33.235 - DBG : ZabbixServer - ipAddrX 5698:2014-05-15 13:55:33.236 - DBG : Modules - mpm server process mysql innodb slave 5698:2014-05-15 13:55:33.236 - DBG : LogFile - /var/log/zabbix/FromDualMySQLagent.log 5698:2014-05-15 13:55:33.236 - DBG : Type - mysqld 5698:2014-05-15 13:55:33.236 - DBG : Password - ************ 5698:2014-05-15 13:55:33.236 - DBG : Disabled - false 5698:2014-05-15 13:55:33.236 - DBG : Username - db_user 5698:2014-05-15 13:55:33.236 - DBG : Debug - 4 5698:2014-05-15 13:55:33.236 - DBG : TimeShift - 0 5698:2014-05-15 13:55:33.236 - DBG : Socket - /var/lib/mysql/mysql.sock 5698:2014-05-15 13:55:33.236 - DBG : CacheFile - /tmp/FromDualAgentCache.hostnameX.cache 5698:2014-05-15 13:55:33.236 - DBG : MysqlPort - 3306 5698:2014-05-15 13:55:33.236 - DBG : AgentLockFile - /tmp/FromDualMySQLagent.lock 5698:2014-05-15 13:55:33.236 - DBG : CacheFileBase - /tmp/FromDualAgentCache 5698:2014-05-15 13:55:33.236 - DBG : Hostname - hostnameX 5698:2014-05-15 13:55:33.236 - DBG : Hash - 5698:2014-05-15 13:55:33.236 - DBG : ZabbixServerPort - 10051 5698:2014-05-15 13:55:33.236 - DBG : Methode - https 5698:2014-05-15 13:55:33.237 - DBG : ClusterLog - /var/lib/mysql-cluster/ndb_1_cluster.log 5698:2014-05-15 13:55:33.237 - DBG : MaaS - off 5698:2014-05-15 13:55:33.237 - DBG : PidFile - 5698:2014-05-15 13:55:33.237 - DBG : Url - https://support.fromdual.com/maas/receiver.php 5698:2014-05-15 13:55:33.237 - DBG : MysqlHost - 127.0.0.1 5698:2014-05-15 13:55:33.237 - INFO: Modules for section hostnameX: mpm server process mysql innodb slave 5698:2014-05-15 13:55:33.237 - INFO: Processing module mpm for section hostnameX now… 5698:2014-05-15 13:55:33.324 - INFO: FromDualMySQLmpm::processMpmInformation 5698:2014-05-15 13:55:33.325 - INFO: sendData::sendData 5698:2014-05-15 13:55:33.325 - INFO: writeDataToCacheFile::writeDataToCacheFile 5698:2014-05-15 13:55:33.325 - DBG : hostnameX FromDual.MySQL.mpm.mpm_version 1400154933 0.9.2 5698:2014-05-15 13:55:33.325 - DBG : hostnameX FromDual.MySQL.mpm.mpm_mr_version 1400154933 000902 5698:2014-05-15 13:55:33.325 - INFO: FromDualMySQLagent::checkConnectionToZabbixServer 5698:2014-05-15 13:55:33.325 - DBG : Check connection to zabbix server. 5698:2014-05-15 13:55:33.326 - DBG : /usr/local/zabbix/bin/zabbix_sender –zabbix-server ipAddrX –port 10051 –host ‘hostnameX’ –key FromDual.server.check –value ‘1’ -vv zabbix_sender [5701]: DEBUG: answer [{ “response”:“success”, “info”:“processed: 0; failed: 1; total: 1; seconds spent: 0.000025”}] info from server: “processed: 0; failed: 1; total: 1; seconds spent: 0.000025” sent: 1; skipped: 0; total: 1 5698:2014-05-15 13:55:33.345 - DBG : (ret=512). 5698:2014-05-15 13:55:33.345 - DBG : Partial success (ret=512 / rc=0).

mpm Module Master

Taxonomy upgrade extras: 

Hello Obyis

Hmm... In the master module nothing has changed since v0.9.1 if I searched correctly...
It looks like the problem is located in sending the cache file.
Can you please enabled Debug = 4 and send us the output when the error happens?

MPM Unstable

Taxonomy upgrade extras: 

Hello, I don’t know if you received my previous post => Module Master stucks the MPM.

Bug Module Master ?

Taxonomy upgrade extras: 

Hello, Thanks, it works well with thoses fixes.

Unfortunately, I discovered that the error : “ERR : Load of cache file failed. rc=1301” is coming with the module “Master”. When I remove it, there are no more errors. So the MPM is stucked because of the module Master. For the moment, it’s running without that module.

See bug and fix

Taxonomy upgrade extras: 

We found a pretty uncomfortable bug. It can be fixed easily by yourself or wait for the release of version 0.9.3 coming out soon. For more information see: here.

Bug in v0.9.2

Taxonomy upgrade extras: 

This seems to be a bug in v0.9.2 which happens when you have deadlock error messages in SHOW ENGINE INNODB STATUS output. (bug #139).

Loading "Digest::SHA1" instead

Taxonomy upgrade extras: 

Obyis,

Try to load “Digest::SHA1” instead of “Digest::SHA” at the beginning of “InnoDbStatus.pm” file by replacing “use Digest::SHA” with “use Digest::SHA1”. It should work after that.

Cache errors ?

Taxonomy upgrade extras: 

Hello,

I still have the same error in the log even after installed libdigest-sha-perl “15116:2014-05-07 10:20:38.922 - ERR : Can’t locate object method “new” via package “Digest::SHA1” (perhaps you forgot to load “Digest::SHA1”?) at /usr/local/mysql_performance_monitor/lib/InnoDbStatus.pm line 54.”

Ubuntu intallation advice

Taxonomy upgrade extras: 

Hello

oh, I see. The installation advice for Ubuntu/Debian has a bug. libdigest-sha1-perl does not exits (any more?). I fixed the installation docu.

Missing packages ?

Taxonomy upgrade extras: 

Hi, Here is an error I got : 28991:2014-05-06 15:24:38.940 - ERR : Can’t locate object method “new” via package “Digest::SHA1” (perhaps you forgot to load “Digest::SHA1”?) at /usr/local/mysql_performance_monitor/lib/InnoDbStatus.pm line 54.

FromDual Performance Monitor for MySQL 0.9.2 has been released

FromDual has the pleasure to announce the release of the new version 0.9.2 of its popular Database Performance Monitor for MySQL, MariaDB and Percona Server mpm.

MySQL Performance Monitor upgrade to v0.9.2

Taxonomy upgrade extras: 

I’m going to deploy the new version of MPM on all my servers and i was wondering if there was a way to automatically delete or reload the cache file FromDualAgentCache.hostname.cache when we upgrade to the new version?

mpm cache file

Taxonomy upgrade extras: 

The mpm cache file is automatically loaded from the mpm agent to the Zabbix service at every run. After the load it is automatically shrinked/deleted again. So there is no need to reload or delete this file.>/p>

In some rare case (with older releases) mpm got a hick-up with too big cache files and then it makes sense to completely delete them.

MySQL Environment MyEnv 1.0.4 has been released

FromDual has the pleasure to announce the release of the new version 1.0.4 of its popular MySQL, MariaDB and Percona Server multi-instance environment MyEnv.

MySQL Environment MyEnv 1.0.3 has been released

FromDual has the pleasure to announce the release of the new version 1.0.3 of its popular MySQL, MariaDB and Percona Server multi-instance environment MyEnv.

How to Setup MySQL Master/Slave Replication ?

Taxonomy upgrade extras: 

It’s not usual to find an easy source on how to setup MySQL replication, I thought it might be useful at least for the beginners to write a direct and simple howto blog on setting up Master/Slave replication in MySQL using the classic method (binary log information). Check out my post GTID In Action for information about transaction-based replication using GTID.

Setting the right GCache size in Galera Cluster

Taxonomy upgrade extras: 

One of our customers had a question related to the right value of Galera Cache size (gcache.size) in Galera Cluster for MySQL which I would like to share with you.

Does login log will do super user attempts?

Taxonomy upgrade extras: 

Hi,

I have completed your audit_connect for logon but its not working for super users,any idea to log super user attempts in this process?

Impact of General Query Log on MySQL Performance

Taxonomy upgrade extras: 

Sometimes, it is required to enable the General Query Log (which is disabled by default). If the General Query Log is enabled the server writes to this log information when clients connect or disconnect, and each SQL statement received from the client.

log_output = NONE

Taxonomy upgrade extras: 

OK. Try to set log_ouput to table with:

SET GLOBAL log_output = 'table';

Sir,

Taxonomy upgrade extras: 

Sir,

Log_output is showing none

General Query Log & Slow query log is not working

Taxonomy upgrade extras: 

I have enabled the General Query Log and the Slow Query Log in MySQL 5.6.13 in windows server. File is created but sql statement are not capturing. This is production server now its not possible to restart.

What is the log output?

Taxonomy upgrade extras: 

Are you using FILE or TABLE as log output ?
Try “show global variables like’log_output’;”

Hi,

Taxonomy upgrade extras: 

Hi,

I executed flush logs command even though queries are not capturing.

FLUSH LOGS!

Taxonomy upgrade extras: 

Kalasha,
You might need to execute the SQL statement (FLUSH LOGS;) and then check the log files.

Advantage of pt-online-schema-change

Taxonomy upgrade extras: 

Hi Przemek,

I do agree with you that the replication will be blocked until the slaves finish executing the alter statement, but the table being changed on the slaves themselves wont be blocked during the alter statement the same like the master. I agree also that this could be considered as an advantage of pt-online-schema-change over Online DDL. I’ll add that to the blog. Thanks Przemek for the hint …

With online DDL an ALTER

Taxonomy upgrade extras: 

With online DDL an ALTER statement is just a single statement being replicated by single SQL thread, so if a non-blocking ALTER takes 1h on master, then the slave(s) will be applying the same ALTER for another 1h, and replication will be blocked during that time. While pt-osc tool does altering a table by copying rows in chunks, and does monitor the slaves in the same time and pauses the process if necessary. Btw. some additional info here: http://www.mysqlperformanceblog.com/2013/07/05/schema-changes-whats-new-in-mysql-5-6/

Why FromDual customers are using Galera Cluster for MySQL

Taxonomy upgrade extras: 

We are very satisfied with the functionality and the launch. The entire Cluster is running absolutely stable. This is a significant advantage for our customers because we are able to offer our services without interruption. We will use Galera in further projects and convert our existing Master/Slave installations.

Replication in Online DDL

Taxonomy upgrade extras: 

Hi Shlomi

Can you please explain more on how did you produce your results?
Because Online DDL are DDL statements anyway and will be written to the binary log as statements (even if RBR is being used) which means that it will be executed on the slave the same like it was on the master.

Replication

Taxonomy upgrade extras: 

Hi, One additional major difference is in how the oline alter table propagates through replication. With online DDL, it just serializes like any other statement in binary log. To the best of my understanding it makes for a blocking statement on slave. Which means this is all fine all master, but then you will have to forget about your slaves for a couple days… A solution for that would be to issue independently with SQL_LOG_BIN=0 on all hosts.

Online DDL vs pt-online-schema-change

Taxonomy upgrade extras: 

One of the most expensive database operations is performing Data Definition Language (DDL, e.g. CREATE, DROP, ALTER, etc.) statements, specially, the ALTER statements because MySQL blocks the entire table for both reads and writes while modifying the table.

Great!!!

Taxonomy upgrade extras: 

Thanks for the information, it has been very useful to me, best regards of cimaware.com

What are the costs of one hour MySQL downtime?

Taxonomy upgrade extras: 

Hello,

there are companies which earn tens of thousands of Euros per hour with their MySQL databases. Other companies operate their ERP system on MySQL, to which 1000 employees are attached to. Is the database down 1000 people are not working any more until the system is working again! Downtime costs starting at EUR 30'000.- per hour upwards.

System restart vs query start

Taxonomy upgrade extras: 

From throughput point of view I agree. What about from response time point of view? We fire a query once and never again (the same).

Majority of MySQL users has no performance problem!

Taxonomy upgrade extras: 

Hello Øystein,

Unfortunately I have to agree! MySQL is damn fast/cool and hardware nowadays as well. And having much RAM and fast multi-core CPU's sucks from a tuner point of view ;-)

Measurements

Taxonomy upgrade extras: 

In a production system, I think what matters is the steady-state performance of the system, not what happens just after system restart.

Performance problems

Taxonomy upgrade extras: 

95% of all statistics is made up …

If you consider all users of MySQL including those using it to store their record collection, I would think that more than 95% does not have any performance problem.

throughput vs single query performance

Taxonomy upgrade extras: 

Hi Massimo,

From my last 14 years experience as DBA and DB consultant (Oracle, MySQL, MS-SQL Server, PostgreSQL). I have seen several hundreds? different DB performance problems in these years and only few of them (1 upon 20? or even less) where real throughput problems.
Most of them where single query performance problems (including optimizer/optimizing and configuration problems).

ot theses statisticians...

Taxonomy upgrade extras: 

Hello Øystein,

The high/bad standard deviation with MySQL 5.6 comes from some very high outlier in the beginning of the test. I did not delete this outlier because I have seen this as an unfair treatment to the other releases which did not show this phenomena.

95%?

Taxonomy upgrade extras: 

you wrote: " But most of the MySQL users (95%) do not have a troughput problem but a single query performance problem (I assume here that this is true also for Oracle, MS-SQL Server, DB2, PostgreSQL, etc.)."

Confidence

Taxonomy upgrade extras: 

Hi,

With the given standard deviation for the MySQL 5.6.15 run, the 95% confidence interval for the average is between 5.85 and 8.59, if my rusty statistics knowledge serves me right. Hence, the difference between 5.6 and 5.7 is not statiscally significant.

Love is all around...

Taxonomy upgrade extras: 

Thanks, Morgan!

Validate things

Taxonomy upgrade extras: 

Hello Stephane,

Sorry, I cannot completely follow you what you want me to do. But please feel free to reproduce. All needed information are available I think!

Do not trust benchmarks

Taxonomy upgrade extras: 

Good post.

You are raising a real topic here.

This Query is just in memory full table scan with thread state transition to make a join.

MySQL single query performance - the truth!

MySQL single query performance - the truth!

As suggested by morgo I did a little test for the same query and the same data-set mentioned in Impact of column types on MySQL JOIN performance but looking into an other dimension: the time (aka MySQL versions).

Love it!

Taxonomy upgrade extras: 

Thanks for running the test.

InnoDB 4 byte alignment

Taxonomy upgrade extras: 

Hi Joffrey,

The easy answer first: 5 - 15 iterations until it got a stable response time and then I took the most optimistic value. Not very scientific, I know... But I think good enough for a reliable statement.

NDB Alignment

Taxonomy upgrade extras: 

Hi Joffrey,

I think NDB tables use 4-byte alignment not InnoDB:

MediumInt same size as INT ?

Taxonomy upgrade extras: 

Hi Oli,

thanks for the nice comparison chart ! In InnoDB, isn’t (Tiny|Small|Medium)-int internally aligned to 4 bytes, and thus stored as 4bytes int ? How many iterations did you run the query ?

MySQL slower over time?

Taxonomy upgrade extras: 

Hi Morgan,

Thanks!

I have planed such a test already a while ago but did not find the time to do it yet...

Impact of column types on MySQL JOIN performance

Taxonomy upgrade extras: 

In our MySQL trainings and consulting engagements we tell our customers always to use the smallest possible data type to get better query performance. Especially for the JOIN columns. This advice is supported as well by the MySQL documentation in the chapter Optimizing Data Types:

5.5 vs 5.6 single threaded performance

Taxonomy upgrade extras: 

Hi! It’s an interesting (and well designed) test case.

In single threaded workloads 5.6 can be a little slower than 5.5, so it may have advantaged TokuDB just a little bit.

MySQL Environment MyEnv 1.0.2 has been released

FromDual has the pleasure to announce the release of the new version 1.0.2 of its popular multi-instance MySQL Environment MyEnv.

Galera Cluster for MySQL

Taxonomy upgrade extras: 

Features

Galera is a synchronous multi-master replication Cluster for MySQL/InnoDB databases, having features like:

MyEnv License

Taxonomy upgrade extras: 

Hello Jon,

Great you are happy with MyEnv!

A little Information: We plan to release MyEnv 1.0.2 soon (this week?).

License for MyEnv

Taxonomy upgrade extras: 

Hi there! I am working on a project where I will most likely be using MyEnv (oh how I wish I had known of this the last time I set up mysqld_multi). I have added one feature already and have a few bug and performance fixes as well. My questions: Is there a license for MyEnv? If no, can you include one? Also, would you like me to pass my changes upstream? If so, how would be the best way. Mantis? Related to the licensing questions, would it be acceptable for redistribution with my changes? (eg. a public GitHub repository). Thanks for writing MyEnv, it’s going to make this project far more polished without having to use mysqld_multi again.

Check and fix MySQL Replication inconsistencies

Taxonomy upgrade extras: 

There are many different possibilities how you can achieve inconsistencies between Master and Slave in a MySQL replication, intentional and non-intentional ones. How to achieve them is not the topic of this article.

Shrink InnoDB (System-)Tablespace

Taxonomy upgrade extras: 

Hello csmanioto,

As mentioned above this is a PoC and should never be used on system with critical data because it is an evil hack!!!

POC Problem

Taxonomy upgrade extras: 

Hi,

Don’t work for me :(

file ibdata1 = 144539648 bytes (8822 pages)… checking pages in range 0 to 8821 page 0: log sequence number: first = 579975309; second = 579975309 page 0: old style: calculated = 1043303352; recorded = 1043303352 page 0: new style: calculated = 2013654343; recorded = 3190797841 page 0 invalid (fails new style checksum)

Message 9704:2013-11-18 17:03

Taxonomy upgrade extras: 

Message 9704:2013-11-18 17:03:53.377 - WARN: Connection to zabbix server failed (rc=1305)! appears because of a bug in lib/FromDualMySQLagent.pm in function checkConnectionToZabbixServer.

Workbench starting/stopping multiple instance set-ups with myenv

Taxonomy upgrade extras: 

Table of Contents

Introduction

MySQL Workbench is a very good and free GUI tool provided by Oracle to manage MySQL administration and development tasks. Opening many MySQL connections (same or different instances, remote or local MySQL servers) at the same time is one of its main features. While it’s working fine to perform SQL statements on the different connections opened for multiple instances, but some people are asking if it is available as well to start and stop multiple MySQL instances using MySQL Workbench? if yes, how to configure it to perform such task? and also does that make any conflict with MyEnv tool - if it’s installed - or not? Yes, MySQL Workbench could be configured to start and stop multiple MySQL instances (local or remote) and it does not make any conflict with MyEnv tool.

Figured it out. Currently,

Taxonomy upgrade extras: 

Figured it out. Currently, FPMMM is sending the data as such:

Galera 3.1 is now Released

Taxonomy upgrade extras: 

I just want to mention here that Galera 3.1 GA is now released but the online upgrade from MySQL 5.5 to 5.6 has some problems and a workaround should be made (Bug #1251137) to get this process done.

HI

Taxonomy upgrade extras: 

Thank you very much.

One more time. Some debugging

Taxonomy upgrade extras: 

One more time. Some debugging, and I’ve identified a possible source of the issue: checkConnectionToZabbixServer in sendData.pm

Hi,

Taxonomy upgrade extras: 

Hi,

The output you just provided could be gotten by having your database’s tables backed up individually and then restore them the same way.
For this purpose, the backup script should be something like:

Yes, it works in previous

Taxonomy upgrade extras: 

Yes, it works in previous version of 1.8.x. I’m trying to migrate to 2.2 because of the VMware monitoring, but I can’t do that until I get the FromDual configuration working on it.

Error 1305

Taxonomy upgrade extras: 

Has this ever worked before (with < 2.2)?

Error 1305 means, that the agent cannot connect to the zabbix server. We verify: ZabbixServer, ZabbixPort and Hostname

Monitering load database in mysql

Taxonomy upgrade extras: 

HI,

I want to monitor database refresh,when loading database into mysql I want see the below output,so that I can see if any error occurs.

Thank you! I was able to get

Taxonomy upgrade extras: 

Thank you! I was able to get past that issue, but now, I have a new one:

FromDual.MySQL.check became not supported

Taxonomy upgrade extras: 

It looks for me like check delivers an empty string and expects an int or decimal. One has to check what check delivers exactly and why. Debugging in the fpmmm agent should help on this…

Not with 2.2

Taxonomy upgrade extras: 

When I run, I see the following:

30381:20131115:122820.012 item [HOSTNAME:FromDual.MySQL.check] became not supported: Received value [] is not suitable for value type [Numeric (unsigned)] and data type [Decimal]

what exactly to be monitored ?

Taxonomy upgrade extras: 

Hi Srihari,

What exactly you want to monitor in MySQL ?

Monitering load database in mysql

Taxonomy upgrade extras: 

HI, Is there any scripts to moniter load database in mysql,I am trying to moniter with –verbose option in mysql client. but the output giving me all the insert commands. Please help me on this. Thanks Srihari

Galera Cluster 3.1 GA is out!

Taxonomy upgrade extras: 

Great News: Galera Cluster v3.1 GA for MySQL 5.6 was released at Percona Live London (PLUK) 2013. The information is still a bit hidden…

Xtrabackup in a nutshell

Taxonomy upgrade extras: 

Table of Contents

Introduction

No one can deny that one of the most important and daily tasks for DBAs is performing backup and restore operations, we’re not required to perform backup and restore operations only when we want to add new replication slave, when we want to implement disaster recovery procedures or when we want to prepare testing or staging server for the running production system, but even if we’re going to make any changes to the database schema in order to enhance the database performance, it’s recommended to have fresh backup copy before making any live changes, so if backup and restore operations cannot be handled smoothly, we’re going to face many troubles in our daily work. If we’re going to talk about backup and restore operations, Xtrabackup tool will be strongly appeared.

MySQL Environment MyEnv 1.0.1 has been released

FromDual has the pleasure to announce the release of the new version 1.0.1 of its popular multi-instance MySQL Environment MyEnv.

No such way available

Taxonomy upgrade extras: 

I don’t think that there’s such way in MySQL like MSSQL to track users modifications, but you can check the general log file (if it’s enabled) and search for all DCL statements related to the user in question. In the general log file, MySQL records all commands received by the client along with the issuance timestamp. I hope that helps..

user password change date

Taxonomy upgrade extras: 

Dear friends, Is there is any command to check when user and password created in MySQL user table. I want command for user logins last password change date and password created date. in MSSQL we are able to take where as in MySQL unable to take. Kindly help me

Querying the GLB, draining, removing and adding nodes in CentOS

Taxonomy upgrade extras: 

Thanks Oli for the very helpful post, it really helped me to understand how to use and operate GLB, but I'd like to mention here that the option "-q" works only in Ubuntu, but in CentOS, it should be replaced by "-s" to be used as follows:

Upgrade from Galera Cluster 2.x to 3.0

Taxonomy upgrade extras: 

Table of Contents

Introduction

Codership announced from weeks ago introducing the Galera Cluster new release 3.0 having many bug fixes, performance enhancements plus the main purpose which is working with MySQL 5.6. In this article, I’ll go through the upgrade steps from Galera 2.x to the new release 3.0, but at the time of writing this article - as mentioned in the Codership release notes - THIS IS A BETA QUALITY RELEASE FOR TESTING PURPOSES. NOT RECOMMENDED FOR PRODUCTION YET.

Murphy’s Law is also valid for Galera Cluster for MySQL

Taxonomy upgrade extras: 

We had a Galera Cluster support case recently. The customer was drenched in tears because his Galera Cluster did not work any more and he could not make it work any more.

MySQL Environment MyEnv 1.0 has been released

Taxonomy upgrade extras: 

FromDual has the pleasure to announce the release of the new version 1.0 of its popular multi-instance MySQL Environment MyEnv.

MySQL community is invited to join FromDuals company meeting

Taxonomy upgrade extras: 

FromDual holds its annual company meeting this year in Leoforos Vravronos near Athens (20 km outside) in Greece.

#ports and FIN_TIMEOUT

Taxonomy upgrade extras: 

Hello thatsafunnynamecomment,

Thanks for reading and correcting my findings! You are absolutely right. I did a bit short-cut too much in maths!

Thank you for the article.

Taxonomy upgrade extras: 

Thank you for the article. Sorry to nitpick. My colleague pointed out if the local port range is 32768 – 61000, that there are 28233 available ports, not 28232.

Huge amount of TIME_WAIT connections

Taxonomy upgrade extras: 

In MySQL we have the typical behaviour that we open and close connections very often and rapidly. So we have very short-living connections to the server. This can lead in extreme cases to the situation that the maximum number of TCP ports are exhausted.

Intelligent load balancer check

Taxonomy upgrade extras: 

I’ve setup an F5 to actually do a select and check wsrep_ready. F5 BigIP has an builtin mysql client. For more details see this article on f5 devcentral.

insert firewall rule instead of appen

Taxonomy upgrade extras: 
[07:51:52] shyperson: I would suggest to --insert the rule instead of --apendING
[07:52:15] shyperson: Just to make sure there are no other rules allowing mysqlport before

Quick upstart script

Taxonomy upgrade extras: 

I actually made a little upstart script (Ubuntu) - works well under Ubuntu 13.04 (rating) w/ percona xtradb cluster packages 5.5.31-23.7.5-438.raring

Galera Load Balancer Documentation

Taxonomy upgrade extras: 

About

glbd is a simple TCP connection balancer made with scalability and performance in mind. It was inspired by pen, but unlike pen its functionality is limited only to balancing generic TCP connections.

Galera Arbitrator (garbd)

Taxonomy upgrade extras: 

It took me quite a while to find out how the beast Galera Arbitrator (garbd) works. To safe your time here a short summary:

Skript too restrictive

Taxonomy upgrade extras: 

Hello Shinguz,

Pay attention: Your script is a bit too restrictive. It will IMHO also close the port for the SST when you use the wsrep_sst_methode = mysqldump. Possibly you should restrict it to the Load Balancer IP or allow access at least from the possible donors.

Galera Cluster for MySQL and hardware load balancer

Taxonomy upgrade extras: 

Our bigger customers where we help to deploy Galera Cluster for MySQL set-ups have some commercial hardware (e.g. F5 or Cisco) for load balancing instead of software load balancers.

DROP vs REJECT

Taxonomy upgrade extras: 

I was recently told that it would be better to use REJECT than DROP:

To UNION or not to UNION...

Taxonomy upgrade extras: 

Recently a forum question
[ 1
] got my attention:

timestamp is not allowed any more as partition key

Taxonomy upgrade extras: 

Since MySQL 5.1.43 timestamp is not allowed as partition key any more [ 1 ]. Thus we can do it as follows:

MariaDB and MySQL PERFORMANCE_SCHEMA Hints

Unbreakable MySQL Cluster with Galera and glb

Taxonomy upgrade extras: 

We did a similar thing this week with Galera Cluster for MySQL and the Galera Load Balancer (glb).

information_schema helps you to find databases

Taxonomy upgrade extras: 

Hi Fabio,

There are several ways to do this. The most simple one but possibly not what you need is:

Monitor a specific database

Taxonomy upgrade extras: 

I want to monitor a specific mysql database.

This is the output of “show databases” command:

MySQL and Secure Linux (SELinux)

Taxonomy upgrade extras: 

Maybe you experienced some strange behaviour with MySQL: Everything is installed correctly and should work. But it does not.

Virtualization gotchas

Taxonomy upgrade extras: 

VirtualBox

Network Interface does not start on Guest System:

MAC Address must be all the same in:

Unbreakable MySQL Cluster with Galera and Linux Virtual Server (LVS)

Recently we had to set-up a 3-node Galera Cluster with a Load Balancer in front of it. Because Galera Cluster nodes (mysqld) still reply to TCP requests on port 3306 when they are expelled from the Cluster it is not sufficient to just leave it to the Load Balancer to check the port if a Galera node is properly running or not.

We need you: MySQL DBA for FromDual Support line

Taxonomy upgrade extras: 

FromDual is looking for professional, enthusiastic and experienced people who:

Some type of configuration issue

Taxonomy upgrade extras: 

I have installed your MPM for Zabbix, but I am not getting any data into Zabbix. I have followed the troubleshooting steps at http://www.fromdual.com/mpm-installation-guide, and added some extra checks. I even set this up on a test server first (and had this working) On the Zabbix server, Status is Monitored for Host, Availability is in the green, templates at Template_FromDual.MySQL.mpm, Template_FromDual.MySQL.mysql, Template_FromDual.MySQL.server, Template_FromDual.MySQL.slave Monitoring the agent. $ tail /var/log/zabbix/zabbix_agentd.log 1948:20130325:220353 Requested
[FromDual.MySQL.check
] 1948:20130325:220354 Before 1948:20130325:220354 Run remote command
[/usr/local/mysql_performance_monitor_agent/FromDualMySQLagent.pl /usr/local/mysql_performance_monitor_agent/etc/FromDualMySQLagent.conf
] Result
[1
]
[1
]… 1948:20130325:220354 Sending back
[1
] 1949:20130325:220403 Processing request. QUESTION: Is a result of
[1
] correct or incorrect? $ tail -30 /tmp/FromDualMySQLagent.log 6130:2013-03-25 22:04:53.206 - INFO: FromDual Performance Monitor for MySQL (0.9) run started. 6130:2013-03-25 22:04:53.276 - ERR : Load of cache file failed. rc=1301 6130:2013-03-25 22:04:54.358 - ERR : Load of cache file failed. rc=1301 6130:2013-03-25 22:04:54.435 - ERR : Load of cache file failed. rc=1301 6130:2013-03-25 22:04:54.469 - ERR : Load of cache file failed. rc=1301 6130:2013-03-25 22:04:54.528 - ERR : Load of cache file failed. rc=1301 6130:2013-03-25 22:04:54.613 - ERR : Load of cache file failed. rc=1301 6130:2013-03-25 22:04:54.687 - ERR : Load of cache file failed. rc=1301 6130:2013-03-25 22:04:54.757 - ERR : Load of cache file failed. rc=1301 6130:2013-03-25 22:04:54.826 - ERR : Load of cache file failed. rc=1301 6130:2013-03-25 22:04:54.829 - INFO: FromDual Performance Monitor for MySQL run finshed (rc=0). I am feeling these cache file failed errors are not right, and probably the cause of the problem. Queries are definitely being run on the DB: 130325 21:58:25 491 Connect zabbix@localhost on 491 Query set autocommit=1 491 Query SHOW GLOBAL VARIABLES 491 Query SHOW /
!50000 GLOBAL
/ STATUS 491 Quit However, I had to hack the code to add the socket directly. $ tail /tmp/FromDualMySQLagent.log 2536:2013-03-25 21:47:04.383 - ERR : DBI connect with database=mysql, host=localhost, port=3306 and user=zabbix failed: Can’t connect to local MySQL server through socket ‘/var/lib/mysql/mysql.sock’ (2) 2536:2013-03-25 21:47:04.383 - DBG : Database connection failed (rc=2600). I was forced to add mysql_socket to your .pm to get my connections to work in Perl. I can use the exact same connection string via mysql client and not have any issues needing to specify the socket (i.e. -u -p -h) Other Checks. I can connect from server to agent manually sudo -u zabbix zabbix_get –host=10.176.163.126 –source-address=10.181.225.66 –key=“FromDual.MySQL.check” 1 sudo -u zabbix zabbix_get –host=10.176.163.126 –source-address=10.181.225.66 –key=“FromDual.MySQL.mysql.Com_select” ZBX_NOTSUPPORTED But why, is the second one not supported? Is the key wrong? zabbix_sender –zabbix-server=10.181.225.66 –host=10.176.163.12 –key=FromDual.MySQLmysql.Questions –value=“123” –verbose sent: 1; failed: 0; total: 1 $ zabbix_sender –zabbix-server=10.181.225.66 –host=10.176.163.12 –key=FromDual.MySQL.mysql.Questions –value=“123” –verbose sent: 1; failed: 0; total: 1 Is your example right, are you missing a . in MySQL.mysql (tried both). I am at a loss? Any Help appreciated.

Alternative

Taxonomy upgrade extras: 

Mostly, i use changing max_connection to 1 or ‘skip networking’.

Feature differences between InnoDB FTS and MyISAM FTS

Taxonomy upgrade extras: 

There are some important differences between InnoDB FTS and MyISAM FTS. For example parser plugins won’t be used (but can be configured) (Bug #62004) and some defaults are not the same (InnoDB fulltext search in MySQL 5.6 part 2 at MySQL Performance Blog)

Switching from MySQL/MyISAM to Galera Cluster

Taxonomy upgrade extras: 

Switching from MySQL/MyISAM to Galera Cluster requires that all tables (except those from the mysql, information_schema and performance_schema) are using the InnoDB Storage Engine.

Block MySQL traffic for maintenance windows

Taxonomy upgrade extras: 

From time to time some maintenance work on the MySQL database has to be done. During the maintenance window we do not want to have application traffic on the database.

mpm Agent Lock file

Taxonomy upgrade extras: 

The mpm agent writes a lock file to prevent that several instances are running at the same time and piling up and possibly slow down the system.

Can't remove Lock File

Taxonomy upgrade extras: 

I have gotten the FromDual modules and templates working on 2 of our 3 database servers. The last one, I keep getting the below errors in the FromDual log file: 3387:2013-02-05 12:55:51.296 - INFO: FromDual Performance Monitor for MySQL (0.9) run started. 3387:2013-02-05 12:55:51.297 - INFO: FromDualMySQLagent::setAgentLock 3387:2013-02-05 12:55:51.298 - WARN: Agent Lock file /tmp/FromDualMySQLagent.lock already exists. 3387:2013-02-05 12:55:51.299 - WARN: Another agent with PID 3366 (our PID is 3387) is running. We will abort now. Are there any suggestions on how to fix this? Thank you!

Bootstrapping Galera Cluster the new way

Taxonomy upgrade extras: 

A while ago it was pretty inconvenient to start a complete Galera Cluster from scratch. Rolling restart an such things are already working well but bootstrapping was a pain.

Lock file not being removed

Taxonomy upgrade extras: 

I have gotten the FromDual modules and templates working on 2 of our 3 database servers. The last one, I keep getting the below errors in the FromDual log file:

Shinguz Cheat Sheet

Taxonomy upgrade extras: 

Copy a directory structure from one to an other server:

Advanced MySQL trainings in Zurich

Taxonomy upgrade extras: 

Due to customer requests, we have added two of our advanced MySQL training courses in late April in Zurich, Switzerland. One course will be presented in German, the other in English.

MySQL SIG Event: MySQL Replication and new Features

Taxonomy upgrade extras: 

The MySQL SIG of DOAG invites you to join on February 27 at the Inside Hotel in Munich. Topics of the SIG Event: MySQL Replication and new Features.

MySQL and MariaDB Security

Overview

MySQL Security Products

Security Vulnerabilities Fixed in MariaDB

Oracle Critical Patch Update (CPU) Advisory for MySQL

RedHat/CentOS vulnerabilities by CVE name

Red Hat vulnerabilities by CVE name for MySQL

Privileges of MySQL backup user for mysqldump

Taxonomy upgrade extras: 

Some MySQL customers do not want to use the root user for mysqldump backups. For this user you have to grant the following minimal MySQL privileges:

The I_S.INNODB_BUFFER_PAGE

Taxonomy upgrade extras: 

The I_S.INNODB_BUFFER_PAGE query seems unsafe to me, as it queries the buffer pool and not the tablespace. The innochecksum approach to find unused pages at the end to truncate + header field patching seems to be as OK as it could possibly be given the method.

Shrinking InnoDB system tablespace file ibdata1 PoC

Taxonomy upgrade extras: 

In this weeks MySQL workshop we were discussing, beside other things, about the innodb_file_per_table parameter and its advantages of enabling it. In addition there was a discussion if the InnoDB system tablespace file can be shrinked once it has been grown very large or not. We all know the answer: The InnoDB system tablespace file does never shrink again.

Tricky

Taxonomy upgrade extras: 

It’s a nice but tricky solution.
 

  1. If the procedure is dropped, so are the grants (doesn't happen if you drop the database 'tracking')
  2. If the init_connect fails the user is denied access.
 
It would be nice to let the user know the last login ts. I tried to do this by adding a SELECT at the start of the login_trigger procedure, but this doesn't work.

Last login of MySQL database users

MySQL hosting providers can easily loose the overview over their customers and which user or schema is still in use and which not.

MySQL backup to file, gzip and load in one step

Taxonomy upgrade extras: 

When a MySQL Slave is set-up with mysqldump you have 2 possibilities:

Resize XFS file system for MySQL

Taxonomy upgrade extras: 

Important: Before you start any operation mentioned below do a proper file system backup of your XFS file system you want to resize. If MySQL is running on this mount point do this with a stopped mysqld. Alternatively you can also use mysqldump to do the MySQL backup but test the restore time before continuing to not experience ugly surprises…

MySQL tmpdir on RAM-disk

MySQL temporary tables are created either in memory (as MEMORY tables) or on disk (as MyISAM tables). How many tables went to disk and how many tables went to memory you can find with:

MPM trigger mysql is down not working?

Taxonomy upgrade extras: 

Hi, I have now installed your great zabbix script on our 3 galera nodes. One thing that is strange is that the trigger MySQL is down doesn’t seem to work. Shutting down MySQL on one of the nodes should actually trigger this but there is just nothing… Is there something wrong in my configuration? Best Regards, Oli

Artikel über MySQL im neuen iX

Hallo MySQL Gemeinde,

Im neuen iX (2012-10) hat es zwei nette Artikel über: MySQL HA-Lösungen (S. 116) und MySQL 5.6 (S. 66).

Galera Cluster Nagios Plugin

Taxonomy upgrade extras: 

Based on customer feedback we have decided to add a plugin Galera Cluster for MySQL to our MySQL Nagios/Icinga Plugins.

Re: Modified channel failover steps in recent releases

Taxonomy upgrade extras: 

Hello Frazer,

Thank you very much for your valuable feedback. Good that Oracle is doing something in this direction and make MySQL even easier to use!

Modified channel failover steps in recent releases

Taxonomy upgrade extras: 

Hi Oli,

Good writeup!

We've recently modified the schema of the ndb_binlog_index table to include some extra per-epoch information - specifically the next_file and next_position columns.

Date for next MySQL Cluster trainings scheduled

Taxonomy upgrade extras: 

The dates for the next MySQL Cluster (ndb) trainings with the Linux Hotel are scheduled now: March 11 - 12 2013 and September 23 - 24 2013. You can book your training here.

Run mpm agent less often

Taxonomy upgrade extras: 

Hello Roger,

The item FromDual.MySQL.check (MPM Agent is alive) is triggering the agent. Its interval is by default set to 10 seconds. Try to set the interval to 30 seconds and let us know if it helps…

How to adjust the rate of FPMMM sending data to zabbix server

Taxonomy upgrade extras: 

Hi, I have monitored my MySQL server with FPMMM v0.9 since one month ago, and it work very well. But the FPMMM collecting and sending data 10 seconds per time. I want to adjust the rate from 10s to 30s. But I don’t how to do this on my server. Could you help me please, Thanks a lot in advance.

Galera Cluster discussions at FrOSCon 2012

During and after Henriks great talk about Galera Cluster at the FrOSCon 2012 in St. Augustin we found 2 important things related to Galera Cluster for MySQL:

Deadlocks, indexing and Primary Key's

Recently a customer has shown up with some deadlocks occurring frequently. They were of the following type (I have shortened the output a bit):

PHP cheat sheet

Taxonomy upgrade extras: 

PHP Java bytecode

PHP Compiler

// Call with php -f test.php

error_reporting(E_ALL);

// Class (blueprint) = package => object (instantiated class)
class ParentClass {

  // variable = property

  // encapsulation
  // visible anywhere
  public $public       = 'Public';
  // visible only within the class, and in inherited and parent classes
  protected $protected = 'Protected';
  // visible only within class
  private $private     = 'Private';

  // function = methode
  public function printItem($string) {

    // ParentClass
    print get_class($this) . ': ' . $string . PHP_EOL;
    print $this->public . PHP_EOL;
    print $this->protected . PHP_EOL;
    print $this->private . PHP_EOL;
  }

  const CONST_VALUE = 'PHP is great!';

  public function printPHP() {

    $classname = get_class($this);
    print constant($classname . '::CONST_VALUE') . PHP_EOL;
    print $classname::CONST_VALUE . PHP_EOL;
    print ParentClass::CONST_VALUE . PHP_EOL;
  }
}

class ChildClass extends ParentClass {

  public function printItem($string) {

    // ChildClass
    print get_class($this) . ': ' . $string . PHP_EOL;
    print self::__bla();
  }

  // private functions are names with __
  private function __bla() {
    print 'bla' . PHP_EOL;
  }
}

class Main {

  private static $instance;
  var $bla;

  private static function __init() {
  }
}

class Person {

  var $name;   // public!

  // access modfiers (public = default)
  public $height;
  protected $social_insurance;
  private $pin_number;

  // PHP constructor methode initialise object when instantiated
  function __construct($persons_name) {

    $this->name = $persons_name;
  }

  private function getPinNumber() {

    return $this->pin_number;
  }

  function setName($new_name) {

    $this->name = $new_name;
  }

  function getName() {

    return $this->name;
  }
}

// inherit from Person all public and protected properties and methodes
// Employee is a TYPE of Person
class Employee extends Person {

  function __construct($employee_name) {

    $this->setName($employee_name);
  }

  // Overwrite the setName methode from Person
  function setName($new_name) {
    if ( $new_name != 'Oli' ) {
      $this->name = strtoupper($new_name);
    }
    else {
      Person::setName($new_name);
      // Or alternatively:
      // parent::setName($new_name);
    }
  }
}


$main = new Main();

$parent = new ParentClass();
$child = new ChildClass();

$parent->printItem('baz');
// Output: 'ParentClass: baz'
$parent->printPHP();
// Output: 'PHP is great'

$child->printItem('baz');
// Output: 'ChildClass: baz'
$child->printPHP();
// Output: 'PHP is great'


// interface bar {
// }

// class MyDatabase implements IDatabase {
// }

// abstract class Base {
//     abstract protected function __construct ();
// }

// protected function hello_right () {

// handle/reference to new object person
$p = new Person('Oliver');
print $p->getName() . PHP_EOL;
$p->setName('Oli');
print $p->getName() . PHP_EOL;
// This is a bad behaviour!
print 'Bad hehaviour: ' . $p->name . PHP_EOL;
// This should give an error
// print $p->pin_number . PHP_EOL;


$e = new Employee('Hugo');
print "Employee " . $e->getName() . PHP_EOL;
$e = new Employee('Oli');
print "Employee " . $e->getName() . PHP_EOL;

function inverse($x) {
  if (!$x) {
    throw new Exception('Division by zero.');
  }
  else return 1/$x;
}

try {
  echo inverse(5) . "<br>n";
  echo inverse(0) . "<br>n";
}
catch (Exception $e) {
  echo 'Caught exception: ' .  $e->getMessage() . "<br>n";
}

// Continue execution
echo 'Hello World';
*/

MONyog

Taxonomy upgrade extras: 

Hello Mahesh,

Thanks for the suggestion. I have added MONyog...

MONyog - MySQL Monitor should have been in this list ... IMHO

Taxonomy upgrade extras: 

I think MONyog should have been in this list as it offers MySQL monitoring solution through - 200+ Advisors, Query Analysis, Email Notification etc..

SchoonerSQL

Taxonomy upgrade extras: 

There is a product out in the wild which is called SchoonerSQL
[ 1
] from an American company called Schooner Information Technology
[ 2
]. They claim to have top-performance
[ 3
] and high-availability features with up 99.999% availability
[ 1
].
The technology seems to be based on InnoDB, SSD and some kind of replication with failover mechanism.

Alternative query

Taxonomy upgrade extras: 
SELECT t.table_schema, t.table_name, t.engine
  FROM information_schema.tables AS t
  LEFT JOIN information_schema.key_column_usage AS i ON t.table_schema = i.table_schema AND t.table_name = i.table_name AND i.constraint_name = 'PRIMARY'
 WHERE i.constraint_name IS NULL
   AND t.table_schema NOT IN ('information_schema', 'mysql')
;

DOAG SIG MySQL - Replication: September 4, 2012 in Hamburg

Taxonomy upgrade extras: 

On Tuesday, September 4, 2012 the next DOAG SIG MySQL meeting will take place in Hamburg (Germany) with the topic Replication.

Frankfurter Datenbanktage 2013

Taxonomy upgrade extras: 

FromDual is having a talk at Frankfurter Datenbanktage 2013, March 14/15

InnoDB variables and status explained

Taxonomy upgrade extras: 

InnoDB Buffer Pool

The InnoDB Buffer Pool is the memory area where the InnoDB Storage Engine caches its data and index blocks. Each InnoDB data and index block has a size of Innodb_page_size (16384 byte = 16 kbyte). The InnoDB Buffer Pool is configured in bytes with the innodb_buffer_pool_size variable. On a dedicated system the InnoDB Buffer Pool can be configured up to 80% of the systems physical RAM (free).

Bug report was opened

Taxonomy upgrade extras: 

A bug report for the following problem has been opened: http://support.fromdual.com/bugs/view.php?id=40

Does fpmmm work with Zabbix 2.0?

Taxonomy upgrade extras: 

A customer asked:

I would like to know if the FromDual Performance Monitor for MySQL works with Zabbix 2.0?

MPM and Percona Server

Taxonomy upgrade extras: 

Hi John,

MPM can work with any MySQL branch/fork. Some of the branches try to make their product unique by adding features or changing things. Because we are parsing the output of SHOW ENGINE INNODB STATUS amongst other things some values can become wrong over time when the output format is changed by the vendors.

Can FPMMM work with Percona mysql ?

hi guys, I have install latest mpm for monitoring a Percona mysql server 5.5

GLB init script

Taxonomy upgrade extras: 

Daniel the Hazard wrote us:

just wanted to leave this complement to your GLB post: a init script for GLB that supports adding and removing targets

Change MyISAM tables to InnoDB and handle SELECT COUNT(*) situation

Its a known problem that changing the Storage Engine from MyISAM to InnoDB can cause some problems
[ 1
] if you have queries of this type:

concurrency

Taxonomy upgrade extras: 

I guess your feed system writes into the table in a serial fashion? Any concurrency is going to kill this method. The summary table will have very few rows, which will create very hot locks when the base table is modified. Deadlocks and lock wait timeout errors are likely.

Binary log file and binary log position

Taxonomy upgrade extras: 

Hi Geoff,

The mysqldump was done with –master-data(=1) which explicitly set’s binary log file and binary log position.

Replication to galera cluster

Taxonomy upgrade extras: 

You don’t mention the binary log and the position in this post. Will this work as expected (ie regular mysql)?

MySQL @ FrOSCon 7 in St. Augustin (Germany)

Taxonomy upgrade extras: 

Also this year we will have a special track for MySQL, Galera, Percona und MariaDB at the FrOSCon in St. Augustin in Germany. The conference is scheduled for August 25 and 26 2012.

Using screen for support and/or surveillance

Taxonomy upgrade extras: 

See also Byobu.

Often support customers want to see what you do on their databases. For this screen is the ideal tool.

CentOS 6 and bonding

Taxonomy upgrade extras: 

Some updates if you want to use bonding on CentOS 6:

FromDual Newsletter Spring 2012

Dear MySQL User,

With this newsletter we bring you up to date about MySQL and our Services.

RE: Database Label

Taxonomy upgrade extras: 

I just did a test and now understand what you are saying.

RE: Database Label

Taxonomy upgrade extras: 

Hi Oli,

You are describing exactly what I would like to do with the label. The issue is more about saying which database to monitor without having to rename our databases to the label’s format.

Database label

Taxonomy upgrade extras: 

Hello Matthew,

In the proposed way it does not work. In Zabbix a host name must be unique. What you call db_label is the Zabbix hostname.

Config file database label

Taxonomy upgrade extras: 

Hi,

In the process of setting up the agent I was modifying the FromDualMySQLagent.conf and setting up the databases as in the documentation:

Solved: host name was wrong

Taxonomy upgrade extras: 

Hello Wills,

No problem. I am lucky we finally found it. Any improvement suggestions are welcome!

Gr, the issue was definitely

Taxonomy upgrade extras: 

Gr, the issue was definitely with the zabbix server name. It was changed on Apr 5th. I’m sorry to have bothered you.

active vs. passive Zabbix Config

Taxonomy upgrade extras: 

Hello Wills,

First I would check if the host ‘util-mysql0’ matches EXACTLY the hostname in Zabbix server. That is the typical problem. Are you sure this specific item (FromDual.MySQL.mysql.version) exists under this host?

[root@util-mysql0 /]#

Taxonomy upgrade extras: 
[root@util-mysql0 /]# /usr/bin/zabbix_sender --zabbix-server util-zabbix0 --port 10051 --host 'util-mysql0' --key FromDual.MySQL.mysql.version --value 'test version' -vv zabbix_sender [8896]: DEBUG: answer [{ "response":"success", "info":"Processed 0 Failed 1 Total 1 Seconds spent 0.000017"}] Info from server: "Processed 0 Failed 1 Total 1 Seconds spent 0.000017" sent: 1; skipped: 0; total: 1

Must be Zabbix configuration. I meant the agent configuration, does it matter if it is active or passive? Something changed, but I’m not sure what at this point.

active vs. passive Zabbix Config

Taxonomy upgrade extras: 

Hello Wills,

What about uploading data of some of the relevant modules (mysql or innodb for example)? Have you changed something except upgrading the mpm agent?

Hi Oli, Thanks for replying.

Taxonomy upgrade extras: 

Hi Oli,

Thanks for replying. I did not stop the service, I probably should have before upgrading. However, I did stop the zabbix_agent (killall,) and then restarted it. Here is the log for zabbix_agentd.log: [root@util-mysql0 zabbix]# more zabbix_agentd.log 2880:20120412:104635.151 Starting Zabbix Agent [util-mysql0.arw.pvt]. Zabbix 1.8.10 (revision 24303). 2882:20120412:104635.152 agent #0 started [collector] 2884:20120412:104635.152 agent #2 started [listener] 2885:20120412:104635.152 agent #3 started [listener] 2883:20120412:104635.153 agent #1 started [listener] 2886:20120412:104635.153 agent #4 started [active checks] Here an exerpt of the mpm log in debug: 2891:2012-04-12 10:46:56.905 - DBG : Check connection to zabbix server. 2891:2012-04-12 10:46:56.906 - DBG : /usr/bin/zabbix_sender –zabbix-server util-zabbix0 –port 10051 –host ‘util-mysql0’ –key FromDual.server.check –value ‘1’ -vv zabbix_sender [2895]: DEBUG: answer [{ “response”:“success”, “info”:“Processed 0 Failed 1 Total 1 Seconds spent 0.000016”}] Info from server: “Processed 0 Failed 1 Total 1 Seconds spent 0.000016” sent: 1; skipped: 0; total: 1 2891:2012-04-12 10:46:56.911 - DBG : (ret=0). 2891:2012-04-12 10:46:56.911 - DBG : Connection to zabbix server seems OK. 2891:2012-04-12 10:46:56.911 - INFO: sendCachedData::sendCachedData 2891:2012-04-12 10:46:56.911 - DBG : Sending cache file to zabbix server. 2891:2012-04-12 10:46:56.911 - DBG : Cache file found.

FromDual.server.check does not exist.

Taxonomy upgrade extras: 

Hi Wills,

This is OK because the key does not exist in any template.

It was working for a while,

Taxonomy upgrade extras: 

It was working for a while, and it stopped on April 5th. I upgraded to the latest version, and now when I look at the log, I see this:

MySQL and Galera Load Balancer (GLB)

Taxonomy upgrade extras: 

Table of Contents

When you install a Galera Cluster for MySQL for High Availability (HA) it is not enough to install the Database Cluster to achieve this goal. You also have to make the application aware of this HA functionality. This is typically done with some kind of load balancing mechanism between the database and the application.

Troubles with MySQL 5.5 on FreeBSD 9

FreeBSD 9 seems to have some troubles with MySQL 5.5.20. A customer has moved from MySQL 5.0 on Linux to MySQL 5.5 on FreeBSD 9. He experienced a lot of periodic slow downs on the new, much stronger, system which he has not seen on the old Linux box.

I understand that you have to

Taxonomy upgrade extras: 

I understand that you have to focus on the future, no problem. My last comment wasn’t for you. But I’m testing compression in a 5.1 (with InnoDB plugin) now and these tables could help me. I will test that on a 5.5 very soon. Thx Cédric

Available in 5.5

Taxonomy upgrade extras: 

Hello Cédric,

OK. I see. 5.1 is a bit outdated now… Most of our customers are going to 5.5 now or are already on it. So we have to focus on the future.

Hello, thx for these

Taxonomy upgrade extras: 

Hello, thx for these informations. I regret that these tables are not available in 5.1 with InnoDB plugin.

InnoDB compression time calculation

Taxonomy upgrade extras: 

Hello Cédric,

What the monitor does is the following:

SELECT SUM(compress_time) AS compress_time, SUM(uncompress_time) AS uncompress_time
  FROM information_schema.INNODB_CMP

The MySQL documentation states in chapter The INFORMATION_SCHEMA INNODB_CMP and INNODB_CMP_RESET Tables:

Hi, could you explain how

Taxonomy upgrade extras: 

Hi, could you explain how InnoDB compression time is calculated ? Thx Cédric

Does InnoDB data compression help with short disk space?

Taxonomy upgrade extras: 

Because we are a bit short off disk space on one of our servers I had the idea to try out the MySQL feature Data Compression for InnoDB. This feature is useful if you have tables with VARCHAR, BLOB or TEXT attributes.

zabbix_sender failed

Taxonomy upgrade extras: 

zabbix_sender was capable to connect and send (sent: 1) but processing the item failed (Processed 0, Failed 1)

Some more troubleshooting

Taxonomy upgrade extras: 

Some more troubleshooting information: -bash-4.1$ zabbix_sender -z util-zabbix0 -s util-mysql0 -k FromDual.MySQLmysql.Questions -o “123456789” -vv

I apologize for the delayed

Taxonomy upgrade extras: 

I apologize for the delayed response. I was able to get it running. However, recently, the following error has been appearing anytime I attempt to run the FromDualMySQLagent.pl scrip manually:

Once in a while Zabbix graphs do not display any information

Taxonomy upgrade extras: 

Hello

I have successfully installed and configured zabbix to work with your performance monitoring. However, every once in a while, the graphs in zabbix do not display any information. It seems when I invoke FromDualMySQLagent.pl things go back to normal. Do I need to setup a cron to refresh the data?

Zabbix agent stopps working

Taxonomy upgrade extras: 

Hello William,

A cron job should not be necessary. It looks like the Zabbix Server disables this specific Zabbix agent/host for some reasons. So we should find, why! Could you please have a look at the zabbix_server.log and the zabbix_agent.log and let us know if you find anything?

Test Zabbix/mpm Agent

Taxonomy upgrade extras: 

Hi handon,

In the MPM installation guide I can find this:

FPMMM check not working

Taxonomy upgrade extras: 

Hi, we have a Zabbix monitoring solution up and running here but now we want to add additional database monitoring. Although I followed your installation guide I was not able to get the database monitoring online. Here I’m checking from my Zabbix installation towards the same host: sudo -u zabbix zabbix_get –host=192.168.0.10 –source-address=192.168.0.10 –key=“FromDual.MySQL.check” ZBX_NOTSUPPORTED Template is applied to the host configuration. If I fire up the perl script I also receive data in Zabbix but the script will never be executed by the agent neither do I find any errors in agent log.

Codership partners with FromDual to offer consulting and support services for Galera Cluster for MySQL

Helsinki, Finland, Uster, Switzerland – February 18, 2012 – Codership, the provider of Galera Cluster for MySQL, and FromDual, a MySQL consulting company, today announced collaboration to offer Galera Cluster technology and related support and consulting services for Galera users all over the world, especially in German speaking countries Germany, Austria and Switzerland (DACH). Galera Cluster is a synchronous, true multi-master replication cluster for MySQL using the well known InnoDB storage engine. Customers can deploy Galera Cluster locally in LAN environments, as geo-clusters over the WAN or as virtual cluster in the cloud.

What can MySQL performance monitoring graphs tell you?

Many of you may monitor their databases for different purposes. Beside alerting it is often good to also make some graphs from MySQL performance counters to see what is actually happening on your database.

ndb%count output

Taxonomy upgrade extras: 

Hello amatus,

Not sure if I understood you correctly. But the output is in the following Before and After code boxes…

Question

Taxonomy upgrade extras: 

Excellent help with EXPLAIN command.. but.. I’m having issues.. why reason there’s no results after execute this: SHOW SESSION STATUS LIKE ’ndb%count’; ??

I prefer MySQL binary tar balls with Galera...

Taxonomy upgrade extras: 

In my set-ups I have different MySQL versions (MySQL 5.0, 5.1, 5.5 and 5.6, Percona Server 13.1 and 24.0, MariaDB 5.2.10, 5.3.3, Galera 1.0, 1.1 and 2.0) running in parallel at the same time.

MPM MaaS Questions & Answers

Taxonomy upgrade extras: 

Question: How does the MPM MaaS agent send data to the service?

MPM Questions & Answers

Taxonomy upgrade extras: 

Question: What is the MySQL Performance Monitor (MPM) monitoring and what data is the agent sending?

FromDual launches Monitoring as a Service for MySQL

On January 9th FromDual launched its Monitoring as a Service (MaaS) solution for MySQL. This service is based on the Performance Monitor for MySQL (mpm) v0.8 and Zabbix.

VIP

Taxonomy upgrade extras: 

Hello Reid,

Try to break it down into smaller pieces. Do the VIP manually first:

Help with MySQL and HeartBeat

Taxonomy upgrade extras: 

Hello,

I’ve been using VMware to test in a virtual environment (for financial reasons XD)…

Newsletter Autumn 2011

Taxonomy upgrade extras: 

New version of FromDual’s Performance Monitor for MySQL (MPM) v0.7.2 is out

Dear MySQL User,

Bug in PDF

Taxonomy upgrade extras: 

Rumbi pointed me to a bug in the PDF!

The first Slave S should point to Master M on port 3315.

Old concepts, please do not use anymore...

Taxonomy upgrade extras: 

This concept/PoC is old! Nowadays we do not need this anymore.

Old concepts, please do not use anymore...

Taxonomy upgrade extras: 

This concept/PoC is old! Nowadays we do not need this anymore.

Canias optimizations

Taxonomy upgrade extras: 

Canias is a great ERP product but there is still some potential to improve it. We only focus on MyISAM/InnoDB installations of Canias v6.0.2 in this article. For other DB back-ends those recommendations might be obsolete.

MySQL Performance Monitor v.0.8 is out

Taxonomy upgrade extras: 

Yesterday we released the new version of the MPM v0.8. The most important new features are:

What about ENUM/SET and long varchar types?

Taxonomy upgrade extras: 

It seems that if you have any ENUM or SET types in your tables you’re a bit out of luck. There’s nothing in InnoDB that would give you the correct information for those. Also, since long VARCHAR columns are silently converted to TEXT you may get a definition that matches with the InnoDB data dictionary but will be slightly off from the original .frm file.

Rolling upgrade of Galera 1.0 to 1.1

Taxonomy upgrade extras: 

A few days ago Codership announced their new version Galera v1.1 - synchronous Replication Cluster for MySQL. Before we look at the new feature of Rolling Online Schema Upgrade (OSU) we have a look at how to upgrade to the new Galera release.

Example 1

Taxonomy upgrade extras: 
CREATE TABLE `order` (
  id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY
, name VARCHAR(64) NOT NULL
) ENGINE = InnoDB;

INSERT INTO `order` VALUES
  (NULL, 'Test order 1')
, (NULL, 'Test order 2')
, (NULL, 'Test order 3');


CREATE TABLE pos (
  id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY
, order_id INT UNSIGNED NOT NULL
, name VARCHAR(64) NOT NULL
, amount SMALLINT NOT NULL
, price DECIMAL (6,2) NOT NULL
, status TINYINT NULL
) ENGINE = InnoDB;

INSERT INTO pos VALUES
  (null, 1, 'Schrauben', 50, 0.10, 0)
, (null, 1, 'Muttern', 50, 0.10, 0)
, (null, 2, 'Nägel', 1000, 0.05, 1);


CREATE TABLE pos_shadow LIKE pos;
ALTER TABLE pos_shadow ENGINE = MEMORY;
INSERT INTO pos_shadow SELECT * FROM pos;

delimiter //

CREATE TRIGGER upd BEFORE UPDATE ON pos
FOR EACH ROW
BEGIN
  UPDATE pos_shadow AS p
    JOIN `order` AS o ON o.id = p.order_id and o.id = NEW.order_id
    SET status = 1
  WHERE o.id = 1;
END;
//

delimiter ;

SELECT o.name, p.name, p.amount, p.price, (p.amount*p.price) AS total, p. status
  FROM `order` AS o
  JOIN pos_shadow AS p ON p.order_id = o.id
;

UPDATE pos AS p
  JOIN `order` AS o ON o.id = p.order_id AND o.id = 1
   SET p.status = 1, p.order_id = 1
 where o.id = 1;

SELECT o.name, p.name, p.amount, p.price, (p.amount*p.price) AS total, p. status
  FROM `order` AS o
  JOIN pos AS p on p.order_id = o.id
;

Galera 1.1 release

Taxonomy upgrade extras: 

If you cannot wait you can read Building Galera Replication from scratch

Ok, thank you, I guess I will

Taxonomy upgrade extras: 

Ok, thank you, I guess I will have to wait for the 1.1 release, hopefully soon :)

Galera 1.0

Taxonomy upgrade extras: 

Yes I know! :)

It will NOT work with 1.0… We did some tests earlier with 1.0 and they failed. The results made it into into 1.1…

galera version

Taxonomy upgrade extras: 

Hello,

Thank you, very usefull informations… I am planning a migration too soon, but I am wondering because you say it’s working with release 1.1, which does not seem to be out there yet..

Additions for compiling on RedHat/CENTOS

Taxonomy upgrade extras: 

Follow the Galera documentation as well!

What was needed in addition in my case:

innodb_file_per_table and bug #62224

Taxonomy upgrade extras: 

Did you test with or without innodb_file_per table?

Did you know about MySQL Bug #62224?

Why I build from source

Taxonomy upgrade extras: 

Hello Vineet,

Great if it was a help for you…

Re: Building Galera Replication from Scratch

Taxonomy upgrade extras: 

Thanks Shinguz for such a good post, its very hard to find any blog for Galera patch & implementation.

Building Galera Replication from Scratch

Introduction

MySQL/Galera synchronous Multi-Master Replication consists of 2 parts:

If you do not want to download the prepared binaries you can build it on you own.
First you have to download the native MySQL sources, then patch it with the Galera wsrep patches and compile it. In a second step you have to build the Galera Plugin.

Teilnehmer

Taxonomy upgrade extras: 

Angemeldet haben sich: Volker, Erkan, Mario, Oli, Ronny, (Norbert), …

DOAG Conference 2011 - MySQL Community Abend

Hallo zusammen,

Einige von Euch haben sicher vor, an die DOAG Conference 2011 nach Nürnberg zu kommen, welche vom 15. bis 17. November statt findet.

Michal did a similar Survey for OpenSuSE

Taxonomy upgrade extras: 

Michal Hrušecký did a Survey of the usage of different MySQL branches on OpenSuSE Linux. The results can be found in his article: MySQL survey results (Oct 17, 2011).

1000000 InnoDB Tables

Taxonomy upgrade extras: 

We have seen a customer running a MySQL instance with about 1 Mio InnoDB tables. He had some problems (hick-ups) but basically it worked…

bind-address

Taxonomy upgrade extras: 

This depends a bit on version and distribution. Debian/Ubuntu for example sets bind-address to localhost/127.0.0.1 afaik.

MySQL was connected with

Taxonomy upgrade extras: 

MySQL was connected with localhost by default, am I right? I would like to make it not only localhost, so that my other computer can get access or connected to the database on my PC. I read through some website and they suggest to change the bind address in my.cnf. Unfortunately, I can’t locate the file and failed to find the line to change.

Re: Steps of setting up shared database server

Taxonomy upgrade extras: 

Hello BBlue,

Can you please elaborate a bit more what the problem is? It is not clear to me where you stuck.

Steps of setting up shared database server

Taxonomy upgrade extras: 

I had read your article and it does lighten my mind up. However, all my efforts on surfing for information on how to set up the shared server wasn’t enough. I can’t find a clear picture on how to set it up, even i just want to connect my virtual machine with database in my own pc. Hope can get some help.

Galera - Synchronous Multi-Master Replication Cluster for MySQL/InnoDB

Galera features

Galera provides the following features:

  • Synchronous replication
  • Active/active multi-master topology
  • Read and write to any cluster node
  • Automatic membership control, failed nodes drop from the cluster
  • Automatic node joining
  • True parallel row level replication
  • Direct client connections
  • Drop-in replacement for native MySQL

Galera benefits

Benefits using Galera Replication:

MySQL Vala Program Example

Taxonomy upgrade extras: 

Summary: In this article we have a short look at a simple MySQL example program written in Vala.

faster compression

Taxonomy upgrade extras: 

Alternatively, there is this story about a guy looking for a fast compression algorithm for backup. It’s intention is to have compression “inline”, which means it should never become a bottleneck slowing down file transfer. It seems he found a solution : http://www.mail-archive.com/fsck@truman.edu/msg00123.html

Exercises of Advanced MySQL Developer Workshop

Taxonomy upgrade extras: 

Our Advanced MySQL Developer Workshop is over now and IMHO it was quite a success.
During the workshop it is planned to have some exercises. If you are curious and if you want to test or train your MySQL skills, find the exercises here: Advanced MySQL Developer Workshop Exercises.

MySQL JMeter Webshop Benchmark

Taxonomy upgrade extras: 

Abstract: In this article we provide a little JMeter WebShop Example Benchmark for MySQL.

To zip, or not to zip, that is the question

Taxonomy upgrade extras: 

Abstract: In this article we have a look at the compression options of common zipping tools and its impact on the size of the compressed files and the compression time. Further we look at the new parallel zip tools which make use of several cores.

I, too, prefer NULL, but...

Taxonomy upgrade extras: 

If you’re using NULL to represent “anytime in the past/future” for DATETIME, that means that you need “special handling” for what would otherwise be simple inequalities.

Henrik - your conclusions are

Taxonomy upgrade extras: 

Henrik - your conclusions are too strong. If you want performant code then SQL, PL/SQL, whatever might be a bad choice. Or it might be a good choice. This just shows that that MySQL stored procedures are slower than PL/SQL and insert triggers slow down an insert. This also shows that PHP is slow and that hasn’t prevented successful deployments of it. There are many other things to consider when deciding whether to use a stored procedure or do it on the client side.

I think Oli makes exactly

Taxonomy upgrade extras: 

I think Oli makes exactly that point here. I think it’s correct to say that if you want performant code for some computation, then SQL is a bad choice, even PL/SQL. Whether MySQL or Oracle is “less bad” is kind of uninteresting, I agree with you MySQL performance is acceptable if it’s within 2x from Oracle.

How good is MySQL INSERT TRIGGER performance

Abstract: In this article we discuss how big is the performance impact of MySQL TRIGGERs compared to application side logging (with INSERT) into a MySQL table.

is it really that bad?

Taxonomy upgrade extras: 

I don’t think that 2X slower than Oracle sucks. Oracle has put a lot of resources into making PL/SQL fast. PHP results aren’t very good on this test – only 2X faster than Oracle and 4X faster than MySQL.

ER-Diagram of the InnoDB Data Dictionary

Taxonomy upgrade extras: 

With the new MySQL 5.6 release there are some more InnoDB Data Dictionary Tables in the INFORMATION_SCHEMA:

Corresponding I_S table for Percona Server

Taxonomy upgrade extras: 

Percona Server has had a buffer pool pages I_S table for a while, based on an earlier patch by Jeremy Cole or Eric Bergen, I think. However, I suspect that the Oracle implementation is likely to be safer. Some of the Percona I_S tables dealing with InnoDB internal information have had bugs, and I have become reluctant to use them on production systems. I am glad to see InnoDB providing their own implementation. Here is a link to the list of additional I_S tables provided in Percona Server: http://www.percona.com/docs/wiki/percona-server:features:indexes:index_info_schema_tables

Buffer pool dump/preload now implemented in InnoDB

Taxonomy upgrade extras: 

Interesting approach, thanks for sharing this hint! However, the latest 5.6 release may have already solved this issue: InnoDB now supports dumping and loading the buffer pool automatically on shutdown and startup: http://blogs.innodb.com/wp/2011/07/shortened-warm-up-times-with-a-preloaded-innodb-buffer-pool/

generally agree

Taxonomy upgrade extras: 

I do generally agree with the “Conclusion” mentioned at the end of this entry. It will be a topic of different post to discuss and convince people to normalize data if you see too many NULLable columns in the database.

restore buffer pool

Taxonomy upgrade extras: 

Hi Partha Dutta,

What you are describing is mentioned in Literature reference [3].

"Similar" options available in Percona Server

Taxonomy upgrade extras: 

There is a similar option available in Percona Server (I don’t recall the exact version, but its in the newer 5.1 build) called innodb_auto_lru_dump. Setting this option will dump the innodb LRU queue to disk at specified intervals (innodb_auto_lru_dump=X, where X is the interval in seconds). On server startup, this file will be read, and the corresponding pages referenced will be loaded into the buffer pool.

Shinguz, thanks a lot for

Taxonomy upgrade extras: 

Shinguz, thanks a lot for your detailed reply. I’d decided to avoid relying on indexing nulls even if MySQL supported it, as insurance against future database switch. But you took the time to test and even publish your results. Highly appreciated!

Warming up the InnoDB Buffer Pool during start-up

Taxonomy upgrade extras: 

Abstract: Heating up the InnoDB Buffer Pool during the MySQL instance startup should significantly improve InnoDB Performance in the beginning of the life of the Instance. This is achieved by sequential scans of the needed data instead of random I/O reads which would happen when we just let the system work it out by itself.
How to find the database objects which can be loaded during MySQL start-up and how to load them automatically is described in this article.

Different opinions

Taxonomy upgrade extras: 

Some people did not agree with my statements or had some questions…

Using NULL values is

Taxonomy upgrade extras: 

Using NULL values is dangerous because it can lead to incorrect results (or at least unexpected results). Take the following table: CREATE TABLE t ( id int(11) NOT NULL DEFAULT 0, city varchar(10) DEFAULT NULL );

I have seen this issue on

Taxonomy upgrade extras: 

I have seen this issue on physical servers as well. sync_binlog can help to avoid the problems.

Using NULL as default values

Taxonomy upgrade extras: 

Abstract:

It is common practice in MySQL table design that fields are declared as NOT NULL but some non-sense DEFAULT values are specified for unknown field contents. In this article we show why this behavior is non optimal an why you should better declare a field to allow NULL values and use NULL values instead of some dummy values.

Hi, Using date values like

Taxonomy upgrade extras: 

Hi,

Using date values like ‘0000-00-00 00:00:00’ is really terrible, but what about magic non-null values for indexing purposes?

Query Cache has to be disabled

Taxonomy upgrade extras: 

Hi Baron,

90% of the MySQL installations have 1 or 2 concurrent running queries. And most of the MySQL users do not have the time or the capabilities to tune queries, applications or add indexes.

HPM book documents this

Taxonomy upgrade extras: 

I believe that we documented the query cache’s behavior, and the actual mechanism for it, in High Performance MySQL 2nd Edition. The blog post looks like FromDual has found an additional bug, though.

Do NOT leave out BEGIN or START TRANSACTION!

Taxonomy upgrade extras: 

After further investigations with MariaDB developers we found out, that the Problem can be solved when an explicit BEGIN or START TRANSACTION is set in front of the SELECT.

Problem with simple Query and AUTOCOMMIT off

Taxonomy upgrade extras: 

It looks really evil as you said. I could reproduce it with the following sequence:

Bug with Query Cache

Taxonomy upgrade extras: 

Hi luke,

Great! Thank you for the hint. I somehow missed this bug… :(

problem isn't in the complex query

Taxonomy upgrade extras: 

see this. this bug was still alive… problem isn’t’ query complex or not complex. i see it in 5.5.13 community & redhat 5.1.52_log

Great, thanks a lot! it is

Taxonomy upgrade extras: 

Great, thanks a lot! it is surprising to find out how old are the versions being used outside.

MySQL versions used

Taxonomy upgrade extras: 

Hi Wlad,

Please find the numbers here:

MySQL Version

Version%
4.00.2%
4.12.7%
5.062.4%
5.129.6%
5.2 (MariaDB)1.7%
5.53.5%
100.0%
MySQL Version

Please do NOT compare the numbers with the numbers above. They have a slightly different base but the result should not change significantly…

CMS Platforms And Databases

Taxonomy upgrade extras: 

Hi cypherinfo,

Indeed, that would be interesting…

Unfortunately we do not have these numbers. CMS is nothing we have directly to do with and it seems like CMS do not typically have problems with their (MySQL) databases.

CMS Platforms And Databases

Taxonomy upgrade extras: 

it would be very interesting to study the relationship and genesis about the major cms platforms like Joomla! and their databses (GPL, Open source or not); the trend on using a commercial or free database.

Pie charts

Taxonomy upgrade extras: 

Thanks for the post, interesting insights.

Just one remark: recently I bumped into an article that argues why Pie charts are bad - esp. “fancy” 3D ones. When I started reading it, I didn’t think I’d be convinced, but after seeing the examples in the article I changed my mind. When I was trying to read the Pie charts in this articles I had an immediate recollection - it’s really hard to estimate the size of the Pie slices when they are oddly sized, in particular the smaller ones.

MySQL versions used

Taxonomy upgrade extras: 

Seufzg!

I thought this question would pop up…! I try if I find some time to gather them…

MySQL versions?

Taxonomy upgrade extras: 

Oli, do you have stas for MySQL versions used? Would be interesting to see it here.

SuSE vs. Gentoo

Taxonomy upgrade extras: 

Possibly in the 4th graph the values are not too correct. I do not know for example where MySQL packages distributed with the SuSE distribution count and where MySQL Packages FOR the SuSE distribution count. Windows on the 4th graph is completely missing so they are counted in the MySQL% packages…

It's interesting to see that

Taxonomy upgrade extras: 

It’s interesting to see that there are more production servers using Gentoo then Suse. Maybe Gentoo could/should have more attention from Mysql/Oracle? Just a thought …

MySQL out in the wild

One of our partners recently asked me on what platforms do we usually see MySQL installed out there…

Example

Taxonomy upgrade extras: 

It was just a complex Join Query as far as I can remember:

Can you give some sensible

Taxonomy upgrade extras: 

Can you give some sensible definition of complex Query? How many tables are affected, are all tables using the same table engine (which), which type of joins are used, …

MySQL Query Cache does not work with Complex Queries in Transactions

We did recently a review of one of our customers systems and we found that the Query Cache was disabled even thought it had significant more read than write queries.
When we asked the customer why he has not enabled the Query Cache he mentioned a review that was done a few years ago and which stated that the Query Cache hit ratio was non optimal.
This was verified on a testing system which had the Query Cache enabled by accident.

pros vs cons of using replication rather than the drbd method

Taxonomy upgrade extras: 

Hi rhousand,

Pros of DRBD are mostly data consistency and reliability. DRBD is a sync replication and you only have your data in one place. The Cons are Performance and Complexity.

unknown variable 'table_open_cache=3072'

Taxonomy upgrade extras: 

Hi Phil,

This looks like you are using a 32-bit MySQL Binary:

MYSQL Installation

Taxonomy upgrade extras: 

This is what im running into whenever i go to install the db on the mounted drbd device:

somebody should make

Taxonomy upgrade extras: 

somebody should make benchmarks. if you can see a batter performance sombody can make a patch, so it would be hardcoded.

More clever algorithm

Taxonomy upgrade extras: 

How would you add this logic to the script? Maybe pull out Qcache_free_blocks and Qcache_total_blocks and set them to variables?

Why not use the event scheduler?

Taxonomy upgrade extras: 

Hi,

Hopefully this will help. As of 5.1.6 (iirc) the event_scheduler has been available. Simply enable it on the server you’re using in my.cnf (details can be found in the manual).

More clever algorithm

Taxonomy upgrade extras: 

Hi Normann,

Yes, why not? Great idea!

Something like: If Qcache_free_blocks is bigger than 10% of Qcache_total_blocks then do a flush.

why not flush it after every

Taxonomy upgrade extras: 

why not flush it after every N_th QC change!

Newsletter Summer 2011

Taxonomy upgrade extras: 

Dear MySQL and MariaDB User,

With this Newsletter you receive the News about FromDual for Summer 2011.

just a rant

Taxonomy upgrade extras: 

i wonder why mysql cant flush the QC on its own. having a configuration parameter to flush every x seconds would be so much more convenient and everybody using QC would use it if reasonable defaults were set …

Regularly flushing the MySQL Query Cache

Taxonomy upgrade extras: 

When we analyze our customers systems we see typically a high fragmentation of the query cache after a while. This leads to a less optimal use of the Query Cache than possible.

InnoDB Graphs for MySQL Performance Monitor

We have just released v0.7.1 of the FromDual MySQL Performance Monitor. The new release can be downloaded from here.

sync_binlog

Taxonomy upgrade extras: 

I’ve seen this happen a lot when the master has crashed and sync_binlog isn’t turned on.

Beware of the fsync()

Taxonomy upgrade extras: 

Thats why I rant against VMWare, Xen and so on \o/ They use to cache fsync’s. So I suggest the position was there but never synced. So with the crash it was gone. But the Slave already knew the position :)

Be cautious when using Virtualized System with your Database

A customer rose a support case with a problem on his Master-Master set-up. The 2nd Master claims to have a problem:

Advanced MySQL Developer Workshop

Taxonomy upgrade extras: 

From August 15th to 17th FromDual will have an Advanced MySQL Developer Workshop with Citrus in Helsinki (Finland). The workshop will be held in English. The workshop topics you can find here and the registration form is available here.

German speaking MySQL User Group (DMySQLAG) founded today

Taxonomy upgrade extras: 

Today the German speaking MySQL User Group (DMySQLAG) was officially founded in Berlin. The association advocates:

MySQL New Features

Taxonomy upgrade extras: 

MySQL 5.6

The focus of this release seems to be on Replication, Partitioning and InnoDB/Performance.

When a MySQL table was last touched

In our last customer project we had around 600 Gbyte of data in a MySQL database. Because this database consumed a significant amount of our disk space and backups with the InnoDB backup tool took pretty long we wanted to find out if we could get rid of some of the tables.

replication vs HA setup

Taxonomy upgrade extras: 

What are the pros vs cons of using replication rather than the drbd method in your howto?

Newsletter Spring 2011

Taxonomy upgrade extras: 

Dear MySQL and MariaDB User,

With this Newsletter you receive the News about FromDual for Spring 2011:

MySQL Proxy is not full

Taxonomy upgrade extras: 

MySQL Proxy is not full multithreaded, the network layer is multithreaded, but not the LUA layer, what does it mean? As soon as you use LUA, you are again using just a single thread.

Dumping BLOB's from the MySQL database

Taxonomy upgrade extras: 

A customer who is handling digital certificates had a problem with one of those. So we had to investigate.

Percona Server improvements

Taxonomy upgrade extras: 

Percona Server has an option to limit amount of memory consumed by dictionary entries. This might be similar to what is in 5.6 from Oracle; I have not looked at the 5.6 code yet. We created this feature specifically for hosting providers :-)

Configuration of MySQL for Shared Hosting

If you ask around about shared hosting setups with MySQL everybody is frightened. In fact it looks like shared hosting is one of the most difficult setups you can get.

One of challenges with shared

Taxonomy upgrade extras: 

One of challenges with shared hosting is monitoring and controlling single user/db usage. For this I think is useful Percona Xtra DB with detailed per-user/index/host/table statistics and counters.

Medicine table

Taxonomy upgrade extras: 

Hi vishnuraj

Simple examples are always good to explain or to try to understand. So I created the following table:

Has anyone tried to compile

Taxonomy upgrade extras: 

Has anyone tried to compile the code under Windows?

MySQL Doubts

Taxonomy upgrade extras: 

Hi everybody Please rectify my doubts. In my database i have three fields as id,medicinename,quantity. In medicine name i have many different names.Many names comes twice or thrice.Now i need to fetch the data from database for particular medicine name only(this medicine name comes nearly 10 times)say for example if the medicinename is “A” it comes in id 1,4,9,12,25.Now i want to fetch the data from id 1 only.Whent the quantity comes to “0” in id “1”,i want to fetch the datas from next id.Also when the quantity comes to “0” the row shold be deleted automatically.Please help me to do this.

The DRBD Module for FromDual Performance Monitor for MySQL is now available

Taxonomy upgrade extras: 

FromDual has released today the next version v0.6 of its FromDual Performance Monitor for MySQL.

MySQL Performance Monitor, download available

Taxonomy upgrade extras: 

The FromDual Performance Monitor for MySQL is now available on our download page.

Other node cannot even respond to read only queries?

Taxonomy upgrade extras: 

An other customer was asking the following question related to this blog post:

Ein paar Anmerkungen:

Taxonomy upgrade extras: 

A friend made some private comments and allowed me to post them. IMHO they are worth considering. translate.google.com may help:

MySQL HA (high availability) Cluster cookbook

In the following article I have summarized some steps and hints to set-up a MySQL active/passive failover Cluster also sometimes called MySQL HA.

MySQL Performance Monitor with DRBD monitoring capabilities

The FromDual Performance Monitor for MySQL has now a new module for monitoring DRBD. Since more an more of our customers want to run MySQL High Availability solutions based on DRBD we have implemented this module.

Be careful when using SAN

Be careful when using SAN (Storage Area Networks) or similar shared storage solutions (and any other virtualization, consolidation or cloud solutions).

Zabbix vs. Nagios

Taxonomy upgrade extras: 

Hi Henrik,

Yes great idea!

Basically the differences are: Zabbix is an integrated Monitoring and Alerting solution where Nagios is an Alerting Solution with Monitoring modules. Zabbix is technologically newer than Nagios. I have heard from some customers that they are not happy with how Fixes and Changes are included into Nagios. Incinga is a fork of Nagios and seems to address these problems.

PrimeBase Technologies and FromDual form a Service-Cooperation for MySQL products

From the Cooperation of these two companies arises the biggest independent service provider for MySQL and MariaDB in Europe.

Zabbix vs Nagios?

Taxonomy upgrade extras: 

Hi

On your download page you have both this Zabbix based performance monitor, and the Nagios plugins. Since I’ve used neither, it would be interesting to read a separate blog post comparing the two.

FromDual releases new version of its MySQL Performance Monitor

FromDual releases its new version v0.5 of its MySQL Performance Monitor working with Zabbix.

MySQL Restore and Recovery methods

Taxonomy upgrade extras: 

Backup is for sissies! Let’s have a look what we can do when we are not a sissy…

channel_failover.pl v0.02

Taxonomy upgrade extras: 

Starting and stopping, status and failover is possible now. Script basically works but should be made a bit more sophisticated still…

Closing Circle again and channel_failover script

Taxonomy upgrade extras: 

One thing I forgot to mention: We lost Cluster B. So we rebuilt Cluster B from Cluster A.

auto_increment_increment / auto_increment_offset

Taxonomy upgrade extras: 

Hi Krishna,

I got you and fully agree with you!

Cluster Circular Replication

Taxonomy upgrade extras: 

Hi Oli,

By mistake i mention log_slave_updates. Actually, i was talking about auto_increment_increment and auto_increment_offset needs to be setup carefully, in order to avoid duplicate key errors on primary key.

Query and traffic

Taxonomy upgrade extras: 

Hello Ky,

Yes. You got me right! I meant the query on ndb_binlog_index.

Careful using log_slave_updates

Taxonomy upgrade extras: 

Hi Krishna,

Why do you think we should be carful using log_slave_updates in circular replication set-up’s?

Cluster Circular Replication

Taxonomy upgrade extras: 

Thanks, for such an informative post. It’s a new and interesting HA post. Even, i believe we should be very careful in using log_slave_updates in circular replication setup.

Recommend channel-failover procedure

Taxonomy upgrade extras: 

Thanks for the post, it is informative. Just have a few quick questions:

MySQL Cluster - Cluster circular replication with 2 replication channels

A few days ago I had to deal with MySQL Cluster replication. I did not do this for a while so I was prepared to expect some interesting surprises once again.

Thanks, I appreciate the

Taxonomy upgrade extras: 

Thanks, I appreciate the effort you are taking to find the truth. -Bradley

Same test for InnoDB

Taxonomy upgrade extras: 

I forgot to mention in the main post that I did these tests with 5.1.50.

I didn't mean to be flaming,

Taxonomy upgrade extras: 

I didn’t mean to be flaming, I’m sorry if it seemed that way. And I apologize for not noticing that the response to my comment wasn’t from the original author.

hrm

Taxonomy upgrade extras: 

Let me summarize something. You don’t disagree the cost of maintaining indexes as this blog describes. You are not disagreeing there are “some” costs for innodb either. So there is a flame MyIsam vs. InnoDb left. Which is imho not intended (at least from the author). Btw: Im not working for fromdual, so I don’t give a ***** what they do. If you want to read my homepage just click on my name;)

It is about performance

Taxonomy upgrade extras: 

You are correct that indexes cost something in InnoDB. However, if you measure InnoDB you will likely find it is much faster than MyISAM for insertions when maintaining an index on a large table. My measurements (and others, such as Mark Callaghan at Facebook) say that InnoDB is faster (maybe 4x) for this kind of load.

It is no post MyISAM vs. InnoDB

Taxonomy upgrade extras: 

Moin Bradley, the post is about the increasing cost of maintaining (more) indexes.

Use a better indexer

Taxonomy upgrade extras: 

Using MyISAM is just asking for poor performance. Try using a storage engine that is actually good at indexing.

How can I find what InnoDB version I am using?

In the old days everything was simpler. We had one maker of our favourite database management system and possibly the choice between different Storage Engines. Mostly the decision has to be taken between MyISAM and InnoDB. When you care about your data integrity you have chosen InnoDB.

Impact of indices on MySQL

Taxonomy upgrade extras: 

It is generally well known that indexes help a lot to speed up database queries (especially SELECT but also UPDATE and DELETE). It is less known, that indexes also have some disadvantages.

Does the statement run in its own transaction?

Taxonomy upgrade extras: 

Hello Justin,

Does the statement run in its own transaction after the main connection terminates?

MyISAM warm key blocks made it into MariaDB 5.2.4

Taxonomy upgrade extras: 

I just found that the MyISAM warm key blocks feature made it into MariaDB 5.2.4… :)

Getting it into MariaDB

Taxonomy upgrade extras: 

Hi Sergei,

OK I will do so… The problem with maria-developers@ is just that there is so much traffic I can oversee something which concerns me…

MySQL logon and logoff trigger for auditing

A while ago I did some research about MySQL audit functionality and logon a and logoff triggers. MySQL and MariaDB provide a logon trigger in the form of the init_connect variable but no logoff trigger where most of the work for auditing would be done. When we would have a logoff trigger we could track the login and possibility some activity of a user and implement auditing functionality.

Answering your question on

Taxonomy upgrade extras: 

Answering your question on IRC - yes, we can get it in MariaDB, although I’d prefer a slightly different interface. But anyway - we cannot discuss that in the blog, it’s the wrong medium, right? But if you write to maria-developers@ we can continue there.

transactions?

Taxonomy upgrade extras: 

Does the statement run in its own transaction after the main connection terminates?

MySQL Client Error Codes and Messages 2050 - 2099

Taxonomy upgrade extras: 

2000 - 2049

  • Error: 2050 (CR_FETCH_CANCELED)

    Message: Row retrieval was canceled by mysql_stmt_close() call

MySQL Server Error Codes and Messages 1200 - 1249

Taxonomy upgrade extras: 

1150 - 1199 1250 - 1299


  Error: 1200 SQLSTATE: HY000 (ER_BAD_SLAVE)
  Message: The server is not configured as slave; fix in config file or with CHANGE MASTER TO

How does the MySQL error message look like?

MySQL Error codes and messages

Taxonomy upgrade extras: 

Just a general rule with error messages: Usually they are not as good as they could be. But nevertheless read them carefully. Most of the time they tell you what you need to know…

Results from using PBXT with AVG_ROW_LENGTH

Taxonomy upgrade extras: 

We dug some further with this problem of too big rows. The results you can find below.

Partitioning with PBXT MEMORY tables

Taxonomy upgrade extras: 

Further discussion we had about PBXT MEMORY tables partitioned:

Q: Is there a good case where partitioned PBXT MEMORY tables could make sense?

AVG_ROW_LENGTH = 12

Taxonomy upgrade extras: 

Hi Stewart,

Thanks for your comment. Paul made some similar conclusions:

Normal PBXT makes guesses as

Taxonomy upgrade extras: 

Normal PBXT makes guesses as to what rows should be stored fixed format and what varsized.

Transactional memory resident tables with PBXT

Introduction

In his presentation about PBXT at the DOAG Conference 2010 Paul McCullagh was speaking about memory resident PBXT tables. They will be available in version 1.1 of the PBXT Storage Engine Plugin. Memory resident PBXT tables should have similar characteristics like normal MySQL MEMORY</span> tables</a>. But in addition to the MEMORY tables they are transactional and can handle BLOB</span> and TEXT attributes.

MySQL Plugins and UDF's

Taxonomy upgrade extras: 

At the DOAG 2010 we found that there are already a lot of Plugins etc. for MySQL available. Therefor it will be a good time to start with a collection of Plugins, UDF’s etc. available.

Why shall 2 LCPs be kept?

Taxonomy upgrade extras: 

Hi Baomin Wang,

After some thinking an talking to some colleagues I found the answer:

Why shall 2 LCPs be kept?

Taxonomy upgrade extras: 

Hi Baomin Wang,

  1. I come back with an answer later…

1. Why shall 2 LCPs be kept?

Taxonomy upgrade extras: 
  1. Why shall 2 LCPs be kept? It seems that 1 LCP is enough for recovering.
  2. From the above picture, When I can’t find NDB write data to data file?
  3. Does LCP do an accumulated backup or a whole backup?

MyEnv for MySQL Multi-Database set-ups

This week I showed one of my customers our MyEnv. He was very interested in it and suggested to make it known in public. In fact MyEnv is available for download already several years…

How many warm MyISAM key blocks do you have?

When you are working with MyISAM [ 1 ] tables MySQL provides a feature called the Midpoint Insertion Strategy [ 2 ]. You can enable it with the parameter key_cache_division_limit [ 3 ].

Feature request at MySQL

Taxonomy upgrade extras: 

Bug #57532: Warm key blocks in MyISAM key_cache structure could be reported

Disadvantages of explicitly NOT using InnoDB Primary Keys?

Taxonomy upgrade extras: 

We recently had the case with one of our customers where we got externally generated random hash values (up to 70 bytes) and they were used as Primary Keys in InnoDB.

FromDual plans Advanced MySQL DBA Workshop

Taxonomy upgrade extras: 

With one of its partners FromDual plans to offer an Advanced MySQL DBA Workshop. The first workshop should run in November 2010.

MySQL Performance Monitor

FromDual launches its database Performance Monitoring solution for MySQL, Percona Server and MariaDB. This solution provides monitoring capabilities for most MySQL Storage Engines (Aria, InnoDB, MyISAM, NDB, PBXT and XtraDB). Further you can monitor MySQL Master - Slave replication set-ups, UNIX processes (mysqld, ndbd) and MySQL specific information.

Who is corrupting InnoDB blocks?

Taxonomy upgrade extras: 

Because I have seen this week again a similar situation I thought about what could cause such InnoDB block corruptions. I came to the following evil-doers:

Which table is hit by an InnoDB page corruption?

InnoDB is known to have crash-recovery capabilities and thus is called a crash safe storage engine (in contrary to MyISAM). Nevertheless under certain circumstances it seems like InnoDB pages can get corrupt during a crash and then a manual crash-recovery is needed.

MySQL Cluster Local Checkpoint (LCP) and Global Checkpoint (GCP)

MySQL Cluster is mainly an in-memory database. Nevertheless it requires a good I/O system for writing various different information to disk.

CREATE ALGORITHM = TEMPTABLE VIEW

Taxonomy upgrade extras: 

To find out more about the VIEW’s behaviour I was playing around with the ALGORITHM = TEMPTABLE feature [1]. It was also related to a customers question of how VIEW’s effect performance of queries.

ODBA Interview with FromDual about the MySQL/MariaDB future

Taxonomy upgrade extras: 

Henrik Ingo from the Open Database Alliance (ODBA) did an interview with Oli Sennhauser of FromDual about the European MySQL database landscape and its future. If you want to know more about our opinion in this matter please read here.

How the MySQL Optimizer with MySQL Cluster is cheating you...

Taxonomy upgrade extras: 

At a customer we had a nice example of how the MySQL Optimizer is cheating when used in combination with the MySQL Cluster. The customer had queries running not too slow in the development environment but when he tried them on the acceptance test environment (with more data) the query was running much too long which was unacceptable because this query can occur many times per second.

FlexViews - Materialized Views for MySQL

Taxonomy upgrade extras: 

Justin Swanhart from Percona just poked me an told me about FlexViews, a package for Materialized Views he built, based on my ideas. Please have also a look there, possibly it can help you any further…

FromDual becomes Open Database Alliance (ODBA) Silver Partner

Uster, Switzerland – April 26, 2010 – FromDual has signed the Service Provider Partnership Agreement of the Open Database Alliance (ODBA).

FromDual becomes Open Database Alliance (ODBA) Silver Partner

Uster, Switzerland – April 26, 2010 – FromDual has signed the Service Provider Partnership Agreement of the Open Database Alliance (ODBA).

Is RethinkDB a possible solution for RRD SE?

Taxonomy upgrade extras: 

When I dug through RethinkDB white papers I have seen that they make use of round-robin mechanisms.

Managing sparse files on NTFS

Taxonomy upgrade extras: 

Hello Shinguz,

NTFS is sparse file-capable too. However there is no tools to deal with it in convenient way. I have written one. Check the “SparseChecker” (http://www.opalapps.com/sparse_checker/sparse_checker.html). Current version is free.

MySQL, where are you going?

Taxonomy upgrade extras: 

Our presentation MySQL, where are you going? of March 25 at the OpenExpo in Bern is now available in German and English.

The FromDual Blogs

Taxonomy upgrade extras: 

On this page you can find the various blogs of FromDual employees and some useful blog aggregates.

The MySQL CSV Storage Engine

Taxonomy upgrade extras: 

A little summary about the MySQL CSV table engine:

  • The SQL-Demo script (930 byte) for the following article.
  • The CSV converter to convert normal CSV files into a CSV format which is for MySQL acceptable.

Caution: Use on your own risk!

MySQL Cluster analysis for foodmart

Taxonomy upgrade extras: 

This is an automated analysis of the DBI:mysql:database=foodmart;host=localhost database for migration into MySQL Cluster. No warranty is made to the accuracy of the information.

ndb_size.pl report for database foodmart (21 tables)

Taxonomy upgrade extras: 

Connected to: DBI:mysql:database=foodmart;host=localhost

Including information for versions: 4.1, 5.0, 5.1

MySQL Architectures Overview

Taxonomy upgrade extras: 

Database Architecture & Design

Application logic in the middle tier?

Reduce money spent on software licenses by moving logic to the middle tier. This means moving stored procedures into the application server or web server layer where it is much cheaper to scale out. Reducing or eliminating business logic running in the DB may reduce Database CPU utilisation and hence save support costs for the DB Portability is key! [1]

What's going on when MySQL does operations on Partitions

Taxonomy upgrade extras: 

Following question came up recently: What happens if you drop or add a partition of an existing already partitioned table with ALTER TABLE? Will it be copied or will just the single partition be dropped and added? How are the index(es) rebuild after such a drop/add?

Operating System Signals on different platforms

Taxonomy upgrade extras: 
shell> kill -l

Linux

 1) SIGHUP 2) SIGINT 3) SIGQUIT 4) SIGILL
 5) SIGTRAP 6) SIGABRT 7) SIGBUS 8) SIGFPE
 9) SIGKILL10) SIGUSR111) SIGSEGV12) SIGUSR2
13) SIGPIPE14) SIGALRM15) SIGTERM16) SIGSTKFLT
17) SIGCHLD18) SIGCONT19) SIGSTOP20) SIGTSTP
21) SIGTTIN22) SIGTTOU23) SIGURG24) SIGXCPU
25) SIGXFSZ26) SIGVTALRM27) SIGPROF28) SIGWINCH
29) SIGIO30) SIGPWR31) SIGSYS
34) SIGRTMIN35) SIGRTMIN+136) SIGRTMIN+2
37) SIGRTMIN+338) SIGRTMIN+439) SIGRTMIN+540) SIGRTMIN+6
41) SIGRTMIN+742) SIGRTMIN+843) SIGRTMIN+944) SIGRTMIN+10
45) SIGRTMIN+1146) SIGRTMIN+1247) SIGRTMIN+1348) SIGRTMIN+14
49) SIGRTMIN+1550) SIGRTMAX-1451) SIGRTMAX-1352) SIGRTMAX-12
53) SIGRTMAX-1154) SIGRTMAX-1055) SIGRTMAX-956) SIGRTMAX-8
57) SIGRTMAX-758) SIGRTMAX-659) SIGRTMAX-560) SIGRTMAX-4
61) SIGRTMAX-362) SIGRTMAX-263) SIGRTMAX-164) SIGRTMAX

Solaris 10 (x86, Sparc)

 1) SIGHUP 2) SIGINT 3) SIGQUIT 4) SIGILL
 5) SIGTRAP 6) SIGABRT 7) SIGEMT 8) SIGFPE
 9) SIGKILL10) SIGBUS11) SIGSEGV12) SIGSYS
13) SIGPIPE14) SIGALRM15) SIGTERM16) SIGUSR1
17) SIGUSR218) SIGCHLD19) SIGPWR20) SIGWINCH
21) SIGURG22) SIGIO23) SIGSTOP24) SIGTSTP
25) SIGCONT26) SIGTTIN27) SIGTTOU28) SIGVTALRM
29) SIGPROF30) SIGXCPU31) SIGXFSZ32) SIGWAITING
33) SIGLWP34) SIGFREEZE35) SIGTHAW36) SIGCANCEL
37) SIGLOST
41) SIGRTMIN42) SIGRTMIN+143) SIGRTMIN+244) SIGRTMIN+3
45) SIGRTMAX-346) SIGRTMAX-247) SIGRTMAX-148) SIGRTMAX

AIX

 1) HUP 2) INT 3) QUIT 4) ILL
 5) TRAP 6) LOST 7) EMT 8) FPE
 9) KILL10) BUS11) SEGV12) SYS
13) PIPE14) ALRM15) TERM16) URG
17) STOP18) TSTP19) CONT20) CHLD
21) TTIN22) TTOU23) IO24) XCPU
25) XFSZ26) bad trap27) MSG28) WINCH
29) PWR30) USR131) USR232) PROF
33) DANGER34) VTALRM35) MIGRATE36) PRE
37) bad trap38) bad trap39) bad trap40) bad trap
41) bad trap42) bad trap43) bad trap44) bad trap
45) bad trap46) bad trap47) bad trap48) bad trap
49) bad trap50) bad trap51) bad trap52) bad trap
53) bad trap54) bad trap55) bad trap56) bad trap
57) bad trap58) bad trap59) bad trap60) GRANT
61) RETRACT62) SOUND63) SAK

OpenBSD

 1) HUP 2) INT 3) QUIT 4) ILL
 5) TRAP 6) ABRT 7) EMT 8) FPE
 9) KILL10) BUS11) SEGV12) SYS
13) PIPE14) ALRM15) TERM16) URG
17) STOP18) TSTP19) CONT20) CHLD
21) TTIN22) TTOU23) IO24) XCPU
25) XFSZ26) VTALRM27) PROF28) WINCH
29) INFO30) USR131) USR2

HP-UX

 1) HUP 2) INT 3) QUIT 4) ILL
 5) TRAP 6) ABRT 7) EMT 8) FPE
 9) KILL10) BUS11) SEGV12) SYS
13) PIPE14) ALRM15) TERM16) USR1
17) USR218) CHLD19) PWR20) VTALRM
21) PROF22) IO23) WINCH24) STOP
25) TSTP26) CONT27) TTIN28) TTOU
29) URG30) LOST31) RESERVED32) ?
33) XCPU34) XFSZ35) ?36) ?
37) RTMIN38) RTMIN+139) RTMIN+240) RTMIN+3
41) RTMAX-342) RTMAX-243) RTMAX-144) RTMAX

MySQL Cluster overview

Taxonomy upgrade extras: 

This is a chaotic collection of my MySQL Cluster experience…

MySQL Cluster memory sizing

Taxonomy upgrade extras: 

MySQL Cluster is pretty fast. The reason for this is, that it is completely memory based. Nowadays memory is still, in contrary to disk, limited to your systems. Thus, before installing a MySQL Cluster you have to calculate the amount of memory you need.

DBA wisdoms

Taxonomy upgrade extras: 

Controlling developers is like herding cats.

Kevin Loney, Oracle DBA Handbook

Oh no, it's not. It's much harder than that!

Limitations of MySQL

Often asked but informations are spread around: The limitations of MySQL.

MySQL User Defined Function (UDF) collection

Taxonomy upgrade extras: 

I really like this new toy called UDF. So I try to provide some more, hopefully useful, functionality.

The handler_read_* status variables

Because I do a lot of Performance Tuning gigs I get often in contact with these status variables. In the beginning I had a problem to understand them and now I have a problem to memorize the relation of the name and the meaning. Therefore I wrote this little summary:

Hunting the core

Taxonomy upgrade extras: 

Core files under Linux

When dealing with MySQL crashes it is very useful to get the core files for further debugging. I have collected all the informations I found about it and wrote it together here:

Reading other processes memory

Taxonomy upgrade extras: 

As you probably have experienced yet MySQL does not always provide all internal information as you might want to have them and as you are used to have from other RDBMS.

MySQL Monitoring solutions

Basic solutions (CLI)

Those solutions are run from the command line (CLI):

Profiling MySQL with oprofile

Taxonomy upgrade extras: 

Why is is data load with LOAD DATA INFILE so much faster?

MySQL Federated Storage Engine

What is a Federated Table?

A Federated Table is a table which points to a table in an other MySQL database instance (mostly on an other server). It can be seen as a view to this remote database table. Other RDBMS have similar concepts for example database links.

MariaDB and MySQL Benchmarking

Table of Contents

Database Benchmark

General Benchmarking Tools

  • Apache JMeter: To test performance on static and dynamic resources (files, Servlets, Perl scripts, Java Objects, Data Bases and Queries, FTP Servers and more).
  • Gatling: Gatling is a highly capable load testing tool. It is designed for ease of use, maintainability and high performance.
  • Tsung: Open-source multi-protocol distributed load testing tool.
  • Slamd Java-based Distributed Load Generation Engine application designed for stress testing and performance analysis of network-based applications.
  • Grinder A Java load testing framework that makes it easy to run a distributed test using many load injector machines.
  • mysqlslap mysqlslap is a diagnostic program designed to emulate client load for a MySQL server and to report the timing of each stage. It works as if multiple clients are accessing the server.
  • bm
  • httperf
  • apachebench (ab)

CPU Benchmarking

Disk benchmarking

# bonnie -s 2047 -S 10000

Bonnie 1.4: File './Bonnie.12330', size: 2146435072, volumes: 1
Writing with putc()...         done:  20440 kB/s  89.7 %CPU
Rewriting...                   done:  18940 kB/s  18.3 %CPU
Writing intelligently...       done:  46256 kB/s  28.8 %CPU
Reading with getc()...         done:  18771 kB/s  82.1 %CPU
Reading intelligently...       done:  32549 kB/s  17.3 %CPU

              ---Sequential Output (nosync)--- ---Sequential Input-- --Rnd Seek-
              -Per Char- --Block--- -Rewrite-- -Per Char- --Block--- --10k (03)-
Machine    MB K/sec %CPU K/sec %CPU K/sec %CPU K/sec %CPU K/sec %CPU   /sec %CPU
master 1*2047 20440 89.7 46256 28.8 18940 18.3 18771 82.1 32549 17.3  183.6  1.5

with fsync

MySQL pluggable Storage Engines (SE)

One of the big advantages of MySQL is its concept of Pluggable Storage Engines. This means you can choose the most optimal Storage Engine for your needs. This also has a disadvantage: You have to know what you are doing…

FromDual - The MySQL consulting company goes operational today!

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Ivan

Thanks a lot for your wishes!

FromDual - The MySQL consulting company goes operational today!

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/04013184952866618726 Ivan] said…

Oli!

I wish you all the best and good luck!

FromDual - The MySQL consulting company goes operational today!

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hello Henrik,

Thank you very much for your wishes and all you have done already!

FromDual - The MySQL consulting company goes operational today!

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/09201666166374161923 hingo] said…

Hi Oli

I wish you all the best in taking this step, and promise to do all I can to help you!

FromDual - The MySQL consulting company goes operational today!

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Ronald, hi Fortxun,

Thank you very much for your wishes. I hope we will meet once in a while (again)…

FromDual - The MySQL consulting company goes operational today!

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/13150580805698500214 Fortxun] said…

Excellent, good luck!.

FromDual - The MySQL consulting company goes operational today!

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/16170615042077930093 Ronald Bradford] said…

Congrats Oli.

I hope you have a very prosperous business!

FromDual - The MySQL consulting company goes operational today!

Taxonomy upgrade extras: 

Hello everybody,

One month earlier than planned we have the great pleasure to announce you that the company called FromDual goes operational today!

What is CHECK TABLE doing with InnoDB tables?

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/16041515498065869604 qu1j0t3] said…

ZFS can prevent corruption from ever reaching MySQL (or any application).

Logging users to the MySQL error log

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Shlomi,

Thanks a lot for your input!

Logging users to the MySQL error log

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11874165719204714241 Shlomi N.] said…

Hi, This is a cool hack! One can simplify it by not writing to the error log but to some internal log table, in which case you can use a normal stored function, no need for UTF.

Logging users to the MySQL error log

Problem

A customer recently showed up with the following problem:

Using MySQL User-Defined Functions (UDF) to get MySQL internal i

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/05445777885744635565 Jo] said…

I wrote an interesting UDF you may be interested. JsMap - running JavaScript in MySQL

Can you trust your MySQL backup?

Today a customer with corrupted data files showed up. When we enquired a bit more he told us that he had a broken I/O controller. This is one of the worst things which can happen to you!

What is CHECK TABLE doing with InnoDB tables?

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hello kabel,

Thanks for the flowers!

Anyhow, logical backups with such an amount of data is nearly impossible to restore (in a timely manner)!

What is CHECK TABLE doing with InnoDB tables?

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/08993510241119917712 kabel] said…

Wow. This post could not have been more timely. I have a (legacy) server with a large (600G) InnoDB tablespace that is slightly corrupted. A new machine has been rotated into production while I clean up this monster, but you just saved me a lot of heartache with the fatal lock timeout catch. It’s probably going to end up being a incremental table dump and restore.

MySQL on VMware Workstation/DRBD vs. VMWare ESX Server/SAN

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/17059197203923199652 Oliver] said…

I have set up almost identical scenarios on top of Xen, and I found performance to be quite acceptable.

What is CHECK TABLE doing with InnoDB tables?

Recently we had a case where a customer got some corrupted blocks in his InnoDB tables. His largest tables where quite big, about 30 to 100 Gbyte. Why he got this corrupted blocks we did not find out yet (disk broken?).

MySQL on VMware Workstation/DRBD vs. VMWare ESX Server/SAN

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/04408844340588067447 Charlie] said…

You should expect stellar performance, actually! DRBD, when configured well, has less than a 10% overhead.

MySQL on VMware Workstation/DRBD vs. VMWare ESX Server/SAN

Taxonomy upgrade extras: 

Or an active-active failover cluster à la VMware.

Today I have learned about a totally crazy/cool looking architecture where the expensive VMware ESX server was replace by a free/cheap VMware Workstation version in combination with DRBD.

The battle against Oracle is probably over but has the real war begun yet?

According to different sources from the web the decision about the Oracle - Sun merger has been approved by the European commission soon. So at least in the West it is clear what is going on. Let us see what the East decides… [ 1 ], [ 2 ].

MySQL reporting to syslog

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/13094362409916524291 Antony] said…

Alas, the new log/audit framework I had developed for MySQL 6.0 would happily log to multiple targets. I guess I should find the time to extract the code from the defunct 6.0 repository and contribute it to MariaDB.

MySQL reporting to syslog

Taxonomy upgrade extras: 

There are 2 different possible situations you can face when you have to deal with MySQL and syslog:

My wish for the New Year: MySQL DBA's, please install iostat on

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/09563736552283458282 Leandro] said…

Not to mention that sysstat also includes “sar”, which is one of the best tools to record system resource usage history! :)

My wish for the New Year: MySQL DBA's, please install iostat on

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Brian,

Thanks for the hint. Just added it!

My wish for the New Year: MySQL DBA's, please install iostat on

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/10147638743111625798 Brian Moon] said…

You forgot:

emerge -avq sysstat

Gentoo 4tw!! =)

My wish for the New Year: MySQL DBA's, please install iostat on your servers!

Taxonomy upgrade extras: 

iostat is a very handy tool to help you investigating what kind of performance problems you have. Especially your databases can cause a lot of troubles to your I/O system and thus it would be very nice if every DBA has installed iostat on all of his MySQL database servers.

MySQL useful add-on collection using UDF

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Roland,

Ups! It seems like I did not look into it well enough… :( Thanks for your hint!

MySQL useful add-on collection using UDF

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/13365137747952711328 Roland Bouman] said…

Hi there,

I did this too once (http://rpbouman.blogspot.com/2008/07/writing-to-mysql-error-log.html)

MySQL useful add-on collection using UDF

I really like this new toy (for me) called UDF. So I try to provide some more, hopefully useful, functionality.

Using MySQL User-Defined Functions (UDF) to get MySQL internal i

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

I was told that spin_wait_delay is exposed to public with the InnoDB pluggable storage engine 1.0.4. Seems I have to look for an other hidden variables now. :)

Using MySQL User-Defined Functions (UDF) to get MySQL internal i

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Papagnome,

You are absolutely right, UDF’s came in in 3.23 already (I was told). What was in my mind was more the pluggable stuff. This feature is very nice an pretty new. But somehow I did not manage to express what I wanted to… :)

Using MySQL User-Defined Functions (UDF) to get MySQL internal i

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/04939369461678423022 papagnome] said…

Just FWIW, UDFs existed in 4.1 and I’m pretty sure in 4.0 as well.

Using MySQL User-Defined Functions (UDF) to get MySQL internal i

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Mark,

Thanks a lot for your feedback. And how is the correct way to make it version IN-dependent and thus better portable?

Using MySQL User-Defined Functions (UDF) to get MySQL internal i

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/15864507044869250062 Mark Robson] said…

I also tried to use mysql UDFs to call internal MySQL APIs. It works.

Using MySQL User-Defined Functions (UDF) to get MySQL internal informations

In one of my previous posts I was writing about how to read other processes memory
[ 1
]. As an example I tried to get the value of the hard coded MySQL internal InnoDB variable spin_wait_delay (srv_spin_wait_delay).

Using MySQL User-Defined Functions (UDF) to get MySQL internal i

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Andrew pointed me to the following blog entry of Brian: [http://krow.livejournal.com/481313.html Daemon Example (deamon plugin)]

Determine in MySQL if we are in summer time or winter time (day

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Björn,

Thanks a lot for you post. Much better than mine! :)

Determine in MySQL if we are in summer time or winter time (dayl

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/12606038649636876830 arathorn2005] said…

Nice approach!

Try this:

SELECT IF(TIMESTAMPDIFF(HOUR , UTC_TIMESTAMP(), SYSDATE()) = 2, ‘summer time’, ‘winter time’) AS TIME;

Determine in MySQL if we are in summer time or winter time (daylight saving time, DST)

Recently a colleague at Sun was asking me if MySQL can tell him to determine if we are currently in summer time or winter time. He was doing some data analysis of his house where he has installed solar panels.

Reading other processes memory

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

A colleague pointed out that I was missing some information:

Reading other processes memory

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/07820955267400574921 Morgan] said…

I just read what I wrote, sorry for not making sense. What I meant:

Reading other processes memory

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Morgan,

Do not get this. With the script read_process_memory.sh you can sample at a specific interval with a timestamp in the record and write a *.csv. That must be ideal for Cacti or any other monitoring/graphing tool, is it not? You could even extend it to write directly to a database…

Reading other processes memory

Taxonomy upgrade extras: 

As you probably have experienced yet MySQL does not always provide all internal information as you might want to have them and as you are used to have from other RDBMS.

Reading other processes memory

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/07820955267400574921 Morgan] said…

Very nice! I can see the real use with some of the InnoDB stats. The random sampling interval makes it very difficult to get good numbers to use for cacti/RRDTool graphs.

Typical automated MySQL maintenance jobs

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/07511835531671315487 Daniel] said…

knetknight

I’m not to hot on MySQL but I would have thought 5. repair table would be avoided except as a last result?

MySQL licenses for dummies

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/07820955267400574921 Morgan] said…

You might want to add that Community Edition has partitioning.

MySQL licenses for dummies

Taxonomy upgrade extras: 

The following summary shows my personal understanding of MySQL 5.1 licenses, packages and products. It does not necessarily reflect 100% the way MySQL understands it. But after all the discussions I hope it is as close as possible to the reality:

Why does MySQL Cluster takes so long for --initial?

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/02551781456999098405 Jonas Oreland] said…

FYI: I also added a new config parameter in 6.3.19, that makes the redo-files to be fully initialized:

Why does MySQL Cluster takes so long for --initial?

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hey guys,

Have a look at the addendum. I have updated it.

Why does MySQL Cluster takes so long for --initial?

Taxonomy upgrade extras: 

Anonymous said…

Thanks for sharing this. This is a very good read!

Why does MySQL Cluster takes so long for --initial?

Taxonomy upgrade extras: 

Anonymous said…

Will this performance improvement patch made it into normal releases or will it be available for Enterprise customers only?

Why does MySQL Cluster takes so long for --initial?

Taxonomy upgrade extras: 

This week we had a very interesting problem at a customer: They complained, that their MySQL Cluster takes about 1 hour for a --initial start-up. After some tuning on the hardware and the config.ini they brought it down to around 40 minutes. But this is still unacceptable long…

MySQL Multi-Master – Single-Slave – Replication (Episode 2)

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Baron

Hmmm. Did not know about it. But to be honest: I did not yet have time to look at all the nice stuff from your Maatkit and all the cool Google Patches and OurDelta etc… :-(

MySQL Multi-Master – Single-Slave – Replication (Episode 2)

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi Willy

Yes. MySQL circular replication usually works fine (technically). I hope you have a good concept cleaning it up again when it some how messes up!

MySQL Multi-Master – Single-Slave – Replication (Episode 2)

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/02327079024123812197 willy] said…

I have 4 servers, I need 4 servers share changes made on each one, my solution was configure them in ring schema, this is: server1 is master of server2 and slave of server4, server2 is master of server3 and slave of server1, and so on. This works fine. All server updates on same schema. Hope to be useful.

MySQL Multi-Master – Single-Slave – Replication (Episode 2)

Introduction

One of the features that make MySQL so great is its easy replication set-up. If you are experienced and know-how to do it, it takes you about 15 minutes to set-up a slave. What you have in the end is a replication from one master to one or several slaves. So you can build a top-down data stream pyramid and spread your data on many slaves.

MySQL Multi-Master – Single-Slave – Replication (Episode 2)

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/01621441847303652718 Baron] said…

You can also use [http://code.google.com/p/mysql-mmre/ MySQL mmre]

Test application for MySQL high availability (HA) set-up

When I set-up a MySQL HA environment for customers I usually do some final failover tests after configuring the whole beast.

Citation of the week

Taxonomy upgrade extras: 

Das dreieckige Rad hat gegenüber dem viereckigen einen gewaltigen Vorteil: Ein Rumms weniger pro Umdrehung!

Typical automated MySQL maintenance jobs

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said…

Hi knetknight

Thanks for your comment.

When your are facing time/scheduling issues I recommend you to go through the MySQL online documentation (Chapter: Table Maintenance Statements and Restrictions on InnoDB Tables) because some of these commands have no effect on some table types (InnoDB) and some of them do the work already done in a previous command.

MySQL Cluster: No more room in index file

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/11195863756524022642 Shinguz] said… Hi Matthew

Thanks for your comment. This could have helped a lot. I do NOT ask why there was no message like:

MySQL Cluster: No more room in index file

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/04421029174237420523 Matthew Montgomery] said…

In this example I lowered the MaxNoOfOrderedIndexes to 25 and created a bunch of tables, then I got.

MySQL Cluster: No more room in index file

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/04421029174237420523 Matthew Montgomery] said…

After any error in mysqld dealing with NDB tables you should always run “SHOW WARNINGS”. MySQL will only show the last error, which is the mysqld error, “no more room in index file” at execution time. This means that the NDB error which bubbled up to mysqld won’t be displayed unless you use the “SHOW WARNINGS” command.

MySQL Cluster: No more room in index file

Taxonomy upgrade extras: 

Recently we were migrating an InnoDB/MyISAM schema to NDB. I was too lazy to calculate all the needed MySQL Cluster parameters (for example with ndb_size.pl) and just took my default config.ini template.

Possible memory leak in NDB-API applications?

Taxonomy upgrade extras: 

A customer has recently experienced a possible memory leak in its NDB-API application. What he did was something like:

Active/active failover cluster with MySQL Replication

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/13990877688502800403 Sheeri K. Cabral] said…

You could probably very easily put this all into a lua script, slap MySQL Proxy in front of it, and have automated failover – if it can’t reach the 1st backend, pick among the other backends by doing a query, promote it, etc.

Active/active failover cluster with MySQL Replication

Electing a slave as new master and aligning the other slaves to the new master

In a simple MySQL Replication set-up you have high-availability (HA) on the read side (r). But for the master which covers all the writes (w) and the time critical read (rt) there is no HA implemented. For some situations this can be OK. For example if you have rarely writes or if you can wait until a new Master is set up.

Typical automated MySQL maintenance jobs

Taxonomy upgrade extras: 

[http://www.blogger.com/profile/13385339200643211924 knetknight] said…

Just what I needed. I have become the maintainer of a small but previously neglected mysql server and was looking for exactly this kind of info. It serves one database which feeds an intranet application. The database/tables hadn’t had any maintenance in three years so I found some errors in it initially and am now in the process of automating basic maintenance.

Typical automated MySQL maintenance jobs, query cache

The following maintenance jobs are typically run against a MySQL database:

Some more details about DiskSyncSize

Taxonomy upgrade extras: 

Jon Stephens said…

According to the information I have, it was added in 5.1.12, not 5.1.23.

My thoughts about MySQL (Cluster) replication

Taxonomy upgrade extras: 

According to Johans wishes I write down my concerns about MySQL (Cluster) replication. These items are things I run again and again into it with customers:

Some more details about DiskSyncSize

Taxonomy upgrade extras: 

Johan Andersson said…

I guess it is related to DiskCheckpointSpeed nowadays (>= 5.1 ).

Some more details about DiskSyncSize

The parameter DiskSyncSize is a MySQL Cluster parameter and was added in MySQL 5.1.23.

With MySQL-Enterprise Montior through firewalls

Taxonomy upgrade extras: 

Sometimes it is nice to show customers the functionality of MySQL-Enterprise Monitor (aka Merlin). I install the agents on the servers and the dashboard runs on my laptop. But very often only ssh is open to these servers.

Sparse files

Taxonomy upgrade extras: 

What is a sparse file?

“A sparse file is a file where space has been allocated but not actually filled with data. These space is not written to the file system. Instead, brief information about these empty regions is stored, which takes up much less disk space. These regions are only written to disk at their actual size when data is written to them. The file system transparently converts reads from empty sections into blocks filled with zero bytes at runtime.”
[ 1
]

Ranking in MySQL results

Taxonomy upgrade extras: 

A friend of me asked me long time ago: “How can I have a ranking on a result with MySQL?”. Now I found some time to write it down:

MySQL logon trigger

With MySQL 5.0 the database provides trigger functionality on INSERT, REPLACE, UPDATE and DELETE.

MySQL Cluster restore

Recently the question came up if it is faster to restore a MySQL cluster when all nodes are up or only ONE node from each node group during restore.

MySQL Active - Active Clustering

It is possible to use an active - active shared-disk cluster in MySQL in some cases. For doing this you have to fulfill the following requirements:

Transaction performance

Transaction performance relates among other things from I/O performance. This means hard disk performance.

Round-Robin Database Storage Engine (RRD)

In a round-robin database (RRD) usually time-series data like network bandwidth, temperatures, CPU load etc. is stored. The data is stored in the way that system storage footprint remains constant over time. This avoids resource expensive purge jobs and reduces complexity.

SATA Flash Solid State Disk up to 160 Gbyte announced!

The price for a 160 Gbyte disk will be around USD 15'000. This is still a bit expensive. But the access time is around 0.5 ms (both for reading and writing) which is around 10 times faster than a normal 15'000 rpm SCSI disk! The disk has NO cache because it is a cache itself (according to the supplier. Maybe this will change in the future). And the lifetime of a cell is > 5 mio writes. For the same performance one needs usually an array of around 10 disks. If your database is heavily write-I/O bound you should consider this solution.

MySQL Multi-Master - Single-Slave - Replication

MySQL provides its replication for High Availability (HA) and for read Scale-out. Generally it is known that in a MySQL replication you can only replicate from one Master to many slaves. In this paper it is shown how a set-up can look like to replicate from two masters to one slave.

Profiling MySQL with oprofile

Taxonomy upgrade extras: 

Probably the answer to this question is already known. But we want to prove it and by the way learn to deal with MySQL and oprofile.

Materialized Views (MV) with MySQL

Materialised View (MV) is the pre-calculated (materialised) result of a query. Unlike a simple VIEW the result of a Materialised View is stored somewhere, generally in a table. Materialised Views are used when immediate response is needed and the query where the Materialised View bases on would take to long to produce a result. Materialised Views have to be refreshed once in a while. It depends on the requirements how often a Materialised View is refreshed and how actual its content is. Basically a Materialised View can be refreshed immediately or deferred, it can be refreshed fully or to a certain point in time. MySQL does not provide Materialised Views by itself. But it is easy to build Materialised Views yourself.

Pittfalls with Federated Tables

A Federated Table is a table which points to a table in an other MySQL database instance (mostly on an other server). It can be seen as a view to this remote database table. Other RDBMS have similar concepts for example database links.

Some more benchmarks added

Taxonomy upgrade extras: 

We have added some more database benchmarks to our collection.

MySQL storage engines

Taxonomy upgrade extras: 

One of the big advantages of MySQL is its concept of pluggable Storage Engines (SE). This means you can choose the most optimal storage engine for your needs. This also has a disadvantage: You have to know what you are doing…

Full-Text Search Engines

MySQL has also a Full-Text Search Engine built in. But this Search Engine is not as fast a you probably want to. Thus there are some alternative Full-Text Search Engines which might be working together with MySQL.

Stealthy migrating MySQL tables and MySQL data access interfaces using enlarged updateable VIEW functionality

Applications occasionally require redesign. However, redesigning an application cannot be done in one step because the application is distributed or several versions of applications must be supported. MySQL 5.0 provides the necessary means to stealthy migrate your data. In a short overview let’s look at what we plan to do: Stealthy Migration (PDF 98.7 kByte).

Subscribe to FromDual RSS