If you would like to try it, we are testing a workaround that should work for most (probably all) people having problems with the time not being set properly. To manually install the update download and install the correct version for your device:
Pi1:
wget http://46.37.189.135/osmc/apt/pool/main/a/armv6l-network-osmc/armv6l-network-osmc_1.4.5_armhf.deb
sudo dpkg -i armv6l-network-osmc_1.4.5_armhf.deb
Pi 2 / Vero:
wget http://46.37.189.135/osmc/apt/pool/main/a/armv7-network-osmc/armv7-network-osmc_1.4.5_armhf.deb
sudo dpkg -i armv7-network-osmc_1.4.5_armhf.deb
Please let us know if this helps fix the time/date not being set on boot.
For some technical background on this for those interested, the problem is not actually a bug in our ntp client, but rather source port 123 (used by the ntp protocol) being blocked by the router/ISP.
So we are implementing a workaround very similar to that used in Raspbmc - during boot the time is first set approximately by sending an HTTP query to google/apple/microsoft and using the Date field in the returned HTTP header. This is only accurate to within about a second or two allowing for network delays, but is better than being out by 40 years…
After that ntpd is started and will set the time more accurately and make fine adjustments to keep the time within a few milliseconds. So if you cant use ntp because port 123 is blocked your time won’t be as accurate and won’t be continually fine tuned to stay in sync but it will be near enough. If you can use ntp (your date/time currently works ok) there is no down side - your time will stay accurately synced to ntp time.
This should be part of the next major round of updates.
Sorry for the delay. I missed this question being posted until now. I have dsl and I’m using the dsl modem/router (BEC brand) that was provided. I also have a small network switch between the Vero and the router. Yes the Vero is on a private and reserved IP address.
I will try the update when I get a chance and report back what happens.
I installed the update but I can’t tell if it has helped or not since my time and date has been correct since the manual update.
Try shutting down for 5 minutes then booting up.
If it’s working the time will be correct, if it’s not working the time will be 5 minutes behind.
That makes sense. I will try that.
My time appears to be updating correctly now. I unplugged it for a while and it is still correct after booting back up.
The new updates worked! I had given up on OSMC gone back to Raspmc and thought I would try it one more time. I read all your posts and after much trial and error (might have been the new updates today), voila! the time and date worked perfectly. I am going to copy this SD card to another to make sure I have a clone, just in case.
Thanks for all the help and for working so hard to make OSMC such a great success.
Glad to hear it. We pushed out a load of updates for RC3 today including a fix for setting the time so yes if you run updates the time fix should be installed.
Note that this fix is technically more of a workaround - if ntp is not able to connect then the time is only set once during boot using an HTTP request - this time may be anywhere up to about a second behind, (typically about 0.2 to 0.8 seconds behind I’ve measured) and will gradually drift out of time by as much as a few seconds per day (due to the accuracy of the Pi clock) unless you reboot as the time is not being periodically corrected.
However - this is more or less the exact same workaround that was used in Raspbmc, so you are no worse off than you were in Raspbmc. (We had forgotten that workaround existed in Raspbmc so have re-implemented it in OSMC as apparently a few people were relying on it)
To get much more precise time (within 0.1 seconds) that is constantly maintained then you would need to find why ntp is unable to connect using port 123 and fix that. (Most likely your router)
Thanks, again. My son is a software engineer in Kansas City for a nationally recognized company. Online he helped me try hundreds of “trys” to rectify that time issue, included going in to check all of my forwarding ports on my router, which he set up and maintains. Nothing worked. We spent 3 hours at this and finally right before I went to bed I did the update. (I normally go to bed at 11 pm and this was at 3 am.) I forwarded the post you sent me to him, because he is the one who guided me through the rss updates and without his help I am useless at this.
I have an extensive collection of video recordings on my main computers which use mythtv as the backends and I enjoy that very much.
Now the schedule’s direct finally also works. We can go back and forth on the reason’s why but I can tell you that without that update, I have a backup of the Raspmc to use on all 3 of our pis. It will be fun to see what the horizon holds for this little electronic wonder.
I need the schedule’s direct to work or the pi is useless to me. Thanks for what you are doing.
I’m experiencing some trouble with wrong time in mine 2015.11-2 version… and I’m under a NAT with my provider that gives me private IP address.
My question is: if I obtain a public IP from my ISP this should solve the problem?
Proper time should not depend on public IP address (I am running NTP via 3 threetimes cascaded NAT). It is more about how your ISP handles the NAT and also the access to the NTP port.
Suggest you post the output of:
sudo journalctl -u ntp
ntpq -c peers
sudo /usr/bin/http-time
either you run the command and post the output or you pipe it to paste-log and post the URL’s here
sudo journalctl -u ntp | paste-log
ntpq -c peers | paste-log
sudo /usr/bin/http-time | paste-log
That looks fine, how about the other two commands?
Why in
sudo journalctl -u ntp
the log reports:
– Logs begin at Fri 2015-12-11 15:39:55 CET, end at Thu 2015-12-24 10:13:48 CET
2015-12-11 it’s the wrong date…
Well hard to say as the ntp server only is started when the machine boots. Not sure when you last time rebooted.
But looking at your ntpq -c peers the issue is the first 3 NTP server are not working.
Can you post output of cat /etc/ntp.conf
I’ll post in seconds, however i have restarted the machine many times from 2015-12-11, for sure!