-
Notifications
You must be signed in to change notification settings - Fork 63
Conversation
Thanks Julien -- I'll take a closer look this week and get this merged in. How would we suggest people opt out of this feature if they don't want the risk of killing the process? Set the timeout to |
Hello Ryan,
You are right, we need an option to opt out. I think setting the timeout to
0 is the most intuitive way.
I’ll modify my PR the next weekend.
Have a nice day.
…On Mon, 14 May 2018 at 05:57, Ryan Puffer ***@***.***> wrote:
Thanks Julien -- I'll take a closer look this week and get this merged in.
How would we suggest people opt out of this feature if they don't want the
risk of killing the process? Set the timeout to [int]::MaxValue or null?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#46 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AI4kpGDf3w8-7dHz6RoMg3dri3rW_kv-ks5tyQ7LgaJpZM4T55oi>
.
|
Disabling WinRM workaround (process killing) is implemented: when HungRegistrationTimeout is set to 0, no process is killed. |
{ | ||
# Temporary disabling Verbose as xxx-PSSessionConfiguration methods verbose messages are useless for DSC debugging | ||
$VerbosePreferenceBackup = $Global:VerbosePreference | ||
$Global:VerbosePreference = 'SilentlyContinue' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can this be changed to the script scope?
{ | ||
# Temporary disabling Verbose as xxx-PSSessionConfiguration methods verbose messages are useless for DSC debugging | ||
$VerbosePreferenceBackup = $Global:VerbosePreference | ||
$Global:VerbosePreference = 'SilentlyContinue' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same scope issue
|
||
if ($Path) | ||
{ | ||
$registerString = "`$null = Register-PSSessionConfiguration -Name '$Name' -Path '$Path' -Force -ErrorAction 'Stop' -WarningAction 'SilentlyContinue'" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we use a static script block with parameters and the argument list to Start-job?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see comments
Hello,
This is my fix proposal for issue #30.
Before registering the PSSessionConfiguration, we save the list of services running in the same process as WinRM + services depending from them.
We let Register-PSSessionConfiguration command 10 seconds to complete. If it not complete in 10 seconds and the WinRM service is in the state 'Stopping', we kill the process hosting WinRm service and then restart all services impacted.
This change is