Update server time

From the command line as root.

For instructions, try this:

# man date

Jeff
 
If you read "man date" it should tell you how to do it:
Code:
date
Then copy the output...
Code:
date -s
and before pressing the Enter key, be sure to put in a space, and a double-quote mark. Then paste in what you copied previously. Then put in a closing double-quote mark.

Then before pressing Enter, backspace and change what you need to change.

Then press enter.

You can automate it as well, and get the correct time as often as you'd like from a timeserver; how you'd do that would depend on your server's OS distribution.

Jeff
 
I don't understand.

You log on to your linux or unix based server using ssh.

You type the command "date" (without the quotes) and you press the Enter key.

Do you get any output?

Do you then do what I said about using "date -s" ?

That's not supposed to give you any output, but if you immediately type just the first "date" command and press enter, you should now have the correct date.

What do you mean by "picks the time from windows.com"?

Jeff
 
if you want to sync it with the atomic clock, use this command:

/usr/bin/rdate -s time-a.nist.gov; /sbin/hwclock --systohc
 
Back
Top