[systemd-devel] How to get notification when time changes

Lennart Poettering lennart at poettering.net
Tue Jan 23 13:36:32 UTC 2018


On Di, 23.01.18 16:40, prashantkumar dhotre (prashantkumardhotre at gmail.com) wrote:

> Hi
> When time changes in system , I see
> "systemd[1]: Time has been changed" journal log. From systemd,
> Is there a way for my app to get notification about this time change event ?

Use the timerfd interface for that. See timerfd_create(2) for that,
you are looking for the TFD_TIMER_CANCEL_ON_SET flag.

Lennart

-- 
Lennart Poettering, Red Hat


More information about the systemd-devel mailing list