Hi,
I wanna calculate a time difference between real time and time on a server.
In order to do that i've created 2 items:
- system.run[/opt/stack/bin/get-time.sh] this one's gets time
- last(system.localtime)-last(system.run[/opt/stack/bin/get-time.sh]) this one calculates the difference
I want triggers to inform me if the time difference is between 5 min and hour, and second one - greater than 1h.
Trigger to it looks like this:
- 5 min to 1h:
{my_linux_t:time.sync.abschange(0)}>300 & {my_linux_t:time.sync.abschange(0)}<3600
and the other one:
{my_linux_t:time.sync.abschange(0)}>3600
Now,
Triggers go off, but the one which should go off if the diference is greater than 3600 seconds goes off at really small values (58,57, 56, 55 .....)
The other one react the opposite way: goes off after values are greater than 3500 (!) seconds.
Where did i go wrong ?
Help anyone?
Best Regards
I wanna calculate a time difference between real time and time on a server.
In order to do that i've created 2 items:
- system.run[/opt/stack/bin/get-time.sh] this one's gets time
- last(system.localtime)-last(system.run[/opt/stack/bin/get-time.sh]) this one calculates the difference
I want triggers to inform me if the time difference is between 5 min and hour, and second one - greater than 1h.
Trigger to it looks like this:
- 5 min to 1h:
{my_linux_t:time.sync.abschange(0)}>300 & {my_linux_t:time.sync.abschange(0)}<3600
and the other one:
{my_linux_t:time.sync.abschange(0)}>3600
Now,
Triggers go off, but the one which should go off if the diference is greater than 3600 seconds goes off at really small values (58,57, 56, 55 .....)
The other one react the opposite way: goes off after values are greater than 3500 (!) seconds.
Where did i go wrong ?
Help anyone?
Best Regards
Comment