satu

Gajah mati meninggalkan tulang
harimau mati meninggalkan belang
manusia mati meninggalkan nama

persiapkan klu kalian mati ingin meninggalkan apa ?

Friday, 28 December 2018

alter table zabbix database

sumber : https://support.zabbix.com/browse/ZBX-13789

Hi,

I have done some tunning on the database by adding few indexes :

ALTER TABLE `zabbix`.`problem` DROP INDEX `Test`, ADD INDEX `Test` (`source`,`object`, `r_eventid`) USING BTREE;

ALTER TABLE `zabbix`.`rights` DROP INDEX `Test`, ADD INDEX `Test` (`id`,`groupid`) USING BTREE;



ALTER TABLE `zabbix`.`hosts_groups` DROP INDEX `Test`, ADD UNIQUE `Test`(`groupid`, `hostid`) USING BTREE;

ALTER TABLE `zabbix`.`triggers` DROP INDEX `Test`, ADD INDEX `Test`(`triggerid`, `priority`) USING BTREE;

those indexes + removing the DIstinct from the SQL request make the requests working like a charm on the database, and I have no more the issue on mysql.


ALTER TABLE `event_recovery` ADD INDEX `event_recovery_idx_eventid_eventid` (`eventid`,`r_eventid`);
ALTER TABLE `events` ADD INDEX `events_idx_source_object_object_value_eventi` (`source`,`object`,`objectid`,`value`,`eventid`);

No comments:

Post a Comment