the problem is my raspberry pi 3 doesn't show the correct date and time.i edit this file: sudo nano /etc/ntp.conf
with correct server addresses and i try this commands :
sudo /etc/init.d/ntp stop
sudo ntpd -q-g
but i get this error:
/usr/sbin/ntpd: illegal option -- -
ntpd - NTP daemon program - Ver. 4.2.8p10
Usage: ntpd [ -<flag> [<val>] | --<name>[{=| }<val>] ]... \
[ <server1> ... <serverN> ]
Try 'ntpd --help' for more information.
how can i correct this error? thank you
ntpd
timesyncd
is the Debian default used to synchronize the local system clock with a remote Network Time Protocol server and works for the vast bulk of users. There is no reason to think the OP has installedntpd
; it seems more likely to be following an obsolete tutorial. Unless this is clarified answering seems pointless, and the question would still not be Raspberry Pi specific