Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Lets say you have a server that stores records, and the time stamp that goes into the mysql/postgres/text-file/whatever is vital to be accurate (lets pretend it's a physics experiment, or bank transaction auditing system).

My server's always end up out of time bit by bit each day (this may be due to existinging inside a VM?). I can run ntpdate every day, manually, which is a total pain, but I dont want to do that, and have a feeling it may not be a good solution at all for high precision time tracking.

What should I do to ensure my computer is never off by more than 0.05 seconds? I want to be able to walk away from it for 5 years and have it running accurate time when I come back.

Note: This is ubuntu-server, CLI commands only, there is no GUI.

share|improve this question
    
0.05 seconds is 50 milliseconds, which is a lot different than microseconds. Which did you really mean? –  psusi Apr 19 '11 at 19:26
    
I'm generally seeking precision better than a second, I imagine a microsecond may be difficult to track on a standard CPU without some sort of external higher-precision /dev connected. –  Incognito Apr 19 '11 at 19:46
1  
Indeed, you are going to need an atomic clock for microseconds. NTP serves quite well for +/- 50 milliseconds. –  psusi Apr 20 '11 at 0:46
add comment

2 Answers

up vote 2 down vote accepted

Please install ntp (not ntpdate) and add some time servers to your configuration.

See https://help.ubuntu.com/10.04/serverguide/C/NTP.html and the linked page to ntp here: http://www.ntp.org/ntpfaq/NTP-a-faq.htm

share|improve this answer
add comment

http://longspine.com/how-to/real-time-kernel-on-ubuntu-10-10-maverick-meerkat/

I'm not sure if this will be of any assistance, but I think you would need a real-time-kernel to do time sensitive, bank, automation etc.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.