[ZBX-21681] Show Uptime in human readable time Created: 2022 Sep 22  Updated: 2025 Jul 31

Status: Confirmed
Project: ZABBIX BUGS AND ISSUES
Component/s: Documentation (D)
Affects Version/s: 6.2.2, 7.0.17, 7.4.1
Fix Version/s: None

Type: Incident report Priority: Major
Reporter: Roberto Marcelino Machado Assignee: Zabbix Development Team
Resolution: Unresolved Votes: 2
Labels: macro
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: AlmaLinux 8.6 (Sky Tiger)
CPE OS Name: cpe:/o:almalinux:almalinux:8::baseos
Kernel: Linux 4.18.0-372.26.1.el8_6.x86_64
Architecture: x86-64

PHP 7.4.19 (cli) (built: May 4 2021 11:06:37) ( NTS )
Zend Engine v3.4.0, Copyright (c) Zend Technologies
with Zend OPcache v7.4.19, Copyright (c), by Zend Technologies

64 GB memory
12 vCPU
640 GB disk

Zabbix 6.2.3 on 09/21/2022


Attachments: PNG File Screenshot 2025-07-31 at 16.37.19.png     PNG File image-2022-09-21-21-25-30-441.png     PNG File image-2022-09-21-21-29-37-259.png     PNG File image-2022-09-21-21-31-35-913.png     PNG File image-2022-11-03-08-32-36-771.png     PNG File image-2022-12-29-14-34-40-169.png     PNG File image-2023-02-02-13-38-36-615.png     PNG File image-2023-04-20-20-32-04-876.png    

 Description   

In Media Types > Email > Message templates I'm trying to return host uptime and it's not showing human readable time, only in seconds.

Uptime: {?last(//system.uptime)}

Even version 5.4 worked perfectly. It's not working in version 6.0.

 

 

Now, in version 6.2.3, uptime return wrong value.{}

 

Item values:
Name: {ITEM.NAME1}
Value: {ITEM.VALUE1}

Uptime: {?last(//system.uptime)}

 

Another error:

 

 



 Comments   
Comment by Nico Hänsel [ 2022 Sep 29 ]

For me the same Problem in Messages.... Every Item Funktion is resoved to the {item.lastvalue} Value.

 

e.g. Alarm for Printer Toner below 20%... the Value ist 19

In the Message I have something like:

Modell: {?last(/

{HOST.HOST}

/deviceModel)} -> in the Message it is not Resolve to "HP Laserjet", it is resolved as "19"... the Value of the Item that Trigger

Comment by Roberto Marcelino Machado [ 2022 Nov 03 ]

The problem persists in version 6.2.4.

 

Item values:
Name: {ITEM.NAME1}
Value: {ITEM.VALUE1}
Uptime: {?last(//system.uptime)}

Comment by Roberto Marcelino Machado [ 2022 Dec 29 ]

Same problem in version 6.2.6:

Comment by Nico Hänsel [ 2023 Jan 13 ]

Have a lock at https://support.zabbix.com/browse/ZBX-21922

Looks like the Same Problemen and should be Resolve in the next Release.

Comment by Roberto Marcelino Machado [ 2023 Feb 02 ]

Until version 5.4 the uptime value returned human readable time.

From version 6.0 it doesn't work anymore.

Now in version 6.2.7 it is returning the correct value of the parameter but it continues to show the value in milliseconds.

 

Comment by Roberto Marcelino Machado [ 2023 Apr 21 ]

Until version 5.4, the uptime value returned the human readable time.
Item values:

Name: {ITEM.NAME1}
Value: {ITEM.VALUE1}
Uptime: {?last(//system.uptime)}

In version 6.0 it didn't work anymore.

In version 6.2.7 it is returning the correct value of the parameter but it continues to show the value in milliseconds.

In version 6.4.1 the problem persists: it does not return in human readable time format.

 

Generated at Sat Aug 02 10:52:05 EEST 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.