Configuring your database for performance

Runtime metrics collection and the sample analytics pipeline provide support for MariaDB and MySQL. You can configure your MariaDB or MySQL database for optimal database performance.

Before you begin

Ensure that you have the required software installed. For more information about the supported versions of MariaDB and MySQL, see the runtime metrics collection entry in Optional z/TPF and z/TPFDF product software.

Procedure

  • If you want to configure MariaDB for performance, complete the following steps:
    1. Update the MariaDB configuration file (my.cnf) to configure MariaDB for your system. For more information, see the Start of changetpf_sap/tpf_files/tpf_db/mariadb.cnfEnd of change file that is provided in the sample analytics pipeline.
      Notes:
      • Start of changeIf you do not use the tpf_sap/tpf_files/tpf_db/mariadb.cnf file, review the settings in the mariadb.cnf file against your database settings. In particular, the innodb_buffer_pool_size setting must be set appropriately or the database might experience adverse performance. For more information, see InnoDB Buffer Pool on the MariaDB website.End of change
      • If you want to capture results over long periods of time by using real-time runtime metrics collection, disable or limit the size of the MariaDB binary log. The MariaDB binary log records all updates to the database in a set of files on your hard drive. If the MariaDB binary log is not limited in size when collection is running and real-time runtime metrics collection is analyzing name-value pair collection results, the log will eventually consume all hard drive space in your Linux® environment and cause various components to fail. For more information about the MariaDB binary log, see Overview of the Binary Log.
    2. Configure your instance of MariaDB for performance.
  • If you want to configure MySQL for performance, complete the following steps:
    1. Update the MySQL configuration file (my.cnf) to configure MySQL for your system. For more information, see the Start of changetpf_sap/tpf_files/tpf_db/mysql.cnfEnd of change file that is provided in the sample analytics pipeline.
      Notes:
      • Start of changeIf you do not use the tpf_sap/tpf_files/tpf_db/mysql.cnf  file, review the settings in the mysql.cnf file against your database settings. In particular, the innodb_buffer_pool_size setting must be set appropriately or the database might experience adverse performance. For more information, see InnoDB Buffer Pool Configuration on the MySQL website.End of change
      • If you want to capture results over long periods of time by using real-time runtime metrics collection, disable or limit the size of the MySQL binary log. The MySQL binary log records all updates to the database in a set of files on your hard drive. If the MySQL binary log is not limited in size when collection is running and real-time runtime metrics collection is analyzing name-value pair collection results, the log will eventually consume all hard drive space in your Linux environment and cause various components to fail. For more information about the MySQL binary log, see The Binary Log.
    2. Configure your instance of MySQL for performance.