[ZBX-6062] Triggers containing system.run items with "||" characters in command are not editable in expression constructor + can not change trigger contents in text mode: parsing error; Created: 2013 Jan 04  Updated: 2017 May 30  Resolved: 2013 Jan 04

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Frontend (F)
Affects Version/s: 2.0.4
Fix Version/s: 2.0.5rc1

Type: Incident report Priority: Critical
Reporter: Leonid Satanovsky Assignee: Unassigned
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

2.0.4 is affected.
earlier versions are not.


Attachments: JPEG File zbx-trigger-expression.jpg    
Issue Links:
Duplicate
is duplicated by ZBX-6061 triggers containing system.run items ... Closed

 Description   

Triggers containing system.run items with "||" characters in command are not editable in expression constructor + can not change trigger contents in text mode: parsing error;

Trigger expression example:

============

{-- Tpl_Condor_Grid_worker_node:system.run["file=/net/$(hostname -f)/local_disk/zabbix.test; touch $file ||

{ echo 1; exit 1; }

; rm $file; echo 0;"].last(1000)}=1 |
{-- Tpl_Condor_Grid_worker_node:system.run["for mp in /sw /home /tools /tools/local; do ( 2> /dev/null mount | grep -E 'nfs|bind' | grep $mp > /dev/null && ls -l $mp/ > /dev/null ) ||

{ echo 1 && exit; }

; done; echo 0"].last(1000)}=1 |
{-- Tpl_Condor_Grid_worker_node:vfs.fs.size[/local_disk,free].last(1000)}<5000000000 |
{-- Tpl_Condor_Grid_worker_node:system.run["( exec > /dev/null 2>&1 /usr/bin/env condor_q ) ||

{ echo 1; exit; }

; echo 0"].last(1000)}=1 |
{-- Tpl_Condor_Grid_worker_node:custom.grid.condor.worker.swapped_to_available_prop.last(600)}>3 |
{-- Tpl_Condor_Grid_worker_node:custom.grid.condor.worker.cpu.cores_putil.avg(600)}>195 |
{-- Tpl_Condor_Grid_worker_node:ssh.run["Condor worker, IO: Reported I/O errors"].iregexp(err,60)}=1

============

2.0.3 has no troubles with it, so, the issue was introduced in 2.0.4



 Comments   
Comment by Leonid Satanovsky [ 2013 Jan 04 ]

UPD:
Editing in text mode works.
The problem is only related to expression constructor mode.

Comment by richlv [ 2013 Jan 04 ]

reproducible in 2.0.4, not reproducible in 2.0 branch svn head - this was fixed in revision 31993

Generated at Tue Apr 08 04:25:13 EEST 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.