Vagrant -> Windows 8.1 WinRM remoting speed fix for slowness

498 views
Skip to first unread message

ferrix

unread,
Dec 29, 2014, 5:31:43 PM12/29/14
to vagra...@googlegroups.com
I couldn't figure out why the WinRM communicator was agonizingly slow to my Windows 8.1 VM.  I think I may finally have nailed it:

Turns out, it's the recurrence of a good ol' Powershell issue from back in the v1 days.

The Win 8.1 install doesn't seem to (or maybe, doesn't have time to?) run the scheduled task that "NGEN"s all the GAC assemblies.  This is needed to speed up launching .NET assemblies.

Thanks to this stack overflow thread and this clever powershell function, I have now added this task to my initial Packer deployment.  So by the time I'm running Vagrant provisioners, the WinRM communication is no longer painfully awful.

I just now got all this working, so I'm only about ~75% sure this was the actual issue (the speed seems to vary).  But I'm putting this post out into the world in case it can help other searchers.

Umair Chagani

unread,
Dec 29, 2014, 6:22:16 PM12/29/14
to vagra...@googlegroups.com

I would also check the startup type of the winrm service. By default, winrm service is set to "Automatic (delayed)". Setting this to just "Automatic" sped up connection to winrm a lot more.

--
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vagrant-up+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

ferrix

unread,
Dec 29, 2014, 6:43:01 PM12/29/14
to vagra...@googlegroups.com, umair....@gmail.com
Good idea, but it was definitely not a "just at startup" thing.  The delay happened every time a winrm context was invoked. 
Reply all
Reply to author
Forward
0 new messages