-
Type:
Problem report
-
Resolution: Duplicate
-
Priority:
Trivial
-
None
-
Affects Version/s: 7.0.22, 7.4.5
-
Component/s: Frontend (F)
-
None
Triggers created from trigger prototypes prevent unlinking and clearing the template, if the trigger prototype is depending on a master trigger from the template.
Host H
Template T
Trigger parent
Trigger prototype proto depending on parent
T linked to H
During LLD, triggers are created on H:
Trigger proto_instance (created from proto)
When trying to "unlink and clear" T from H, an error is raised that it cannot be unlinked since proto_instance are depending on proto.
Steps to reproduce:
- Clone default Zabbix template "Linux by Zabbix agent" to "Linux by Zabbix agent - clone 1"
- Under dicovery rule "Network interface discovery" , change Trigger "Linux: Interface {#IFNAME}: Link down" , under trigger Dependencies , set it depend on trigger "Linux: Zabbix agent is not available"
- Add template to a test host (lucky)
- Wait until data comes in , discovery rule process data and creates trigger prototypes
- Make sure that Trigger prototype is created and depends on "Linux: Zabbix agent is not available"
- Edit host , choose template "Linux by Zabbix agent - clone 1" do click "Unlink and clear" , when click "Update" button on host , get error message
- Get error message "Cannot update host"
Cannot unlink template "Linux by Zabbix agent - clone 1" from host "lucky" due to dependency of trigger "Linux: Interface eth0: Link down". [zabbix.php:17 → require_once() → ZBase->run() → ZBase->processRequest() → CController->run() → CControllerHostUpdate->doAction() → CApiWrapper->__call() → CFrontendApiWrapper->callMethod() → CApiWrapper->callMethod() → CFrontendApiWrapper->callClientMethod() → CLocalApiClient->callMethod() → CHost->update() → CHost->validateUpdate() → CHostBase->checkTemplatesLinks() → CHostBase->checkTriggerDependenciesOfHostTriggers() → CApiService::exception() in include/classes/api/services/CHostBase.php:401]
Result:
Error message is shown,Template is not unlinked.
Attached screenshot 
Expected:
Expected template to unlink and clear data
Workaround:
Remove dependency in template trigger prototype
Execute Network discovery rule
Make sure trigger does not depend on "Linux: Zabbix agent is not available" anymore under Data Collection->Host->test_host->Triggers
Unlink and clear
Notes
Tested on versions 7.0.22 and 7.4.5.
Same problem appears on 7.4.5 , but slightly different message
"Cannot update host"
Cannot unlink template "Linux by Zabbix agent - clone 2" from host "h1" due to dependency of trigger "Linux: Interface eth0: Link down".
Screenshot attached:

- causes
-
ZBX-27424 Templates cannot be unlinked and cleared from hosts if trigger prototype in template depend on trigger in same template
-
- Closed
-