XMLWordPrintable

    • Icon: Incident report Incident report
    • Resolution: Won't fix
    • Icon: Trivial Trivial
    • None
    • 2.2.7
    • Server (S)
    • None
    • Ubuntu 12.04 x64
      PHP 5.3.10 (php-fpm)
      PostgreSQL 9.3.5-1

      I converted zabbix DB from mysql (MariaDB 5.5) to PostgreSQL with this toolhttps://github.com/philipsoutham/py-mysql2pgsql.
      Now:
      if i try to delete any Triggers i see the following error:

      eleted: Trigger "HTTPCode_Backend_5XX on

      {HOST.NAME}

      " on "AWS ELB CloudWatch".
      pg_query(): Query failed: ERROR: update or delete on table "triggers" violates foreign key constraint "functions_triggerid_fkey" on table "functions" DETAIL: Key (triggerid)=(14202) is still referenced from table "functions". [triggers.php:316 ? CAPIObject->delete() ? CAPIObject->__call() ? czbxrpc::call() ? czbxrpc::callAPI() ? call_user_func() ? CTrigger->delete() ? CTrigger->deleteByIds() ? CZBXAPI->deleteByIds() ? DB::delete() ? DBexecute() ? pg_query() in /usr/share/zabbix/include/db.inc.php:509]
      Error in query [DELETE FROM triggers WHERE triggerid='14202'] [ERROR: update or delete on table "triggers" violates foreign key constraint "functions_triggerid_fkey" on table "functions" DETAIL: Key (triggerid)=(14202) is still referenced from table "functions".]
      SQL statement execution has failed "DELETE FROM triggers WHERE triggerid='14202'"

      and, if i try to delete any IT Services i see the following errors:

      pg_query(): Query failed: ERROR: update or delete on table "services" violates foreign key constraint "service_alarms_serviceid_fkey" on table "service_alarms" DETAIL: Key (serviceid)=(2) is still referenced from table "service_alarms". [services.php:106 ? CAPIObject->delete() ? CAPIObject->__call() ? czbxrpc::call() ? czbxrpc::callAPI() ? call_user_func() ? CService->delete() ? DB::delete() ? DBexecute() ? pg_query() in /usr/share/zabbix/include/db.inc.php:509]
      Error in query [DELETE FROM services WHERE serviceid='2'] [ERROR: update or delete on table "services" violates foreign key constraint "service_alarms_serviceid_fkey" on table "service_alarms" DETAIL: Key (serviceid)=(2) is still referenced from table "service_alarms".]
      SQL statement execution has failed "DELETE FROM services WHERE serviceid='2'"

            Unassigned Unassigned
            DmitrySyrov Dmitry Syrov
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: