sammo
9
System date and time are set by /etc/init.d/sysfixtime script by finding the most recent timestamp of any file found in /etc:
boot() {
local curtime="$(date +%s)"
local maxtime="$(find /etc -type f -exec date -r {} +%s \; | sort -nr | head -n1)"
[ $curtime -lt $maxtime ] && date -s @$maxtime
}
Then, if you have Internet connection, NTP client will receive the actual date and time from an NTP server configured in /etc/config/system
1 Like