Trying to upgrade a fresh install of Zabbix Proxy.
DB upgrade fail at patch 2050055 with following error:
16066:20160212:164604.982 query [txnlev:1] [begin;] 16066:20160212:164604.983 query [txnlev:1] [alter table opinventory add constraint c_opinventory_1 foreign key (operationid) references operations (operationid) on delete cascade] 16066:20160212:164605.003 query [txnlev:1] [update dbversion set mandatory=2050054,optional=2050054] 16066:20160212:164605.004 query [txnlev:1] [commit;] 16066:20160212:164605.004 completed 38% of database upgrade 16066:20160212:164605.004 query [txnlev:1] [begin;] 16066:20160212:164605.004 query [txnlev:1] [select severity_color_0,severity_color_1,severity_color_2,severity_color_3,severity_color_4,severity_color_5 from config] 16066:20160212:164605.005 query [txnlev:1] [rollback;] 16066:20160212:164605.005 database upgrade failed 16066:20160212:164605.005 End of DBcheck_version():FAIL
From what I understand from DBpatch_2050055 function in file src/libs/zbxdbupgrade/dbupgrade_2050.c, my guess is that the select on line 501 returns no results.
The funtion exists at line 507 with default ret value, which is FAIL.
If no row returned, ret should be set to SUCCEED