Skip to content

Agent fails to update new Fleet Server hosts if the first host fails #1328

@AndersonQ

Description

@AndersonQ

The Elastic Agent fails to update the fleet-server hosts when the first host is unreachable.

Steps to Reproduce:

  1. configure fleet-server hosts to have 2 hosts. The first must NOT work, the second should work. (Suggestion, make the first host be https://localhost:8220)
  2. I enroll agent by using the working fleet-server URL, the second one
  3. the agent successfully installs
  4. The agent shows unhealthy on fleet-ui
  5. in the agent logs, a error log like the following is found
{"log.level":"error","@timestamp":"2022-09-27T13:38:46.667Z","log.origin":{"file.name":"fleet/fleet_gateway.go","file.line":202},"message":"failed to dispatch actions, error: fail to communicate with updated API client hosts: Get \"https://localhost:8220/api/status?\": dial tcp 127.0.0.1:8220: connect: connection refused","ecs.version":"1.6.0"}

Affected versions

  • Version: 8.2.2, 8.6-SNAPSHOT (2b6cfdc)
  • Operating System: all
  • Discuss Forum URL: N/A

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions