[Solved] [rc4.2 r4] appVM time is off

no change, Dom0 still shows the same correct time and untrusted appVM date command still shows the wrong time 5h in the past.

sys-firewall

What’s the current time in sys-firewall?

1 Like

same 5h back in time and sudo qvm-sync-clock does not help in there either

Run timedatectl inside sys-firewall then check if NTP service is “active” and if “System clock synchronized” is set to “yes”

1 Like

What’s the output of this command in sys-firewall?
sudo systemctl status systemd-timesyncd

1 Like
[user@sys-firewall ~]$ sudo timedatectl 
               Local time: Thu 2023-11-16 05:26:38 EST
           Universal time: Thu 2023-11-16 10:26:38 UTC
                 RTC time: n/a
                Time zone: America/New_York (EST, -0500)
System clock synchronized: yes
              NTP service: active
          RTC in local TZ: no

hmm never set time to NY / EST

active

● systemd-timesyncd.service - Network Time Synchronization
     Loaded: loaded (/usr/lib/systemd/system/systemd-timesyncd.service; enabled; preset: enabled)
    Drop-In: /usr/lib/systemd/system/service.d
             └─10-timeout-abort.conf
             /usr/lib/systemd/system/systemd-timesyncd.service.d
             └─30_qubes.conf
     Active: active (running) since Thu 2023-11-16 05:05:30 EST; 23min ago
       Docs: man:systemd-timesyncd.service(8)
   Main PID: 440 (systemd-timesyn)
     Status: "Contacted time server 193.136.152.72:123 (2.fedora.pool.ntp.org)."
      Tasks: 2 (limit: 494)
     Memory: 1.7M
        CPU: 44ms
     CGroup: /system.slice/systemd-timesyncd.service
             └─440 /usr/lib/systemd/systemd-timesyncd

Nov 16 05:05:30 sys-firewall systemd[1]: Starting systemd-timesyncd.service - Network Time Synchronization...
Nov 16 05:05:30 sys-firewall systemd[1]: Started systemd-timesyncd.service - Network Time Synchronization.
Nov 16 05:06:00 sys-firewall systemd-timesyncd[440]: Contacted time server 193.136.152.72:123 (2.fedora.pool.ntp.org).
Nov 16 05:06:00 sys-firewall systemd-timesyncd[440]: Initial clock synchronization to Thu 2023-11-16 05:06:00.666853 EST.

What’s the time zone in dom0 if you run sudo timedatectl there?

1 Like

localtime = 5h back
Universal / RTC = America / NY time

now how do i change the timezone in dom0 to correct local time

In dom0, run timedatectl set-timezone <TZ> where <TZ> is something from this list:

2 Likes

yeah asked AI gave same answer, worked for dom0 but getting access denied on sys-firewall

2 Likes

It’s the default when you install, and the installer don’t really have any incentive to change the default by displaying the screen. You need to click on the timezone to change it.

1 Like

If your timezone is set in dom0 (confirm it with timedatectl), then run sudo qvm-sync-clock in sys-firewall. If this doesn’t work, reboot it instead.

1 Like

so i need to fully reboot for correct time?
I’ll just reboot appVM and be back in a minute.

yes dom is now showing correct settings, the qvm-ync-clock didnt work, rebooting now

thanks guys, full reboot did it. sys-firewall and appVMs now showing correct time.

2 Likes

You should have to do this in the template to make it persistent I guess.

qubes, including templates, inherit the timezone from dom0. So there’s no need to change it in the template.

4 Likes