If you experience any difficulty in accessing content on our website, please contact us at 1-866-333-8917 or email us at support@chicagovps.net and we will make every effort to assist you.

Nick Phillips
By
June 4, 2018

MYSQL AND ALTERNATIVES

  MySQL

Introduction

Most web applications store content and process information from a database. MySQL is the second most popular database according to Statistia.com. Whether you are running a successful eCommerce store or your fun blogging application, these installations require you to install MySQL.

This article talks about MySQL licensing (yes, it has a commercial version) and how the free alternatives stack up.

Commercial Licensing for MySQL

Since the days before Oracle purchased MySQL, there has been an enterprise version targeted towards the commercial market. Whether by incorrect understanding of the terms or by false propaganda, this has sometimes come to mean that if you are running an application for profit, such as a subscription based service or charging users for using a platform, you need to get the Enterprise Version.

Sadly, this is untrue. With the caveat, that you need to talk to a lawyer in case of doubts, here is a quick 401 on when the commercial applies and when it doesn’t it

 
 
Use Case Commercial?
You are creating a closed source application that uses MySQL as an embedded install Yes
You are developing a closed source commercial application that connects to MySQL to store data No
You are developing a commercial application and will be distributing MySQL along with your application. However, the commercial application code is also distributed with the binary No
You are developing a free Open Source application and will include interfacing code/drivers for MySQL with you application No

The key point is about how MySQL is used. Violating the GPL license does not count If you are merely storing information in MySQL and interfacing with the database system.

FORKS

Around the time when MySQL 5.0/5.1 was launched, Percona Server was introduced. This was also followed by the release of MariaDB 5.1 by some of MySQL’s original authors and top developers (who were publicly unhappy about Oracle’s purchase of Sun Microsystems who had earlier bought MySQL).

Both Percona Server & MariaDB are “drop-in” replacements for MySQL. This means that in almost all use-cases, if an installation manual calls for MySQL installation, you could either deploy MySQL/MariaDB/Percona and not face any problems.

Did you know?

MySQL and MariaDB are named after the daughters of the main author of the RDBMS – Ulf Michael Widenius?

Let us talk about these forks and when you may need to choose one over the other.

MariaDB

According to its creators, MariaDB was an open source alternative to MySQL that would be developed with the community and would be perpetually free. The developers intended for MariaDB to be a drop-in replacement. This means that you could uninstall MySQL and install MariaDB without any change in code. To ease this, they even named the MariaDB versions to match MySQL. MySQL 5.1 could be replaced with MariaDB 5.1 and so on.

However, this changed since MariaDB 5.5. MariaDB 10.0 is based on MySQL 5.6, but not all MySQL 5.6 features are imported leading to the major version number change. The latest version of MariaDB (at the time of writing) is 10.3 released on May 25th 2018.

MariaDB contributes back to the upstream on a monthly basis which allows MySQL to pick up any new developments that MariaDB engineers have coded.

The storage engines supported & used by MariaDB range from InnoDB (which MySQL uses) to XtraDB (created by Percona) to ColumnStore (for handling petabytes of data)

Prominent Institutions using MariaDB

  • Wikimedia/Wikipedia (one of the first large sites to migrate and report better performance)
  • Google
  • Mozilla

Percona

Percona Server was one of the first forks of MySQL and it attempts to be as close to the MySQL version as possible whilst adding features such as the XtraDB storage engine which outperforms InnoDB. When a feature from Percona is picked up by Oracle, the Percona team removes their implementation in favor of MySQL’s implementation making Percona a 100% compatible with MySQL

The focus at Percona is more on improving sever performance and availability. I already mentioned the XtraDB engine, the other stand-out feature is the option to take online backups and perform Online table import/export without any downtime to the application. Percona has also imported features that are available only in MySQL Enterprise such as PAM Authentication.

As I mentioned earlier, Percona code is close to MySQL which means that they are quicker to release their new version based on MySQL releases quicker than MySQL

A case in point, MySQL 5.7 was released on 21st Oct 2015 and Percona 5.7 was available 4 months later on 23rd Februrary 2016. The MariaDB version based on MySQL 5.7 was 10.2 which was released on 23rd March 2017, 13 months after Percona.

The latest version (when this article was published) is 5.7 released on 24th April 2018.

Prominent Institutions using Percona

  • Groupon
  • Yelp
  • BBC

Choosing the Right DB

I wish I could tell you that one fork was the best one, but there isn’t. Whether you go for one over the other depends on what you need.

Go for MariaDB if

  • You are looking for the latest developments in the area of DB technology and want upgrade features before MySQL releases them
  • You need security patches to be rolled out quicker
  • You need a variety of storage engines to be supported out of the box

Go for Percona if

  • You want quicker query response time (MariaDB 10.2 defaults back to InnoDB instead of XtraDB storage engine)
  • You want reduced maintenance time and features such as online backup
  • You would like your DB to be as close to MySQL as possible

They tried too…

Drizzle was forked from the 6.0 Development branch of MySQL. It was created to build a slimmer and (hopefully) faster version of MySQL. Work started in mid-2008 and had backers from Canonical, Google, Red Hat and even Percona amongst others. The last stable branch was version 7.2.4 in September 2012.

WebScaleSQL was created by a consortium of companies such as Facebook, Google, LinkedIn and Twitter to build a database that can scale well and easily handle terabytes of data from multiple servers. The selling point for WebScaleSQL was to provide a centralized development structure for extending MySQL for large-scale deployments.

The WebScaleSQL site stated in December 2016 that due to differences between the original contributing companies, they would no longer contribute. The GitHub project has a last commit date in July 2015.

OurDelta was developed as enhancements on MySQL 5.0 with the underlying principle that real production environments required features added more quickly than MySQL was rolling out. By better binary packaging to different Linux flavors, it allowed testing in more environments. However, all these enhancements were folded into Maria DB 5.1

Summary

MariaDB was designed to offer scalability, multiple server replication and to optimize queries. Percona on the other hand, is focused on high availability and getting data out quicker than vanilla MySQL. They are both great alternatives to MySQL and have an excellent and active developer and support community.

References

https://oss.oracle.com/licenses/universal-foss-exception/ – Free & Open Source Exception for MySQL usage

https://mariadb.com/kb/en/library/mariadb-vs-mysql-compatibility/ – Compatibility between MySQL & MariaDB across versions

https://www.percona.com/software/mysql-database/percona-server/feature-comparison Percona Feature list

Subscribe Email

Top