[ZBX-15089] Zabbix Agent Configuration -- Alias not allowed range Created: 2018 Oct 30  Updated: 2018 Nov 01  Resolved: 2018 Oct 30

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Agent (G)
Affects Version/s: 4.0 (plan)
Fix Version/s: None

Type: Problem report Priority: Trivial
Reporter: guwenbo Assignee: Vladislavs Sokurenko
Resolution: Won't fix Votes: 0
Labels: agent
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

Hello , 

 

I`m a user of Zabbix. I found a bug while I was configuring my agent. The "Alias" item is not allowed to use regex range?

 

Here is my sample :

 

Zabbix_agent.conf:

 

Alias=zabbix.userid:vfs.file.regexp[/etc/passwd,^zabbix:.[0-9]+),,,,\1]

 

Then I started my agentd , and it reported an issue,

 

zabbix_agentd [12369]: ERROR: cannot add alias "zabbix.userid:vfs.file.regexp[/etc/passwd,^zabbix:.[0-9]+),,,,\1]": invalid character at position 59

 

But after I modified the [0-9] to \d , it works.

 

Alias=zabbix.userid:vfs.file.regexp[/etc/passwd,^zabbix:.:(\d+),,,,\1]

 

Is that an issue ?

 

 



 Comments   
Comment by Vladislavs Sokurenko [ 2018 Oct 30 ]

Does this help ?

Alias=zabbix.userid:vfs.file.regexp[/etc/passwd,"^zabbix:.:([0-9]+)",,,,\1]

Parameter - unquoted string

If the key parameter is an unquoted string, any Unicode character is allowed except comma and right square bracket (]). Unquoted parameter cannot start with left square bracket ([).

More info:
https://www.zabbix.com/documentation/3.4/manual/config/items/item/key

Comment by Vladislavs Sokurenko [ 2018 Oct 30 ]

Thank you for your report, closing as Won't fix as there is no indication of a bug.

Comment by guwenbo [ 2018 Nov 01 ]

Thanks for your help. It works.

Generated at Sat Apr 27 04:51:50 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.