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

[Windows] Agent should respect Windows service manager requirements on startup #5710

Closed
faec opened this issue Oct 4, 2024 · 1 comment · Fixed by #6068
Closed

[Windows] Agent should respect Windows service manager requirements on startup #5710

faec opened this issue Oct 4, 2024 · 1 comment · Fixed by #6068
Assignees
Labels
bug Something isn't working Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team

Comments

@faec
Copy link
Contributor

faec commented Oct 4, 2024

The Windows service manager requires services to respond to it immediately on startup before handling other work. Agent doesn't do this, because its startup was initially written for platforms with less strict requirements. Usually this isn't a problem in practice, but in some Windows environments it can cause an issue where occasionally an Agent doesn't start after reboot (because the service manager kills it before it responds). This especially shows up in larger deployments after a system update; some small fraction of Agents will not resume on their own and will need to be started manually.

A manual workaround is to set the Agent's service type to "Automatic (delayed)" rather than "Automatic", which typically runs the service startup under lower system load, averting the issue. However this isn't a scalable option for large installs, so we should rework the startup code to properly handle the default Windows case.

Related: #4976

@faec faec added bug Something isn't working Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team labels Oct 4, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants