DonationCoder.com Software > Post New Requests Here
Idea : One Shot System Time Sync
MilesAhead:
Just to be sure, did you try Cmdtime from here?: http://www.softshape.com/download/cmdtime.zip
I've used it for years but, as you said, it might be blocked. If that doesn't work, I'll see what I can put together.
-skwire (May 24, 2016, 06:59 PM)
--- End quote ---
I don't think I can get there from here. All servers I try return either "cannot reach the time server" or "permission denied."
It is not the end of the world if I have to type the time command into a command prompt. But if you made something that looked good that would be preferable. :Thmbsup:
MilesAhead:
For computername you can try a server on the local network and hopefully get one that hasn't got an exceptionally paranoid firewall.
-4wd (May 25, 2016, 05:42 AM)
--- End quote ---
Something must have happened when they installed new equipment or something. Logging into my web site control panel used to work fine over the WiFi. Now I have to get on one of the wired machines to log in. Fortunately my site is pretty stable now. I do not have to update it often.
Edit: apparently there is a Linux utility called htpdate that gets the time from the headers of web pages specifically for use when ntp port 123 is blocked. I looked around but could not find any Windows port of it less than 10 years old.
skwire:
Edit: apparently there is a Linux utility called htpdate that gets the time from the headers of web pages specifically for use when ntp port 123 is blocked. I looked around but could not find any Windows port of it less than 10 years old.-MilesAhead (May 25, 2016, 07:23 AM)
--- End quote ---
Ten years old is fine if they still work, eh? Did you try any of them?
MilesAhead:
Edit: apparently there is a Linux utility called htpdate that gets the time from the headers of web pages specifically for use when ntp port 123 is blocked. I looked around but could not find any Windows port of it less than 10 years old.-MilesAhead (May 25, 2016, 07:23 AM)
--- End quote ---
Ten years old is fine if they still work, eh? Did you try any of them?
-skwire (May 25, 2016, 12:04 PM)
--- End quote ---
I found a recend win32 version here:
http://www.rkeene.org/devel/htp/win32/stable/
It seems to work ok from and admin command prompt. I downloaded the exe with the highest version number, and scanned it with VirusTotal. Then I renamed it to simply htpdate.
For those interested this command line worked for me:
htpdate www.timeanddate.com set
Then I go on the wb to
Time.is
and it tells me how close my clock is to the time server.
I guess I can do an ahk to run it without showing the command prompt.
skwire:
Just for grins, here's an AHK solution that uses http://www.timeapi.org but doesn't use any third-party executables.
--- Code: Autohotkey ---; Set timezone value to your timezone.myTimeZone := "CDT" myTempFile := A_ScriptDir . "\~" . A_Now . ".txt"URLDownloadToFile, http://www.timeapi.org/%myTimeZone%/, % myTempFileFileRead, myTime, % myTempFileFileDelete, % myTempFile ; Sample output: 2016-05-25T13:24:22-06:00RegExMatch( myTime, "^(\d\d\d\d)-(\d\d)-(\d\d)T(\d\d:\d\d:\d\d)", myMatch ) ; Sample matches:; myMatch1 = 2016; myMatch2 = 05; myMatch3 = 25; myMatch4 = 13:24:22 ; Set the date.Run, %COMSPEC% /C date %myMatch2%-%myMatch3%-%myMatch1%, , Hide ; Set the time.Run, %COMSPEC% /C time %myMatch4% , , Hide
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version