Getting wrong day by ntpd (my fault)

Hello,

I found that time set by ntp is wrong.
I think just starting from today (Saturday September 14) ...

Since my router running OpenWrt 22.03.3 provides a local ntp server every device in my local network shows wrong time.
To be exact. Time is ok, but just a day behind.

Here is how to verify

Show current date:

root@R2S:~# date                                                                                                                                                                                                                        
Fri Sep 13 17:07:35 CEST 2024                                                                                                                                                                                                            

Set correct day and a little different time, to see what is happening

root@R2S:~# date -s "2024-09-14 17:00"                                                                                                                                                                                                  
Sat Sep 14 17:00:00 CEST 2024                                                                                                                                                                                                            

Get time by ntpd

root@R2S:~# ntpd -dnq -p ptbtime1.ptb.de                                                                                                                                                                                                
ntpd: 'ptbtime1.ptb.de' is 2001:638:610:be01::108                                                                                                                                                                                        
ntpd: sending query to 2001:638:610:be01::108                                                                                                                                                                                            
ntpd: reply from 2001:638:610:be01::108: offset:-85921.968746 delay:0.015222 status:0x24 strat:1 refid:0x30505450 rootdelay:0.000107 reach:0x01                                                                                          
ntpd: sending query to 2001:638:610:be01::108                                                                                                                                                                                            
ntpd: reply from 2001:638:610:be01::108: offset:-85921.969863 delay:0.013143 status:0x24 strat:1 refid:0x30505450 rootdelay:0.000107 reach:0x03                                                                                          
ntpd: setting time to 2024-09-13 17:08:10.212394 (offset -85921.969863s)

Bad. Time is correct, but day is wrong again...
Tested with some different ntp servers. Got same result..

In my part of the world (Europe) it is Friday the 13th at the moment I post

1 Like

We have a time traveller :slight_smile:
How comes it's already September 14 for you?
The EU timeserver shows the correct time and day.

Ok,
you are correct. Of course.

Since I'm retired I have lost any feeling for date and time.
And my wife drives me crazy too :wink:

You are using a version that is EOL and unsupported. Have you tried upgrading to 23.05?

Yes I have tried to update.
But "attended sysupgrade" did not work out of the box ....

Error building the firmware image
Server response: Error: Impossible package selection

Request Data:

{
    "url": "https://sysupgrade.openwrt.org",
    "revision": "r20028-43d71ad93e",
    "advanced_mode": "1",
    "branch": "22.03",
    "efi": null,
    "profile": "friendlyarm,nanopi-r2s",
    "target": "rockchip/armv8",
    "version": "23.05.4",
    "packages": [
        "base-files",
        "block-mount",
        "busybox",
        "ca-bundle",
        "cgi-io",
        "collectd-mod-thermal",
        "comgt",
        "dmesg",
        "dnsmasq",
        "dropbear",
        "dropbearconvert",
        "e2fsprogs",
        "fdisk",
        "firewall",
        "fstools",
        "fwtool",
        "getrandom",
        "gpioctl-sysfs",
        "hub-ctrl",
        "iconv",
        "ip6tables-nft",
        "iperf3",
        "iptables-nft",
        "jshn",
        "jsonfilter",
        "kernel",
        "kmod-fs-exfat",
        "kmod-fs-ext4",
        "kmod-fs-vfat",
        "kmod-gpio-button-hotplug",
        "kmod-ip6tables",
        "kmod-ipt-conntrack",
        "kmod-ipt-core",
        "kmod-ipt-nat",
        "kmod-ipt-offload",
        "kmod-lib-crc-ccitt",
        "kmod-lp",
        "kmod-nf-conntrack",
        "kmod-nf-conntrack6",
        "kmod-nf-flow",
        "kmod-nf-ipt",
        "kmod-nf-ipt6",
        "kmod-nf-nat",
        "kmod-nf-reject",
        "kmod-nf-reject6",
        "kmod-ppp",
        "kmod-pppoe",
        "kmod-pppox",
        "kmod-slhc",
        "kmod-usb-net-cdc-ether",
        "kmod-usb-net-rtl8152",
        "kmod-usb-printer",
        "kmod-usb-serial-option",
        "kmod-usb-storage",
        "kmod-usb2",
        "kmod-usb3",
        "libblkid",
        "libblobmsg-json",
        "libc",
        "libcomerr",
        "libext2fs",
        "libf2fs",
        "libip4tc",
        "libip6tc",
        "libiwinfo",
        "libiwinfo-data",
        "libiwinfo-lua",
        "libjson-c",
        "libjson-script",
        "liblua",
        "liblucihttp",
        "liblucihttp-lua",
        "libnl-tiny",
        "libsmartcols",
        "libss",
        "libubox",
        "libubus",
        "libubus-lua",
        "libuci",
        "libuclient",
        "libustream-wolfssl",
        "libuuid",
        "libwolfssl",
        "libxtables",
        "logd",
        "lua",
        "luci",
        "luci-app-adblock",
        "luci-app-attendedsysupgrade",
        "luci-app-commands",
        "luci-app-ddns",
        "luci-app-firewall",
        "luci-app-opkg",
        "luci-app-p910nd",
        "luci-app-squid",
        "luci-app-statistics",
        "luci-app-uhttpd",
        "luci-app-wireguard",
        "luci-app-wol",
        "luci-base",
        "luci-lib-base",
        "luci-lib-ip",
        "luci-lib-jsonc",
        "luci-lib-nixio",
        "luci-mod-admin-full",
        "luci-mod-network",
        "luci-mod-status",
        "luci-mod-system",
        "luci-proto-ipv6",
        "luci-proto-ppp",
        "luci-ssl",
        "luci-theme-bootstrap",
        "mkf2fs",
        "mosquitto-client-nossl",
        "mosquitto-ssl",
        "msmtp",
        "mtd",
        "mtr-json",
        "nano",
        "netifd",
        "odhcp6c",
        "odhcpd-ipv6only",
        "openssh-sftp-server",
        "openwrt-keyring",
        "opkg",
        "partx-utils",
        "patch",
        "picocom",
        "ppp",
        "ppp-mod-pppoe",
        "procd",
        "px5g-wolfssl",
        "qrencode",
        "rpcd",
        "rpcd-mod-file",
        "rpcd-mod-iwinfo",
        "rpcd-mod-luci",
        "rpcd-mod-rrdns",
        "smstools3",
        "socat",
        "squid-mod-cachemgr",
        "sshfs",
        "tcpdump",
        "uboot-envtools",
        "ubox",
        "ubus",
        "ubusd",
        "uci",
        "uclient-fetch",
        "uhttpd",
        "uhttpd-mod-ubus",
        "urandom-seed",
        "urngd",
        "usb-modeswitch",
        "usbutils",
        "usign",
        "zstd"
    ],
    "diff_packages": true,
    "filesystem": "ext4",
    "client": "luci/git-22.210.54153-69231a7"
}

STDERR:

Generate local signing keys...
Generate local certificate...
Package list missing or not up-to-date, generating it.

Building package index...
Downloading https://downloads.openwrt.org/releases/23.05.4/targets/rockchip/armv8/packages/Packages.gz
Updated list of available packages in /builder/build_dir/target-aarch64_generic_musl/root-rockchip/../../../../builder/dl/openwrt_core
Downloading https://downloads.openwrt.org/releases/23.05.4/targets/rockchip/armv8/packages/Packages.sig
Signature check passed.
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/base/Packages.gz
Updated list of available packages in /builder/build_dir/target-aarch64_generic_musl/root-rockchip/../../../../builder/dl/openwrt_base
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/base/Packages.sig
Signature check passed.
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/luci/Packages.gz
Updated list of available packages in /builder/build_dir/target-aarch64_generic_musl/root-rockchip/../../../../builder/dl/openwrt_luci
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/luci/Packages.sig
Signature check passed.
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/packages/Packages.gz
Updated list of available packages in /builder/build_dir/target-aarch64_generic_musl/root-rockchip/../../../../builder/dl/openwrt_packages
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/packages/Packages.sig
Signature check passed.
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/routing/Packages.gz
Updated list of available packages in /builder/build_dir/target-aarch64_generic_musl/root-rockchip/../../../../builder/dl/openwrt_routing
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/routing/Packages.sig
Signature check passed.
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/telephony/Packages.gz
Updated list of available packages in /builder/build_dir/target-aarch64_generic_musl/root-rockchip/../../../../builder/dl/openwrt_telephony
Downloading https://downloads.openwrt.org/releases/23.05.4/packages/aarch64_generic/telephony/Packages.sig
Signature check passed.
Downloading file:packages/Packages
Updated list of available packages in /builder/build_dir/target-aarch64_generic_musl/root-rockchip/../../../../builder/dl/imagebuilder
Downloading file:packages/Packages.sig
Signature check passed.
Collected errors:
 * check_data_file_clashes: Package libustream-mbedtls20201210 wants to install file /builder/build_dir/target-aarch64_generic_musl/root-rockchip/lib/libustream-ssl.so
	But that file is already provided by package  * libustream-wolfssl20201210
 * opkg_install_cmd: Cannot install package luci-ssl.
make[2]: *** [Makefile:189: package_install] Error 255
make[1]: *** [Makefile:154: _call_manifest] Error 2
make: *** [Makefile:274: manifest] Error 2