Showing entries 1 to 10 of 43406
10 Older Entries »
Using MySQL Offline Mode To Disconnect All Client Connections

As a DBA, one of the very frequent tasks is to stop/start MySQL service for batching or some other activities. Before stopping MySQL, we may need to check if there are any active connections; if there are, we may need to kill all those. Generally, we use pt-kill to kill the application connections or prepare kill statements using the select queries.

Example commands:

pt-kill --host=192.168.11.11 --user=percona -p --sentinel /tmp/pt-kill.sentinel2 --pid /tmp/pt-kill.pid  --victims all --match-command 'Query' --ignore-user 'pmm|rdsadmin|system_user|percona' --busy-time 10 --verbose --print --kill 

select concat('kill ',id,';') from information_schema.processlist where user='app_user';

MySQL has a variable called offline_mode to set the server into maintenance mode. When you set this, it immediately disconnects all the client connections that don’t …

[Read more]
How to Upload MySQL Backup Files to FTP or Free File Hosting Services

Discover the best practices for creating secure MySQL backups and uploading them to FTP or popular free file hosting services like Fex.net, Fastupload.io, MEGA, Google Drive, and Easyupload.io. Protect your data with our comprehensive guide.

The post How to Upload MySQL Backup Files to FTP or Free File Hosting Services appeared first on Devart Blog.

MySQL HeatWave Lakehouse on AWS

MySQL HeatWave Lakehouse is now available on AWS, enabling AWS customers to run transaction processing, real-time analytics across data warehouses and data lakes, and machine learning in one cloud database service. They can replace five AWS services with one, reducing complexity and obtaining the best price-performance in the industry for analytics.

How to copy a MySQL instance ?

Learn how to copy a MySQL instance to another server or to the cloud.

How to copy a MySQL instance ?

To copy a MySQL server to another server or to the cloud, there are several ways.

We can distinguish between two different types of copy:

  • physical copy
  • logical copy

The physical copy is often the fastest. However, it requires some tools to ensure that you have a consistent online backup. For example, you can use MySQL Enterprise Backup (MEB).

Alternatively, it’s possible to use the CLONE plug-in to provision a new instance with existing data from a source server. This is my preferred approach.

Finally, the last physical solution is the use of a file system snapshot, but this requires the right infrastructure and even more care to have a consistent …

[Read more]
Don’t Start Using Your MySQL Server Until You’ve Configured Your OS

Whenever you install your favorite MySQL server on a freshly created Ubuntu instance, you start by updating the configuration for MySQL, such as configuring buffer pool, changing the default datadir director, and disabling one of the most outstanding features – query cache. It’s a nice thing to do, but first things first. Let’s review the best practices we usually follow in Managed Services before using your MySQL server in production and stage env, even for home play purposes.

Memory

Our usual recommendation is to use specific memory parameters, which we suggest to ensure optimal performance.

  • To prevent out-of-memory (OOM) episodes, the OOM Score has to be set to -800.
  • vm.swappiness = 1
  • Disable Transparent Huge Pages
  • Install and enable jemalloc. Let’s briefly go through each setting to understand why adjustments are needed. Afterward, we will see how to configure these …
[Read more]
How to scale your database and when to shard MySQL

Not sure when to shard your MySQL database? This article covers when you should consider horizontal sharding as a scaling strategy in MySQL and some other scaling options before then.

Developer Interview with Wendell Adriel – OpenLampTech Repost

OpenLampTech continues to publish great content for the PHP, MySQL, LAMP stack, and open-source communities. This week, I (am resharing) have another awesome text-based developer interview for you with Wendell Adriel. Thanks for reading!

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.

Visit and read Wendell’s fantastic interview here: https://openlamptech.substack.com/p/openlamptech-developer-interview-18d

If you’re not already …

[Read more]
MySQL 8.0 INSTANT ADD and DROP Column(s) - 2

This is the second blog in the series where I talk about INSTANT ADD/DROP columns feature introduced in MySQL 8.0. After the introductory Blog, this blog aims to provide more design details.

The MySQL Clone Plugin Is Not Your Backup

This blog post discusses the limitations of the MySQL Clone plugin.

The MySQL clone plugin significantly simplifies the process of replica provisioning. All you need to do is:

  • Ensure that the source server has binary logs enabled
  • Grant appropriate permissions
  • Execute the CLONE INSTANCE  command on the recipient

This works extremely easily when you provision a new replica that doesn’t have any data.

Due to its simplicity, you may want to use the clone plugin instead of a backup to restore a server that survives data inconsistency or corruption. E.g., after crash.

However, if you have data on your replica, you need to consider how you will recover if the CLONE INSTANCE  command fails with an error.

CLONE INSTANCE  command, by default, works as follows:

  • Checks prerequisites on the replica
  • Wipes out data …
[Read more]
Showing entries 1 to 10 of 43406
10 Older Entries »