Book Image

MariaDB High Performance

By : Pierre Mavro
Book Image

MariaDB High Performance

By: Pierre Mavro

Overview of this book

Table of Contents (18 chapters)
MariaDB High Performance
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

DNS connections


Here is a basic option that can reduce the connection time.

Note

It's preferable to use an IP connection instead of DNS if you want to reduce latency. More than that, this will prevent your database server from going down when your DNS is down or responding slowly.

There is a configuration option that denies naming the connection that you can add to your MariaDB configuration file (my.cnf):

[mysqld]
skip_name_resolve

Before going ahead, you need to check the current configuration of your user with the allowed hostname. You need to check that no hostnames are present and check for wildcard hostnames as well:

MariaDB [(none)]> SELECT USER,HOST FROM mysql.user;
+------------------+-----------+
| USER             | HOST      |
+------------------+-----------+
| root             | 127.0.0.1 |
| root             | ::1       |
| debian-sys-maint | localhost |
| root             | localhost |
| root             | mariadb   |
+------------------+-----------+

In the HOST table, only...