Windows Vista Tips

Windows Vista Tips > Newsgroups > Virtual PC > Re: How to start always with same system time (VPC 2007 SP1)

Reply
Thread Tools Display Modes

Re: How to start always with same system time (VPC 2007 SP1)

 
 
MikeD
Guest
Posts: n/a

 
      01-26-2012

"Christian Zimmermann" <> wrote in message
news:jfrokr$rq6$...
> Hello.
>
> I'm developing software and I want to test it in a virtual system with a
> special system time. So, every time I start the virtual system I want it
> to start with a certain given system time.
>
> I already know how to disable host time synchronisation. Of course this
> precondition is done. But how can I automatically set a certain system
> time as start time for the virtual machine? Is there a special XML tag to
> set in the .vmc file I don't know?
>
> I don't want to do that manually in the vm's bios every time I start it.
>



There's no way that I know of to do this. But since you're a developer, why
don't you just write a little utility to set the system time to whatever you
want it to be and run that utility at startup (either from the Registry or
from Start Menu's Startup group)?

Mike


 
Reply With Quote
 
 
 
 
MikeD
Guest
Posts: n/a

 
      01-26-2012

"MikeD" <> wrote in message
news:jfs0do$e7f$...
>
> "Christian Zimmermann" <> wrote in message
> news:jfrokr$rq6$...
>> Hello.
>>
>> I'm developing software and I want to test it in a virtual system with a
>> special system time. So, every time I start the virtual system I want it
>> to start with a certain given system time.
>>
>> I already know how to disable host time synchronisation. Of course this
>> precondition is done. But how can I automatically set a certain system
>> time as start time for the virtual machine? Is there a special XML tag to
>> set in the .vmc file I don't know?
>>
>> I don't want to do that manually in the vm's bios every time I start it.
>>

>
>
> There's no way that I know of to do this. But since you're a developer,
> why don't you just write a little utility to set the system time to
> whatever you want it to be and run that utility at startup (either from
> the Registry or from Start Menu's Startup group)?
>
> Mike
>
>


Actually, you don't even need to write such a utility. Just create a batch
file to run the Date command line.


 
Reply With Quote
 
MikeD
Guest
Posts: n/a

 
      01-27-2012


"Christian Zimmermann" <> wrote in message
news:jftutp$su3$...
> Yes, thank you. I already thought about such a solution. But it's very
> (too) late in the booting process, because I cannot assure that such a
> script or a program is started before any service. If there is no tag for
> that then it would be necessary to manipulate directly the .vhd file where
> the vm system time and date is stored. But where and how?
>


I'm assuming you only need to do this for debugging/testing purposes
(because otherwise it'd be a very bad thing to be changing the system
date/time). So, can you just hard-code a substitute for the system date for
that purpose only?

The other thing you can do, which I just verified, is change the date and
time of your host OS. It appears the guest OS simply uses that date and
time. I changed the host OS's date to 01/01/2012 and then started a WinXP VM
and sure enough, it also had a date of 01/01/2012. Furthermore, I then reset
the host OS date to the correct date and the guest OS automatically reset
its date to match. Granted, that means you still need to manually change the
system date of the host, but from what I can see, that may be your only
option.

Mike


 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ActiveSync Won't Sync dherrstrom ActiveSync 8 01-15-2011 03:06 AM
Re: Active Directory problems/dcdiag error kj [SBS MVP] Windows Server 4 03-24-2010 09:19 PM
Re: Active Directory problems/dcdiag error kj [SBS MVP] Windows Small Business Server 3 03-24-2010 09:19 PM
active sync issue mk3100 patrick craig ActiveSync 0 01-15-2010 05:06 AM
Exchange Sync Issues Harry ActiveSync 0 08-24-2007 10:42 AM



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59