Zabbix server does not sync the history caches concering items with trigger(s) on shutdown.
Situation is following
1. DB Syncer process starts to sync
1.1 It locks triggers on DCconfig_lock_triggers_by_itemids()
2. Parent process receives the SIGTERM and sends SIGTERM to all children
3. DB Syncer terminates without releasing trigger locks
4. Parent process start full-sync
4.1 find the trigger locks and unlist its item
4.2 terminates without sync
So, I attached the fixed patch to escape to find locks on Parent process.
There is no problem because Parent Process syncs only on shutdown.