Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Michał Zegan
Thanks for the insight. W dniu 01.03.2021 o 17:34, Lennart Poettering pisze: > On Mo, 01.03.21 17:17, Michał Zegan (webczat_...@poczta.onet.pl) wrote: > >>> But this stuff is racy of course if the RTC is compiled as module and >>> you care for generic hw, that might or might not have an RTC: we

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Lennart Poettering
On Mo, 01.03.21 17:17, Michał Zegan (webczat_...@poczta.onet.pl) wrote: > > But this stuff is racy of course if the RTC is compiled as module and > > you care for generic hw, that might or might not have an RTC: we > > cannot gues swhether an RTC will show up or not in that case, > > i.e. whether

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Michał Zegan
W dniu 01.03.2021 o 17:19, Lennart Poettering pisze: > On Mo, 01.03.21 17:09, Michał Zegan (webczat_...@poczta.onet.pl) wrote: > There are problems with log timestamps when you do that, and it is probably why it was not done. I am wondering if the only correct way isn't to do it

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Lennart Poettering
On Mo, 01.03.21 17:09, Michał Zegan (webczat_...@poczta.onet.pl) wrote: > >> There are problems with log timestamps when you do that, and it is > >> probably why it was not done. > >> I am wondering if the only correct way isn't to do it in initramfs (if > >> it's systemd) before starting the

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Michał Zegan
W dniu 01.03.2021 o 16:59, Lennart Poettering pisze: > On Mo, 01.03.21 14:52, Michał Zegan (webczat_...@poczta.onet.pl) wrote: > >> Someone should really find a way to make it cooperate well with modular >> rtcs. >> It's popping up over and over and over and over again and no one is/will >>

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Michał Zegan
W dniu 01.03.2021 o 17:01, Lennart Poettering pisze: > On Mo, 01.03.21 15:38, Michał Zegan (webczat_...@poczta.onet.pl) wrote: > >> There are problems with log timestamps when you do that, and it is >> probably why it was not done. >> I am wondering if the only correct way isn't to do it in

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Lennart Poettering
On Mo, 01.03.21 15:38, Michał Zegan (webczat_...@poczta.onet.pl) wrote: > There are problems with log timestamps when you do that, and it is > probably why it was not done. > I am wondering if the only correct way isn't to do it in initramfs (if > it's systemd) before starting the journald, so

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Lennart Poettering
On Mo, 01.03.21 14:52, Michał Zegan (webczat_...@poczta.onet.pl) wrote: > Someone should really find a way to make it cooperate well with modular > rtcs. > It's popping up over and over and over and over again and no one is/will > build all rtc drivers into the kernel. To my knowledge the kernel

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Michał Zegan
There are problems with log timestamps when you do that, and it is probably why it was not done. I am wondering if the only correct way isn't to do it in initramfs (if it's systemd) before starting the journald, so that first saved logs have correct timestamps? W dniu 01.03.2021 o 15:28, Kevin P.

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Kevin P. Fleming
It's fairly simple to add a one-shot service unit to use 'hwclock' to read from the RTC and set the kernel's real-time clock. I do this on my RPis which use modules for their RTCs. On Mon, Mar 1, 2021 at 9:02 AM Michał Zegan wrote: > > Someone should really find a way to make it cooperate well

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Michał Zegan
Someone should really find a way to make it cooperate well with modular rtcs. It's popping up over and over and over and over again and no one is/will build all rtc drivers into the kernel. W dniu 01.03.2021 o 13:04, Mantas Mikulėnas pisze: > Normally I think systemd expects the kernel to do this

Re: [systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Mantas Mikulėnas
Normally I think systemd expects the kernel to do this on its own. On Mon, Mar 1, 2021, 12:31 Belisko Marek wrote: > Hi, > > I have a case when a board boots without network connection but RTC > have the correct date/time. Does systemd use RTC date/time to set > systemd time or it needs to be

[systemd-devel] use RTC date/time to set system date time

2021-03-01 Thread Belisko Marek
Hi, I have a case when a board boots without network connection but RTC have the correct date/time. Does systemd use RTC date/time to set systemd time or it needs to be done manually? Thanks and regards, marek -- as simple and primitive as possible