From 291db96510af6687569536e25150fb087737f89a Mon Sep 17 00:00:00 2001 From: Paul Hinze Date: Thu, 12 Mar 2015 15:25:40 -0500 Subject: [PATCH] communicators/winrm: don't stop task on idle end StopOnIdleEnd was set in the task definition for elevated/privileged windows guest scripts. This setting: > specifies that the task stops when the idle condition ceases to be true [1] The "idle condition" is something that Windows periodically checks for, and it's defined by a bunch of criteria like user presence/absence, CPU / IO idle time, etc. [2] Telling our provisioner to stop the task if the "idle condition" ceases to be true is a recipe for some sporadically stopped tasks, which seems like precisely the behavior being reported in #5362. I'm pretty sure this fixes #5362 [1] https://msdn.microsoft.com/en-us/library/cc248332.aspx [2] https://msdn.microsoft.com/en-us/library/windows/desktop/aa383561%28v=vs.85%29.aspx --- plugins/communicators/winrm/scripts/elevated_shell.ps1.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/communicators/winrm/scripts/elevated_shell.ps1.erb b/plugins/communicators/winrm/scripts/elevated_shell.ps1.erb index 454e5e874..923f034bb 100644 --- a/plugins/communicators/winrm/scripts/elevated_shell.ps1.erb +++ b/plugins/communicators/winrm/scripts/elevated_shell.ps1.erb @@ -27,7 +27,7 @@ $task_xml = @' false false - true + false false true