-2

I have a vagrant box running centos 7 using VirtualBox on Windows. I have shut off NTP with datetimectl, but every ten seconds the machine is resetting the clock after I manually change it. I need to shut this auto time correct off in order to test code that runs at specific time and days.

Someone down voted this question. I reworded it to provide better clarification. If you down vote again, please explain why. (IMHO all downvotes should be required to leave a reason)

5
  • Someone down voted this. Can you please provide a reason for the downvote? No one seems to know the answer and I have not found it by relentlessly searching. Please tell me how to better ask the question.
    – J.T.
    Commented Oct 22, 2022 at 16:10
  • If you've only used datetimectl, you clearly didn't try enough. Commented Oct 22, 2022 at 16:39
  • I found the answer mashuptwice after 3 hours of searching. It was neither 'clearly' easy to find nor obvious to discern. If you had known the answer, it would have been much better for you to simply post it.
    – J.T.
    Commented Oct 22, 2022 at 17:04
  • Nobody could answer it for you anyways, as you chose to omit that you use VirtualBox. Glad you found the answer by yourself. Commented Oct 22, 2022 at 17:05
  • OK - good point. I will try to edit.
    – J.T.
    Commented Oct 22, 2022 at 17:06

1 Answer 1

0

The solution is through the virtualbox machine.

First: find your machine:

prompt> vboxmanage list vms

(if this fails you might need to add the root directory of virtual box to your environment path)

find the machine you want to shut off the auto date correction for then type:

prompt> VBoxManage setextradata <machine_name> VBoxInternal/Devices/VMMDev/0/Config/GetHostTimeDisabled Value: 1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .