How to set/sync NTP time in iMX7d Linux

Hi,
I am using iMX7d 1GB Colibri EVL board, have usb WiFi module to connect to network/internet.
I want to initialize/sync network time as soon as it boots up, could you please help me on this?

Thank You

HI @jaski.tx ,
Thank you for your reply.
“If internet connection is provided, the systemd-timesyncd service will automatically synchronize the local system clock with a remote Network Time Protocol server and the systemd-timedated service will make sure the new system clock is synchronized with the hardware clock (RTC) immediately.”

by default, time is sync with NTP in has internet.

  1. Is there anyway I can change the time-zone?
  2. Is there any issue if I don’t use RTC (chip) in my actual design and rely on NTP (default mode)?

HI @neeraj.verma

Is there anyway I can change the time-zone?

Sure, please have a look here.

Is there any issue if I don’t use RTC (chip) in my actual design and rely on NTP (default mode)?

If you have network connection, then you can rely on NTP time and don’t need RTC.

Best regards,
Jaski

Thank you @jaski.tx
It works for me.

root@colibri-imx7-emmc:~# timedatectl
      Local time: Wed 2019-10-02 20:50:32 UTC
  Universal time: Wed 2019-10-02 20:50:32 UTC
        RTC time: Wed 2019-10-02 20:50:33
       Time zone: Universal (UTC, +0000)
 Network time on: yes
NTP synchronized: yes
 RTC in local TZ: no
root@colibri-imx7-emmc:~# timedatectl set-timezone "America/Los_Angeles"
root@colibri-imx7-emmc:~# timedatectl
      Local time: Wed 2019-10-02 13:50:49 PDT
  Universal time: Wed 2019-10-02 20:50:49 UTC
        RTC time: Wed 2019-10-02 20:50:51
       Time zone: America/Los_Angeles (PDT, -0700)
 Network time on: yes
NTP synchronized: yes
 RTC in local TZ: no

HI @neeraj.verma

Could you have a look here?

Thanks and best regards,
Jaski

Perfect that it works. Thanks for the feedback.