Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(FM-7628) Update install_puppet.ps1 to catch hanging pxp-agent processes #390

Merged
merged 1 commit into from Feb 21, 2019

Conversation

mcdonaldseanp
Copy link
Contributor

We have seen cases with customers where after shutting down the pxp-agent
service there are still pxp-agent processes open.

This commit adds a workaround to the install_puppet.ps1 powershell script to
wait for any open pxp-agent processes to close, and if they don't the upgrade
script will stop before actually attempting the upgrade.

@puppetcla
Copy link

CLA signed by all contributors.

Copy link
Contributor

@caseywilliams caseywilliams left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes sense to me, LGTM

Write-Log "Waiting for pxp-agent processes to stop"
Get-Process -Name "pxp-agent" -ErrorAction SilentlyContinue | ForEach-Object {
if ($_) {
if (!$_.WaitForExit(120000)){
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What unit is this timeout in? Would be nice to have a comment with human-readable format

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have seen cases with customers where after shutting down the pxp-agent
service there are still pxp-agent processes open.

This commit adds a workaround to the install_puppet.ps1 powershell script to
wait for any open pxp-agent processes to close, and if they don't the upgrade
script will stop before actually attempting the upgrade.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants