I am using Zabbix Server and Agent 1.8.5 with PostgreSQL 8.4.7 backend database. I am trying to mass update dozens of items and encountering a lot of errors. However, sometimes my mass updates work on a set of items and other times it does not -- basically, I can't find a common thread as to why these are occurring. Here are the errors:
zabbix_server.log
postgresql.log
zabbix_server.log
ERROR: deadlock detected
DETAIL: Process 11920 waits for ShareLock on transaction 7556107; blocked by process 8618.
Process 8618 waits for ShareLock on transaction 7556087; blocked by process 11920.
Process 11920: UPDATE items SET description='Host local time',key_='system.localtime',hostid=1001000000100 63,delay=600,history=90,type=0,snmp_community='',s nmp_oid='',value_type=3,data_type=0,trapper_hosts= '',snmp_port=161,units='unixtime',multiplier=0,del ta=0,snmpv3_securityname='',snmpv3_securitylevel=0 ,snmpv3_authpassphrase='',snmpv3_privpassphrase='' ,formula='1',trends=365,logtimefmt='',valuemapid=0 ,delay_flex='',params='',ipmi_sensor='',templateid =100100000022845,authtype=0,username='',password=' ',publickey='',privatekey='' WHERE itemid=100100000025701
Process 8618: update items set lastclock=1308685473,prevvalue=lastvalue,prevorgva lue=NULL,lastvalue='99.944857' where itemid=100100000023974;
DETAIL: Process 11920 waits for ShareLock on transaction 7556107; blocked by process 8618.
Process 8618 waits for ShareLock on transaction 7556087; blocked by process 11920.
Process 11920: UPDATE items SET description='Host local time',key_='system.localtime',hostid=1001000000100 63,delay=600,history=90,type=0,snmp_community='',s nmp_oid='',value_type=3,data_type=0,trapper_hosts= '',snmp_port=161,units='unixtime',multiplier=0,del ta=0,snmpv3_securityname='',snmpv3_securitylevel=0 ,snmpv3_authpassphrase='',snmpv3_privpassphrase='' ,formula='1',trends=365,logtimefmt='',valuemapid=0 ,delay_flex='',params='',ipmi_sensor='',templateid =100100000022845,authtype=0,username='',password=' ',publickey='',privatekey='' WHERE itemid=100100000025701
Process 8618: update items set lastclock=1308685473,prevvalue=lastvalue,prevorgva lue=NULL,lastvalue='99.944857' where itemid=100100000023974;
pg_query() [<a href='function.pg-query'>function.pg-query</a>]: Query failed: ERROR: deadlock detected DETAIL: Process 32460 waits for ShareLock on transaction 7558466; blocked by process 8618. Process 8618 waits for ShareLock on transaction 7558453; blocked by process 32460. HINT: See server log for query details.[/var/www/html/zabbix/include/db.inc.php:540]
Error in query [UPDATE items SET description='Number of running processes',key_='proc.num[,,run]',hostid=100100000010156,delay=300,history=7,type= 0,snmp_community='',snmp_oid='',value_type=3,data_ type=0,trapper_hosts='',snmp_port=161,units='',mul tiplier=0,delta=0,snmpv3_securityname='',snmpv3_se curitylevel=0,snmpv3_authpassphrase='',snmpv3_priv passphrase='',formula='0',trends=365,logtimefmt='' ,valuemapid=0,delay_flex='',params='',ipmi_sensor= '',templateid=100100000022857,authtype=0,username= '',password='',publickey='',privatekey='' WHERE itemid=100100000030427] [ERROR: deadlock detected DETAIL: Process 32460 waits for ShareLock on transaction 7558466; blocked by process 8618. Process 8618 waits for ShareLock on transaction 7558453; blocked by process 32460. HINT: See server log for query details.]
pg_query() [<a href='function.pg-query'>function.pg-query</a>]: Query failed: ERROR: current transaction is aborted, commands ignored until end of transaction block[/var/www/html/zabbix/include/db.inc.php:439]
Error in query [SELECT * FROM items WHERE (itemid IN (100100000030427)) ] [ERROR: current transaction is aborted, commands ignored until end of transaction block]
pg_fetch_assoc() expects parameter 1 to be resource, boolean given[/var/www/html/zabbix/include/db.inc.php:613]
pg_free_result(): supplied argument is not a valid PostgreSQL result resource[/var/www/html/zabbix/include/db.inc.php:615]
Error in query [UPDATE items SET description='Number of running processes',key_='proc.num[,,run]',hostid=100100000010156,delay=300,history=7,type= 0,snmp_community='',snmp_oid='',value_type=3,data_ type=0,trapper_hosts='',snmp_port=161,units='',mul tiplier=0,delta=0,snmpv3_securityname='',snmpv3_se curitylevel=0,snmpv3_authpassphrase='',snmpv3_priv passphrase='',formula='0',trends=365,logtimefmt='' ,valuemapid=0,delay_flex='',params='',ipmi_sensor= '',templateid=100100000022857,authtype=0,username= '',password='',publickey='',privatekey='' WHERE itemid=100100000030427] [ERROR: deadlock detected DETAIL: Process 32460 waits for ShareLock on transaction 7558466; blocked by process 8618. Process 8618 waits for ShareLock on transaction 7558453; blocked by process 32460. HINT: See server log for query details.]
pg_query() [<a href='function.pg-query'>function.pg-query</a>]: Query failed: ERROR: current transaction is aborted, commands ignored until end of transaction block[/var/www/html/zabbix/include/db.inc.php:439]
Error in query [SELECT * FROM items WHERE (itemid IN (100100000030427)) ] [ERROR: current transaction is aborted, commands ignored until end of transaction block]
pg_fetch_assoc() expects parameter 1 to be resource, boolean given[/var/www/html/zabbix/include/db.inc.php:613]
pg_free_result(): supplied argument is not a valid PostgreSQL result resource[/var/www/html/zabbix/include/db.inc.php:615]
Comment