Description of problem: I booted a system with the network cable disconnected and got: [root@localhost ~]# date Wed 01 Apr 2020 05:24:35 PM UTC [root@localhost ~]# hwclock 2020-04-08 15:15:29.146007+00:00 trying to set the time [root@localhost ~]# hwclock --hctosys hwclock: settimeofday() failed: Invalid argument [root@localhost ~]# hwclock --hctosys --verbose hwclock from util-linux 2.35.1 System Time: 1585762054.571276 Trying to open: /dev/rtc0 Using the rtc interface to the clock. Last drift adjustment done at 1585761886 seconds after 1969 Last calibration done at 1585761886 seconds after 1969 Hardware clock is on local time Assuming hardware clock is kept in local time. Waiting for clock tick... ...got clock tick Time read from Hardware Clock: 2020/04/08 15:18:25 Hw clock time : 2020/04/08 15:18:25 = 1586359105 seconds since 1969 Time since last adjustment is 597219 seconds Calculated Hardware Clock drift is 0.000000 seconds Calling settimeofday(NULL, 0) to set persistent_clock_is_local. Calling settimeofday(1586359105.000000, 0) hwclock: settimeofday() failed: Invalid argument [root@localhost ~]# rpm -q glibc glibc-2.31-2.fc32.aarch64 Version-Release number of selected component (if applicable): util-linux-2.35.1-7.fc32.aarch64 I came across https://www.mail-archive.com/info-gnu@gnu.org/msg02694.html which indicates that the apis used by hwclock is removed for new use after being previously deprecated. if a system boots without network, date and time will be off. potentially preventing system from updating. How reproducible: always Steps to Reproduce: 1. hwclock --hctosys 2. 3. Actual results: hwclock: settimeofday() failed: Invalid argument Expected results: time to be set Additional info:
Fixed by upstream commit http://github.com/karelzak/util-linux/commit/cd781c405be82540484da3bfe3d3f17a39b8eb5c It seems we need to backport this commit to Fedora ASAP.
Fixed in util-linux-2.35.1-8.fc33 for rawhide.
FEDORA-2020-eedbcc85f7 has been submitted as an update to Fedora 32. https://bodhi.fedoraproject.org/updates/FEDORA-2020-eedbcc85f7
FEDORA-2020-eedbcc85f7 has been pushed to the Fedora 32 testing repository. In short time you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-eedbcc85f7` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-eedbcc85f7 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2020-eedbcc85f7 has been pushed to the Fedora 32 stable repository. If problem still persists, please make note of it in this bug report.