Centreon: [2.8.x] Partitioning misfunction depending on row_format

Created on 11 Jul 2017  路  4Comments  路  Source: centreon/centreon


BUG REPORT INFORMATION

Centreon Web version: 2.8.9

Centreon Engine version: 1.7.2

Centreon Broker version: 3.0.8

OS: CentOS 6

Steps to reproduce the issue:

  1. Have the 4 known tables partitioned,
  2. Have one of those 4 tables with "Create_options" egale to "row_format=COMPACT partitioned",
  3. Launch the cron script "/usr/share/centreon/cron/centreon-partitioning.php".

Describe the results you received:
The script can't create new partitions for the table from point 2, as it thinks it is not partitioned, and exit.

Describe the results you expected:
New partitions for all tables.

Additional information you think important (e.g. issue happens only occasionally):
The line 414 from "/www/class/centreon-partition/partEngine.class.php" is too restrictive :
if ($row["Create_options"] != "partitioned")

Log from centreon-partitioning.php :
[Thu, 11 May 17 04:00:01 +0200] PARTITIONING STARTED
[Thu, 11 May 17 04:00:01 +0200][updateParts] Create new part : 20170521 - Range: 1495317600
[Thu, 11 May 17 04:00:01 +0200][updateParts] Create new part : 20170521 - Range: 1495317600
[Thu, 11 May 17 04:00:02 +0200] Error: cannot update non partitioned table centreon_storage.log_archive_host

Info for the table :
MariaDB [centreon_storage]> SHOW TABLE STATUS LIKE 'log_archive_host'G;
******** 1. row ********
Name: log_archive_host
Engine: InnoDB
Version: 10
Row_format: Compact
Rows: 833
Avg_row_length: 3776
Data_length: 3145728
Max_data_length: 0
Index_length: 12582912
Data_free: 0
Auto_increment: 880
Create_time: 2017-07-11 04:00:03
Update_time: NULL
Check_time: NULL
Collation: utf8_general_ci
Checksum: NULL
Create_options: row_format=COMPACT partitioned
Comment:

kinbug statuimplemented

All 4 comments

Hi,

This should be fixed by replacing 414 line by this one :

if (!preg_match("partitioned", $row["Create_options"])) {

because we can have COMPACT, DYNAMIC, COMPRESSED in addition to partitioned

Thanks

Actually you can put anything in your "create options".

@cgagnaire really ?! even "for sure" ;p

Mos def!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

anzevi picture anzevi  路  6Comments

zheddiewen picture zheddiewen  路  10Comments

GuillaumeBernard picture GuillaumeBernard  路  3Comments

benoitb21 picture benoitb21  路  6Comments

BenoitPoulet picture BenoitPoulet  路  4Comments