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

[Fix #5341] addressing deadlock regression in windows dispatcher threads #5421

Closed
wants to merge 1 commit into from

Conversation

muffins
Copy link
Contributor

@muffins muffins commented Feb 6, 2019

This addresses a slight regression to ensure that we set set_terminate_threads on Windows. Without this flag being set, Windows threads will deadlock on exit as the boost managed io service threads never receive termination notifications.

I'm opening this PR up against the old master as I feel we should likely cut a 3.3.3, and I'm happy to re-open this PR against the upstream experimental as well, but we'll want a fix for this released as quickly as possible to Windows deployments.

@facebook-github-bot facebook-github-bot added the cla signed Automated label: Pull Request author has signed the osquery CLA label Feb 6, 2019
@muffins
Copy link
Contributor Author

muffins commented Feb 6, 2019

Test pass:

Test project C:/Users/Nick/work/repos/osquery/build/windows10
    Start 1: osquery_tests
1/8 Test #1: osquery_tests ....................   Passed   10.32 sec
    Start 2: osquery_additional_tests
2/8 Test #2: osquery_additional_tests .........   Passed   76.21 sec
    Start 3: osquery_tables_tests
3/8 Test #3: osquery_tables_tests .............   Passed   11.61 sec
    Start 4: osquery_integration_tests
4/8 Test #4: osquery_integration_tests ........   Passed    8.00 sec
    Start 5: python_test_osqueryi
5/8 Test #5: python_test_osqueryi .............   Passed   73.64 sec
    Start 6: python_test_osqueryd
6/8 Test #6: python_test_osqueryd .............   Passed   19.88 sec
    Start 7: python_test_windows_service
7/8 Test #7: python_test_windows_service ......   Passed   25.07 sec

I also tested this against our internal configuration, we're no longer seeing the deadlock occur. We have integration tests for this server, test 7 above, and I'll investigate why it wasn't catching this before.

@muffins muffins self-assigned this Feb 6, 2019
@@ -28,6 +28,7 @@ class Status;
class Dispatcher;



Choose a reason for hiding this comment

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

;,)

@muffins muffins changed the base branch from master to experimental February 6, 2019 16:41
@muffins muffins force-pushed the win-service-zombie-fix branch 2 times, most recently from 1eda4bb to 0ffb269 Compare February 6, 2019 16:48
Copy link

@facebook-github-bot facebook-github-bot left a comment

Choose a reason for hiding this comment

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

@muffins has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

@facebook-github-bot
Copy link

@muffins has updated the pull request. Re-import the pull request

@facebook-github-bot
Copy link

@muffins has updated the pull request. Re-import the pull request

Copy link

@facebook-github-bot facebook-github-bot left a comment

Choose a reason for hiding this comment

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

@muffins has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

muffins added a commit to muffins/osquery that referenced this pull request Apr 1, 2019
…#5421)

Summary:
This addresses a slight regression to ensure that we set `set_terminate_threads` on Windows. Without this flag being set, Windows threads will deadlock on exit as the boost managed io service threads never receive termination notifications.

I'm opening this PR up against the old master as I feel we should likely cut a 3.3.3, and I'm happy to re-open this PR against the upstream experimental as well, but we'll want a fix for this released as quickly as possible to Windows deployments.
Pull Request resolved: osquery#5421

Reviewed By: marekcirkos

Differential Revision: D13972916

Pulled By: muffins

fbshipit-source-id: 55e3b23c80091d5fb51a97d1efc043b52dc48ba3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug cla signed Automated label: Pull Request author has signed the osquery CLA daemon Windows
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants