Changing time or offsetting it in OpenVZ contained server

Milad Naseri asked:

I am trying to run a VPS, a Debian box contained in an OpenVZ container. Obviously, I cannot use time --set or any such command, as the time must be set via the parent node. The owner of the parent node, however refuses to adjust the time (which is 30 minutes slower than the actual time).

All the programs on my system, consequently, now recognized the false time and this throws a wrench in my syncing. Is there a way to possibly change the system time without interference from the container’s administrator? Or perhaps, failing that, a way to make the programs “see” the time 30 minutes faster than what is reported by the container?

My answer:

You can’t do anything with the system time inside an OpenVZ container.

If the host refuses to fix the clock, go take your business elsewhere. They obviously don’t want your money badly enough.

View the full question and any other answers on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.