Create a XFS filesystem using LVM

In this blog post, I will demonstrate how to use LVM to create flexible XFS filesystems where it allows us to extend or reduce its size without disrupting services. Instructions Let’s initiate installing LVM: [crayon-5f0a705e652da508587194/] Next, the disk should be already attached to the instance, and we can verify with fdisk…

Stop Fake News! The most common fake news about MySQL (contains bad language)

Since I have been working with MySQL, I saw a lot of comments about the MySQL ecosystem, which, if they are not made in a bad intention to sell commercial software, they lack a lot of fundamentals and knowledge about its behavior. Like a mantra in my life, researching the…

Toss a coin to your DBA: Estimate MySQL Redo Log Size

Having a right REDO log size is fundamental for MySQL to run smoothly without struggling. An undersized REDO can even lead to errors in operations! For example, this week, a friend of mine reported this error: [crayon-5f0a705e68cae919641745/] This is because MySQL was using the default value for the innodb_log_file_size, which…

Install Valgrind

This post is intended to demonstrate how to install Valgrind in a Centos/Red Hat and Debian/Ubuntu environment. Valgrind is a programming tool for memory debugging, memory leak detection, and profiling.  The yum Method It is the quickest and simpler way. Valgrind is part of the base/7/x86_64 repository, which comes by default. The command…

Linux OS error codes

The list below provides the operating system error codes that commonly happens in the MySQL ecosystem. For example: Another alternative is the use of the perror tool to find the error message which is associated with a given error code. Number Error Code Description 1 EPERM Operation not permitted 2 ENOENT No…

Top 7 Linux Optimizations For MySQL

That’s all. Like a cake recipe. The DBA and sysadmin dream. You don’t think, you can just apply. Here are the 7 crushing tips for basic OS tunning: Swappiness The swappiness parameter controls the behavior of the operating system in the swap area. Swap is the process of sending memory…

Monitor MySQL Memory Usage – Part 2 (Valgrind)

So, today, continuing with memory analysis I will present the Valgrind tool. Valgrind programming tool provides information for memory debugging, memory leak detection, and profiling. It is useful for cases where you suspect that MySQL memory is increasing or simply it is using too much memory given the parameters that…

Upgrade MongoDB/PSMDB Standalone 3.4 to 3.6

In this blog post, I will share the necessary steps for a smooth upgrade from MongoDB (or Percona Server MongoDB) standalone version 3.4 to 3.6. I have plans to publish new versions for sharding and replica-set too. For now, let’s stick with the steps for the standalone. Upgrade Recommendations and…

Monitor MySQL memory usage – Part 1 (Performance Schema)

On my day-to-day activities, one of the most classic cases that I get is: I think that my database has a memory leak. Where MySQL is spending so much memory? So, saying that, I intend to launch a blog post series that might help tackle this issue. For those who…

MySQL built-in function x user-defined function performance

In this article, I’m going to cover the use of built-in functions. The idea is to use the functions that MySQL has available instead of making custom functions (aka user-defined functions). If they do the same thing, why use MySQL functions instead of my own custom made functions? The answer…