Change BIOS time of a VirtualBox VM

Firstly, go here and tweak this script, adding the date you need. Click run. The result displayed is the number of milliseconds that you need to shave off the current bios time.

https://3v4l.org/GYPWE

<?php
// Now
$time = time();
// Date you want
$date = new DateTime('2014-09-18');
$newTime = $date->format('U');
// Copy paste the result into the command below
echo ($time - $newTime) * 1000;

Make sure the box is shut down. Now in your terminal, run these:

VBoxManage setextradata "NAME_OF_VM_HERE" "VBoxInternal/Devices/VMMDev/0/Config/GetHostTimeDisabled" 1
VBoxManage modifyvm "NAME_OF_VM_HERE" --biossystemtimeoffset PASTE_NUMBER_HERE

That’s it! VM is now running in the past.