KEMBAR78
Improve agent startup on windows by stelfrag · Pull Request #21125 · netdata/netdata · GitHub
Skip to content

Conversation

@stelfrag
Copy link
Collaborator

@stelfrag stelfrag commented Oct 9, 2025

Summary
  • Improve log-fw initialization under windows.
    • Add state to make sure thread is initialized
  • Handle EINVAL under windows, when a thread is quickly joined after creation and exit

@stelfrag stelfrag marked this pull request as ready for review October 9, 2025 16:49
Copy link
Contributor

@thiagoftsm thiagoftsm left a comment

Choose a reason for hiding this comment

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

Windows service is starting normally with this PR. LGTM!

Copy link
Contributor

@thiagoftsm thiagoftsm left a comment

Choose a reason for hiding this comment

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

@stelfrag after few minutes running this branch stopped running.

@thiagoftsm thiagoftsm self-requested a review October 9, 2025 19:11
@stelfrag stelfrag marked this pull request as draft October 9, 2025 21:04
@stelfrag stelfrag force-pushed the improve_agent_windows_init branch from 7f32698 to 350315a Compare October 10, 2025 13:03
@thiagoftsm
Copy link
Contributor

Following the latest commits, the system ran successfully for three consecutive hours.

@stelfrag stelfrag force-pushed the improve_agent_windows_init branch from 350315a to 73cee74 Compare October 13, 2025 07:31
@stelfrag stelfrag marked this pull request as ready for review October 13, 2025 07:46
@stelfrag stelfrag requested a review from thiagoftsm October 13, 2025 13:40
Copy link
Contributor

@thiagoftsm thiagoftsm left a comment

Choose a reason for hiding this comment

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

PR is working as expected on Linux and Windows. LGTM!

@stelfrag stelfrag merged commit 3e65147 into netdata:master Oct 13, 2025
114 checks passed
@stelfrag stelfrag deleted the improve_agent_windows_init branch October 13, 2025 15:25
stelfrag added a commit to stelfrag/netdata that referenced this pull request Oct 15, 2025
* Exclude Windows from temporary spawn server initialization and cleanup

* Additional checks to isolate windows deadlock issue

* Switch to sleep_usec

* Cast revents to unsigned int for log clarity in log forwarder

(cherry picked from commit 3e65147)
@stelfrag stelfrag mentioned this pull request Oct 15, 2025
Ferroin pushed a commit that referenced this pull request Oct 15, 2025
* Exclude Windows from temporary spawn server initialization and cleanup

* Additional checks to isolate windows deadlock issue

* Switch to sleep_usec

* Cast revents to unsigned int for log clarity in log forwarder

(cherry picked from commit 3e65147)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants