Showing entries 211 to 220 of 287
« 10 Newer Entries | 10 Older Entries »
Displaying posts with tag: 8.0 (reset)
sysbench for MySQL 8.0

Alexey made this amazing tool that the majority of MySQL DBAs are using, but if you use sysbench provided with your GNU/Linux distribution or its repository on packagecloud.io you won’t be able to use it with the new default authentication plugin in MySQL 8.0 (caching_sha2_password).

This is because most of the sysbench binaries are compiled with the MySQL 5.7 client library or MariaDB ones. There is an issue on github where Alexey explains this.

So if you want to use sysbench with MySQL 8.0 …

[Read more]
MySQL: size of your tables – tricks and tips

Many of you already know how to retrieve the size of your dataset, schemas and tables in MySQL.

To summarize, below are the different queries you can run:

Dataset Size

I the past I was using something like this :

But now with sys schema being installed by default, I encourage you to use some of the formatting functions provided with it. The query to calculate the dataset is now:

SELECT sys.format_bytes(sum(data_length)) DATA,
       sys.format_bytes(sum(index_length)) INDEXES,
       sys.format_bytes(sum(data_length + index_length)) 'TOTAL SIZE'
FROM information_schema.TABLES ORDER  BY data_length + index_length;

Let’s see an example:

[Read more]
How to know if a user never connected to the MySQL server since last boot ?

Performance_Schema is used most of the time to get metrics about queries and connections. But it can also provide other very useful information.

So today, I will show you how you can see a list of users that didn’t connect to MySQL since we restarted it (since last reboot).

SELECT DISTINCT mu.user FROM mysql.user mu
LEFT JOIN performance_schema.users psu
ON mu.user = psu.user
WHERE psu.user IS NULL
AND mu.user NOT IN ('mysql.infoschema', 'mysql.session', 'mysql.sys')
ORDER BY mu.user;

Example:

mysql> SELECT DISTINCT mu.user FROM mysql.user mu
    ->       LEFT JOIN performance_schema.users psu 
    ->       ON mu.user = psu.user  
    ->       AND mu.user NOT IN ('mysql.infoschema', 'mysql.session', 'mysql.sys')
    -> …
[Read more]
MySQL InnoDB Cluster: upgrade from 8.0.11 to 8.0.12

In April, I already posted an article on how to upgrade safely your MySQL InnoDB Cluster, let’s review this procedure now that MySQL 8.0.12 is out.

To upgrade all the members of a MySQL InnoDB Cluster (Group), you need to keep in mind the following points:

  • upgrade all the nodes one by one
  • always end by the Primary Master in case of Single Primary Mode
  • after upgrading the binaries don’t forget to start MySQL without starting Group Replication (group_replication_start_on_boot=0)
  • to run mysql_upgrade

Let’s see this in action on the video below:

As you could see, this is quick and easy.

[Read more]
MySQL InnoDB Cluster 8.0.12 – avoid old reads on partitioned members

We received feedback about how a member should act when leaving the group. And the majority of users wanted that when a node drops out of the group, it should kill all connections and shutdown. I totally agree with that behavior and it’s now the default in MySQL 8.0.12.

This new feature is explained in WL#11568.

Before this change, the server goes into super read only mode when dropping out of the group and allows users connected to this server or new connections (if you don’t use the router) to read old data.

Let’s check this out in the following video:

So now in MySQL 8.0.12, there is a mnew option called …

[Read more]
MySQL at Oracle Open World and Oracle Code One Oct 22-25 2018 !

This year again, the MySQL Team is eager to participate in the Oracle Open World conference. This is a great opportunity for our engineers and the entire MySQL Team to highlight what we’ve done, and also what we are working on. Another reason to be excited this year is our new participation to Code One, the Oracle developer focused conference. Oracle Code One will include a full track dedicated to MySQL.

This is very good news for everybody attending, from DBAs to developers, as we will offer even more great content ! This year, in both events, we will highlight how NoSQL+SQL=MySQL.

Our MySQL Engineers will deliver fantastic sessions about …

[Read more]
PHP 7.2.8 & MySQL 8.0

A good news for all PHP CMS users like Drupal and Joomla!, PHP 7.2.8 (available on Remi’s repo for those using rpms) supports the new MySQL 8.0 default authentication plugincaching_sha2_password‘ !

So, I’ve installed PHP 7.2.8:

And I’ve my user (here joomla) uses the …

[Read more]
Joomla! and MySQL 8.0.12

As other CMS using MySQL and PHP, Joomla! is not yet 100% ready to work with MySQL 8.0 out of the box.

I’ve been contacted by Brian Teeman to give my opinion and some tips… so here is the blog post

@lefred If you could offer some advice on this #joomla #mysql 8 issue it would be appreciated https://t.co/FS37GVunEO

— ((( Brian Teeman ))) (@brianteeman) …

[Read more]
MySQL Router HA with Keepalived

After having explained how to achieve HA for MySQL Router for people who doesn’t want to install the MySQL Router on the application servers and after having illustrated how to use Pacemaker, this article explains how to setup HA for MySQL Router using keepalived.

Keepalived is very popular, maybe because it’s also very easy to use. We can of course use 2 or more servers. The principle is the same as on the previous articles, if the router dies, the virtual IP used by the application server(s) to connect to MySQL is sent to another machine where mysqlrouter is still running.

Let’s have a look at the configuration, in this case we use 2 machines, mysql1 and …

[Read more]
MySQL Router HA with Pacemaker

This article will explain how to setup HA for MySQL Router as described in a previous article about where should the router stand.

For this setup, I will use Pacemaker (part of RedHat High Availability Add-on and available on RHEL, CentOS, Oracle Linux, …).

Of course we need a MySQL InnoDB Cluster but we won’t really use it for the HA setup of the MySQL Router.

Installing Pacemaker

The first step is to install pacemaker on all the machines we will use for our “MySQL Router Cluster”:

# yum install pacemaker pcs resource-agents

Now we need to start the pcsd service and enable it at boot (on all machines):

# systemctl start pcsd.service 
# systemctl enable pcsd.service

It’s time now to setup authentication, this operation is again …

[Read more]
Showing entries 211 to 220 of 287
« 10 Newer Entries | 10 Older Entries »