Community discussions

MikroTik App
 
Rahmani
just joined
Topic Author
Posts: 4
Joined: Thu Nov 12, 2020 12:39 pm

Auto update time

Thu Nov 12, 2020 1:20 pm

Hi Everyone,

i have configured hotspot and Radius in RB2011, so I am using User manager and creating userprofile and lts limitation like 2GB and 5GB. so one problem is here when Mikotik is off for 24 hours then when turn it ON then clock is lagging behind then the current times, so result is "invalid password" for user, i am kindly requesting you to help me about this issue.

best regards
Rahmani
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 11381
Joined: Thu Mar 03, 2016 10:23 pm

Re: Auto update time

Thu Nov 12, 2020 9:13 pm

I suggest you configure (S)NTP client on your router in /system ntp ... configure it to use some good NTP server in area near you, you can check NTP pool project to find two suitable ones.
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 18958
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: Auto update time

Thu Nov 12, 2020 9:51 pm

YOu may have to download a package to access NTP.
Note afterwards your other MT devices capacs etc can get time from that server.
 
Rahmani
just joined
Topic Author
Posts: 4
Joined: Thu Nov 12, 2020 12:39 pm

Re: Auto update time

Sun Nov 15, 2020 7:18 am

YOu may have to download a package to access NTP.
Note afterwards your other MT devices capacs etc can get time from that server.
thank you for your replay, i have already downloaded NTP package and did the setup the clock and NTP client, but unfortunately when Mikrotik router is off and back it ON, time and date is not adjust itself. if you can help me about another suggestion.

best regards,
Rahmani
 
Rahmani
just joined
Topic Author
Posts: 4
Joined: Thu Nov 12, 2020 12:39 pm

Re: Auto update time

Sun Nov 15, 2020 7:20 am

I suggest you configure (S)NTP client on your router in /system ntp ... configure it to use some good NTP server in area near you, you can check NTP pool project to find two suitable ones.
thank you for your replay, i have already did, but unfortunately when Mikrotik router is off and back it ON, time and date is not adjust itself. if you can help me about another suggestion.

best regards,
Rahmani
 
User avatar
Smoerrebroed
Frequent Visitor
Frequent Visitor
Posts: 75
Joined: Mon Feb 12, 2018 10:21 am

Re: Auto update time

Mon Nov 16, 2020 7:58 pm

Perhaps it takes a few seconds after power-up, but ntp should sync the internal clock. Of course you need to configure it, too. Wiki even mentions that there is limited ntp support without the package, but that doesn't work for me, so I recommend the ntp package.
 
WeWiNet
Long time Member
Long time Member
Posts: 591
Joined: Thu Sep 27, 2018 4:11 pm

Re: Auto update time  [SOLVED]

Tue Nov 17, 2020 11:51 am

:delay 30s
:local ntpServer "pool.ntp.org"
:local primary [resolve $ntpServer]
:local secondary [resolve $ntpServer]

/system ntp client set primary-ntp $primary
/system ntp client set secondary-ntp $secondary
Put this into a schedule that runs at boot, adjust the delay (make sure device is fully functional and has internet access)
and then run it.
You can also re trigger this as a script every 12h or so to make sure updates happen...

PS: this works only in R6, in R7 NTP syntax has slightly changed.
 
Rahmani
just joined
Topic Author
Posts: 4
Joined: Thu Nov 12, 2020 12:39 pm

Re: Auto update time

Wed Nov 25, 2020 12:20 pm

Sir, for your info, when i have assigned IP manually not DHCP to ethernet 1, then the issue is solved.
 
User avatar
Smoerrebroed
Frequent Visitor
Frequent Visitor
Posts: 75
Joined: Mon Feb 12, 2018 10:21 am

Re: Auto update time

Wed Nov 25, 2020 7:19 pm

Strange. It works on DHCP for me as well.
 
rihanatkhan
just joined
Posts: 24
Joined: Tue Jun 13, 2017 11:31 am

Re: Auto update time

Fri Apr 16, 2021 7:08 am

Will it work when mikrotik device is in bridge mode and not able to access internet ?

Who is online

Users browsing this forum: lurker888, patrikg, wojtag and 33 guests