[ZBX-16176] Character Value Mappings for item prototypes not displayed in Latest data Created: 2019 May 27  Updated: 2024 Apr 10  Resolved: 2019 Jul 05

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Frontend (F)
Affects Version/s: 4.0.7
Fix Version/s: 4.0.11rc1, 4.2.5rc1, 4.4.0alpha1, 4.4 (plan)

Type: Problem report Priority: Trivial
Reporter: Vadims Kurmis Assignee: Andrejs Verza
Resolution: Fixed Votes: 0
Labels: character, itemprototype, valuemapping, valuemaps
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

CentOS 7


Attachments: PNG File image-2019-05-27-13-43-00-343.png     PNG File image-2019-05-27-13-44-49-661.png     PNG File image-2019-05-27-13-46-40-589.png     PNG File image-2019-05-27-13-48-39-155.png     PNG File image-2019-05-27-13-51-33-856.png    
Issue Links:
Sub-task
depends on ZBX-16279 Value mapping applied in problem name... Closed
Team: Team B
Team: Team B
Sprint: Sprint 53 (Jun 2019), Sprint 54 (Jul 2019)
Story Points: 0.125

 Description   

Steps to reproduce:

  1. Simply doesn't work. 
  2. It shows in item history correctly, when I open item from latest data.
  3. But it should show mapped representation in the Latest data item list as numeric value mapping works.

 

Result:
See screenshot...

Item Prototype configuration:

Value mapping:

How it looks wrong in Latest data:

How it looks correct in latest data item history:

 

 

See log file...
See memory dump...
Expected:
See screenshot....
See attached patch file...



 Comments   
Comment by Vadims Kurmis [ 2019 May 27 ]

How it should be (works in item history):

Comment by Vadims Kurmis [ 2019 May 27 ]

How it actually shows in Latest data item list:

Comment by Vadims Kurmis [ 2019 May 27 ]

Item prototype configuration:

Comment by Vadims Kurmis [ 2019 May 27 ]

Value mapping:

Comment by Vadims Kurmis [ 2019 May 27 ]

SNMPWalk output:

Comment by Vadims Kurmis [ 2019 May 29 ]

I submitted one more bug report: ZBX-16188

I think these two might be related.

Comment by Andrejs Verza [ 2019 Jun 17 ]

Since these facts exist simultaneously:

  1. SNMP library returning an extra space in the end of Hex-String (can be observed even in snmpget's output).
  2. Zabbix does not preprocess the received data automatically.
  3. Zabbix trims trailing spaces in mapped values to avoid confusion when spaces left unintentionally.

... Therefore it is not possible to map a value with trailing spaces. Nevertheless, this can be easily solved by simply applying a TRIM function in preprocessing rule of the item prototype.

As per situation with mapped values in History and not in the Latest data - that's a bug. Mapping should only happen for trimmed values.

Comment by Andrejs Verza [ 2019 Jun 17 ]

Resolved in development branch feature/ZBX-16176-4.0.

Comment by Andrejs Verza [ 2019 Jul 05 ]

Fixed in:

Generated at Sat Apr 20 04:00:54 EEST 2024 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.