469,903 Members | 1,948 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,903 developers. It's quick & easy.

Setting Time/Date in linux??

109 100+
Hi..

I am working on Arm-linux os on developement board. The OS reset the time and date whenever the board is reset. Is there any way that i can run a script to set the time/date instead of manually setting it?

Thanks..
Jul 3 '07 #1
12 5238
Motoma
3,237 Expert 2GB
Hi..

I am working on Arm-linux os on developement board. The OS reset the time and date whenever the board is reset. Is there any way that i can run a script to set the time/date instead of manually setting it?

Thanks..
Provided the board has network access, you may want to get NTP set up and running. Otherwise you will need to keep power to the device even when it is off.
Jul 3 '07 #2
skyy
109 100+
Provided the board has network access, you may want to get NTP set up and running. Otherwise you will need to keep power to the device even when it is off.
Yup.. so how do i get that running? thanks...
Jul 4 '07 #3
Motoma
3,237 Expert 2GB
Yup.. so how do i get that running? thanks...
I proposed two solutions, which one are you trying to figure out?
Jul 5 '07 #4
I proposed two solutions, which one are you trying to figure out?
The OS reset the time and date whenever the board is reset
means that your battery on the M/B is out of date, instead of finding other solutions you should update your battery asasp
Jul 6 '07 #5
means that your battery on the M/B is out of date, instead of finding other solutions you should update your battery asasp

/usr/sbin/ntpdate -v 130.133.1.10 131.188.3.220 193.67.79.202 ; /sbin/hwclock --systohc > /dev/null 2>&1
Jul 6 '07 #6
skyy
109 100+
/usr/sbin/ntpdate -v 130.133.1.10 131.188.3.220 193.67.79.202 ; /sbin/hwclock --systohc > /dev/null 2>&1
hi.. thanks for the reply..

But i cant find the ntpdate function anywhere. Instead i got this "rdate" function which is part of busybox. Any idea how to use it?
Jul 12 '07 #7
Motoma
3,237 Expert 2GB
Check out the rdate man page.
Jul 12 '07 #8
skyy
109 100+
Check out the rdate man page.

Hi.. thanks for the link. What should i set for the host?
Jul 12 '07 #9
Motoma
3,237 Expert 2GB
Hi.. thanks for the link. What should i set for the host?
I think ntp.org keeps a listing of servers. You could try searching their list for one that is close to you geographically, or you could just use pool.ntp.org.
Jul 12 '07 #10
skyy
109 100+
I think ntp.org keeps a listing of servers. You could try searching their list for one that is close to you geographically, or you could just use pool.ntp.org.
Hi thanks for the link...

But when i try with pool.ntp.org, "rdate" return with an error: Host name lookup failure.

I tried other time server also gives me the same error.
Any idea?
Jul 13 '07 #11
Motoma
3,237 Expert 2GB
Hi thanks for the link...

But when i try with pool.ntp.org, "rdate" return with an error: Host name lookup failure.

I tried other time server also gives me the same error.
Any idea?
Sounds like you don't have internet access. Can you ping google from the device?
Jul 13 '07 #12
skyy
109 100+
Sounds like you don't have internet access. Can you ping google from the device?
Hi.. yah i got problem with my internet access. I can't ping google from the device. But my device is connected to a nework router. why it is not able to access internet?
Jul 17 '07 #13

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

8 posts views Thread by Gerrit Holl | last post: by
6 posts views Thread by David Graham | last post: by
1 post views Thread by Steven Dilley | last post: by
8 posts views Thread by David Lozzi | last post: by
5 posts views Thread by Amogh | last post: by
37 posts views Thread by David T. Ashley | last post: by
9 posts views Thread by Aditi | last post: by
1 post views Thread by Waqarahmed | last post: by
reply views Thread by Salome Sato | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.