Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-10415

Cannot update host availability after upgrade to 3.0.0

XMLWordPrintable

      I use Zabbix with Oracle DB 11.2.0.4. After upgrade from 2.4 to 3.0 the Zabbix Server started spamming messages like this into log:

       15177:20160219:104721.042 [Z3005] query failed: [-1] ORA-00911: invalid character [update hosts set disable_until=1455857301 where hostid=10896
      ;]
      

      It is caused by SQL query, which is formed in function "zbx_sql_add_host_availability" and ended by semicolon, and can be fixed by applying the following patch:

      --- zabbix-3.0.0.old/src/libs/zbxdbhigh/db.c	2016-02-15 18:25:54.000000000 +0600
      +++ zabbix-3.0.0/src/libs/zbxdbhigh/db.c	2016-02-19 11:50:14.934039842 +0600
      @@ -2654,7 +2654,7 @@
       		}
       	}
       
      -	zbx_snprintf_alloc(sql, sql_alloc, sql_offset, " where hostid=" ZBX_FS_UI64 "\n;", ha->hostid);
      +	zbx_snprintf_alloc(sql, sql_alloc, sql_offset, " where hostid=" ZBX_FS_UI64 "\n", ha->hostid);
       
       	return SUCCEED;
       }
      

            Unassigned Unassigned
            akint Anton Alekseev
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: