Ad Widget

Collapse

Why alertid field is not set as auto_increment

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Ming Li
    Junior Member
    • Feb 2017
    • 4

    #1

    Why alertid field is not set as auto_increment

    Hello,

    alertid field is not set as AUTO_INCREMENT, and Zabbix server will handle to increment its value when inserting table 'alerts'. But in MariaDB master-master replication mode, two different nodes might trigger inserting alerts table at the same time, it will cause table writing failure because of duplicate key value.

    Can we change this field to be AUTO_INCREMENT so that MariaDB can set the unique value when inserting one record?

    Ming Li
Working...