Ad Widget

Collapse

Zabbix server migration - issue with database.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dominbdg
    Junior Member
    • Sep 2019
    • 5

    #1

    Zabbix server migration - issue with database.

    Hello,

    I have following issue and to be honest don't know what to do.
    I have zabbix server in version 4.0.4 with some mysql(mariadb) database.

    Last time we have decided to migrate zabbix on another server, so I installed debian on it, dumped ,database, installed newer version of zabbix server and imported database from this old one.
    Right now, when I'm starting zabbix server I have following issue:

    1861:20200119:134302.217 Starting Zabbix Server. Zabbix 4.4.1 (revision 8870606e6a).
    1861:20200119:134302.217 ****** Enabled features ******
    1861:20200119:134302.217 SNMP monitoring: YES
    1861:20200119:134302.217 IPMI monitoring: YES
    1861:20200119:134302.217 Web monitoring: YES
    1861:20200119:134302.218 VMware monitoring: YES
    1861:20200119:134302.218 SMTP authentication: YES
    1861:20200119:134302.218 ODBC: YES
    1861:20200119:134302.218 SSH2 support: YES
    1861:20200119:134302.218 IPv6 support: YES
    1861:20200119:134302.218 TLS support: YES
    1861:20200119:134302.218 ******************************
    1861:20200119:134302.218 using configuration file: /etc/zabbix/zabbix_server.conf
    1861:20200119:134302.238 current database version (mandatory/optional): 04010010/04010010
    1861:20200119:134302.238 required mandatory version: 04040000
    1861:20200119:134302.238 starting automatic database upgrade
    1861:20200119:134302.284 [Z3005] query failed: [1005] Can't create table `zabbix`.`host_tag` (errno: 121 "Duplicate key on write or update") [alter table `host_tag` add constraint c_host
    _tag_1 foreign key (`hostid`) references `hosts` (`hostid`) on delete cascade]
    1861:20200119:134302.284 database upgrade failed

    Please advice for help.

    Best regards.

  • exesition
    Senior Member
    • Nov 2019
    • 121

    #2
    Hi
    you had two CONTRAINTS on different tables with the same name
    Last edited by exesition; 20-01-2020, 13:00.

    Comment

    • dominbdg
      Junior Member
      • Sep 2019
      • 5

      #3
      Hi,
      Thanks for Your answer, look I'm not pretty good with mysql queries, can You tell me what can I do to resolve this issue ?

      Thanks!

      Comment

      Working...