We’ve been measuring MySQL replication lag with heartbeats for more than a decade. It works, but can we do better? Let’s see.
MySQL 8.0 is now over four years old and Oracle released the latest quarterly offering today with MySQL 8.0.30, which comes with lots of bug fixes and some interesting additions. This is my take on the release notes for those who do not have the time to wade through them, comments in italics are my comments and reflect the views of only me.
This is an interesting release with a good many bug fixes and I urge those who need fixes to upgrade as soon as they can. For everyone else, the TL;DR is that unless you are on the Oracle Cloud Infrastructure or one of the fixed bugs is causing you problems, then upgrade at your leisure.
Deprecation and removals
Setting the replica_parallel_workers system variable to 0 is now deprecated and to use single threading set replica_parallel_workers=1 instead. …
[Read more]As powerful and useful as the CodeIgniter 4 Query Builder class methods and functions are, there are times when you need to hand-craft your own queries. Perhaps they are complex. Or, you would just rather write the raw SQL. Learn how to safely use the input you need – typically as part of the WHERE clause conditional(s) – using 2 different parameter binding variations with examples in MySQL.
Image by Clker-Free-Vector-Images from Pixabay …
[Read more]Consider this simple Integration Services package. It’s simple because the task is to upload a CSV file to SQL Server. No transformations. Notice the warning in the OLE DB Destination. It’s a string truncation warning. The source column has 50 characters but the target has only 20. So, what? The package may run without errors. […]
The post SSIS Data Types: The No-Sweat Guide with Easy Examples appeared first on Devart Blog.
Introduction/FAQ
Question: I need to run a production-grade open source MySQL DB.
Answer: Percona to the rescue! Percona XtraDB Cluster (PXC) is an open source enterprise MySQL solution that helps you to ensure data availability for your applications while improving security and simplifying the development of new applications in the most demanding public, private, and hybrid cloud environments
Question: I forgot to mention that I need to run it on Kubernetes.
Answer: Percona to the rescue again! Percona Distribution for MySQL Operator based on Percona XtraDB Cluster contains everything you need to quickly and consistently deploy and scale Percona XtraDB …
[Read more]Hey hey, OpenLampTech is back this week with another packed issue of the best MySQL, PHP, and LAMP stack content I am sharing from the web. Enjoy!
The Newsletter for PHP and MySQL Developers
Receive a copy of my ebook, “10 MySQL Tips For Everyone”, absolutely free when you subscribe to the OpenLampTech newsletter.
In OpenLampTech issue #36, we are looking at articles covering:
- PHP == vs === comparison operators
- MySQL ALTER TABLE
- Installing WordPress in a subdirectory.
- Why developers prefer Linux
- Getting your website ready to win
- And much much more
Get your brand, product, or service the attention it needs …
[Read more]When we run a SELECT in a replica server and it returns a different result to the one we would have obtained had we queried the source server instead, due to changes in the dataset that have not yet been replicated or synchronized to the replica, we get what is known as a stale read. My colleague Marcelo has blogged about Stale Reads and How to Fix Them before.
The need to avoid stale reads is a constraint that leads people into migrating to Percona XtraDB Cluster (PXC) / Galera Cluster or, more recently, Group Replication. I am focusing on PXC and Galera in this short blog post, which, similar to Group Replication, implements not exactly a synchronous replication model but what is commonly referred to as a …
[Read more]In this blog, I explain how to recover from a replication failure caused by a corrupted relay log file.
MySQL replica stores data received from its source binary log in the relay log file. This file could be corrupted due to various reasons, mostly hardware failures. If this happens, replication will stop working, and the error log on the replica will have entries similar to:
2022-05-12T12:32:07.282374Z 2 [ERROR] Error in Log_event::read_log_event(): 'Event too small', data_len: 0, event_type: 0 2022-05-12T12:32:07.282386Z 2 [ERROR] Error reading relay log event for channel '': slave SQL thread aborted because of I/O ... 2022-05-12T12:32:07.282396Z 2 [ERROR] Slave SQL for channel '': Relay log read failure: Could not parse relay log event entry. The possible reasons are: the master's binary log is corrupted (you can check this by running 'mysqlbinlog' on the binary log), the slave's relay log is corrupted (you can check this by running …[Read more]
Usually, I receive a lot of emails, and sometimes I read them on my phone and then… I forgot about them.. (shame on me).
On my Linux desktop, I used to use Get Things Gnome for a long time, due to the declining appeal of the project and the end of the extension for Thunderbird, I found it less and less useful.
I was then looking for a solution to have my todolist accessible from everywhere and that I could manage it myself, not hosted somewhere.
I found a very nice, fast and practical project that was easy to deploy and was using MySQL as backend: myTinyTodo.
However, I was missing the possibility to easily create a new task from an email (and especially on my phone).
This is why I decided to write a script that would perform exactly what I was looking for and integrated …
[Read more]Oracle’s MySQL 8.0.29 release extended the support for ALTER TABLE … ALGORITHM=INSTANT to 1) allow users to instantly add columns in any position of the table, and 2) instantly drop columns. As part of this work, the InnoDB redo log format has changed for all DML operations on the server. This new redo log format introduced a design flaw that can cause data corruption for tables with INSTANT ADD/DROP COLUMNS.
The corruption happens when InnoDB crash recovery takes place. InnoDB applies redo logs at startup. Percona XtraBackup copies the redo log during backup and applies it as part of the –prepare step to bring the backup to a consistent state.
Percona fixed the corruption issue and several other issues with the INSTANT ADD/DROP column …
[Read more]