Ad Widget

Collapse

Once again about enable innodb_file_per_table

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • george_zabbix
    Junior Member
    • Mar 2020
    • 10

    #1

    Once again about enable innodb_file_per_table

    Immediately after installing mariaDB, even before creating the zabbix base, I want to enable the innodb_per_table parameter. To enable the innodb_per_table parameter on the Internet, there are 3 options:

    a) backup the databases (in our case, the zabbix database is not yet), delete all the databases except information_schema and mysql (in our case, only the performance_schema database should be deleted), stop mysql, delete the ib_logfile * and ibdata1 files, set the innodb_per_table = 1 parameter, run mysql, run mysql_upgrade to generate a new performance_schema database

    b) make a backup of the database, delete all databases except information_schema, performance_schema and mysql (in our case, none need to be deleted), delete the ib_logfile * and ibdata1 files, set the innodb_per_table = 1 parameter, start mysql

    c) make a backup of the database, delete all the databases, delete the ib_logfile * and ibdata1 files, set the innodb_per_table = 1 parameter, start mysql.

    Can it matter which option to act on?
    Will it affect database performance?
  • ingus.vilnis
    Senior Member
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Mar 2014
    • 908

    #2
    Hi,

    You can start by checking whether the setting is not ON by default already.
    Code:
    mysql> SELECT @@innodb_file_per_table;
    +-------------------------+
    | @@innodb_file_per_table |
    +-------------------------+
    |                       1 |
    +-------------------------+
    1 row in set (0.00 sec)
    If you still need to enable it in the config file then please do so and restart mariadb afterwards.

    Once done, import Zabbix database schema and go to the data directory of the database. You should see a file per each Zabbix table.

    Comment

    Working...