Hello comunity!
I have a problem with the slitaz clock, it shows me a totaly wrong infromation, 11/09/2008 04:39 AM, with 15 hours and 4 years away from the real date and time...
What can i do to set the proper time?
Greetings.
[HELP] Clock problems
(20 posts) (7 voices)-
Posted 12 years ago #
-
# tazpkg get-install ntp
# ntpdate -u fr.pool.ntp.org && hwclock -w -uPosted 12 years ago # -
Thank you Bellard! :)
Posted 12 years ago # -
> # tazpkg get-install ntp
> # ntpdate -u fr.pool.ntp.org && hwclock -w -uWe already have busybox with builtin NTP client/server..
Posted 12 years ago # -
@devl547
OK, so how to you set the clock with "busybox with builtin NTP client/server"?Posted 12 years ago # -
My investigation:
# busybox ntp ntp: applet not found
In the output of busybox --help I see ntpd:
# busybox ntpd --help Command line: busybox ntpd --help BusyBox v1.18.4 (2012-03-14 03:32:25 CET) multi-call binary. Usage: ntpd [-dnqNwl] [-S PROG] [-p PEER]... NTP client/server Options: -d Verbose -n Do not daemonize -q Quit after clock is set -N Run at high priority -w Do not set time (only query peers), implies -n -l Run as server on port 123 -S PROG Run PROG after stepping time, stratum change, and every 11 mins -p PEER Obtain time from PEER (may be repeated)
See ya!
+++
root@slitaz:/home/tux# busybox ntpd -dnqp fr.pool.ntp.org ntpd: sent query to 88.191.88.195 ntpd: reply from 88.191.88.195: reach 0x01 offset 0.066334 delay 0.073731 ↵ status 0x24 strat 2 refid 0x14025dc0 rootdelay 0.001678 ntpd: sent query to 88.191.88.195 ntpd: reply from 88.191.88.195: reach 0x03 offset 0.067031 delay 0.074315 ↵ status 0x24 strat 2 refid 0x14025dc0 rootdelay 0.001678 ntpd: sent query to 88.191.88.195 ntpd: reply from 88.191.88.195: reach 0x07 offset 0.066614 delay 0.074110 ↵ status 0x24 strat 2 refid 0x14025dc0 rootdelay 0.001678 ntpd: sent query to 88.191.88.195 ntpd: reply from 88.191.88.195: reach 0x0f offset 0.066482 delay 0.072698 ↵ status 0x24 strat 2 refid 0x14025dc0 rootdelay 0.001678 ntpd: sent query to 88.191.88.195 ntpd: reply from 88.191.88.195: reach 0x1f offset 0.065155 delay 0.078656 ↵ status 0x24 strat 2 refid 0x14025dc0 rootdelay 0.001678 root@slitaz:/home/tux#
………
Posted 12 years ago # -
@Aleksej
thanks, one question
root@slitaz:/home/tux# busybox ntpd -dnqp fr.pool.ntp.orgtux@slitaz:~$ su
Password:
root@slitaz:/home/tux# /home/tux# busybox ntpd -dnqp fr.pool.ntp.org
sh: /home/tux#: not found
root@slitaz:/home/tux##1 - unsure what command I use and
#2 - where to find the local npt to replace your "fr.pool.ntp.org"Posted 12 years ago # -
Oh man! ;)
Looks like you're new to Linux.
When you see next command:
root@slitaz:/home/tux# busybox ntpd -dnqp fr.pool.ntp.org
you want to understand that root@slitaz:/home/tux# is command line prompt, and busybox ntpd -dnqp fr.pool.ntp.org is actually a command. I just copy my terminal to my post. My prompt includes:- current user name: root
- symbol @
- machine name: slitaz
- symbol :
- current path: /home/tux
- symbol # indicates root user, or symbol $ indicates unprevileged user
For choosing your nearest ntp server go here: http://support.ntp.org/bin/view/Servers/NTPPoolServers
Posted 12 years ago # -
yep - root@slitaz:/home/tux# busybox ntpd -dnqp fr.pool.ntp.org - stupid mistake
thanks for the step-by-stepPosted 12 years ago # -
busybox ntpd -dnqp 0.north-america.pool.ntp.org
still unable to set correct date/time on my system, thoughts?
Posted 12 years ago # -
Copy & paste your terminal here (Sakura terminal → select text (by hold left-mouse-nutton & drag over text, then release left-mouse-button) → switch to forum → press middle-mouse-button in text field (to paste selected text). Or attach screenshot.
I have not any problems with your command.
By the way, NTPD fetches date/time from high-class precision time servers and set your system clocks (system clock is not hardware clock). Do you properly set your timezone? (SliTaz menu → Settings → Time Zone configuration)
Posted 12 years ago # -
That's why Bellard suggested
hwclock -w -u
because it sets the hardware clock with the system clock's time.Posted 12 years ago # -
Yes, there is two steps in Bellard's code:
- set system clocks from internet
- set hardware clocks from system clocks.
Yes, I describe only first step, while second step is optional and unchanged.
So, here combined command to set system clocks and hardware clocks from internet:
busybox ntpd -dnqp north-america.pool.ntp.org && hwclock -w -u
Posted 12 years ago # -
Posted 12 years ago #
-
... did you change the timezone to the right one? Go to Applications--> Preferences--> Time Zone Configuration
You may need to install glibc-locale to get all the possible timezones.
Posted 12 years ago #
Reply »
You must log in to post.