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

[Fleet]: Hostnames are visible with lower case letters when actually set in Upper case. #159372

Closed
amolnater-qasource opened this issue Jun 9, 2023 · 12 comments
Labels
bug Fixes for quality problems that affect the customer experience impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. Team:Elastic-Agent-Control-Plane Team:Fleet Team label for Observability Data Collection Fleet team

Comments

@amolnater-qasource
Copy link

amolnater-qasource commented Jun 9, 2023

Kibana Build details:

VERSION: 8.9.0 Snapshot
BUILD: 63944
COMMIT: 9d6846d9e259192dd968c503fac40c44d42c13b9

Host OS and Browser version: Windows, All

Preconditions:

  1. 8.9.0 SNAPSHOT Kibana cloud environment should be available.
  2. Few Agents should be installed.

Steps to reproduce:

  1. Navigate to Fleet>Agents tab.
  2. Observe host names are visible with lower case.
    • Issue is specifically reproducible with 8.9 artifacts.

Expected:
Hostnames should be visible with upper case letters when actually set in upper case.

Screenshots:
1
2
image
image
image

What's working:

  • Hostnames are showing in upper case if the lower version agents are installed on same host.
@amolnater-qasource amolnater-qasource added bug Fixes for quality problems that affect the customer experience impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. Team:Fleet Team label for Observability Data Collection Fleet team labels Jun 9, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/fleet (Team:Fleet)

@amolnater-qasource
Copy link
Author

@manishgupta-qasource Please review.

@manishgupta-qasource
Copy link

Secondary review for this ticket is Done

@cmacknz
Copy link
Member

cmacknz commented Jun 12, 2023

I think this is because of elastic/elastic-agent#2767 and the related change in Beats.

The original PR was elastic/go-sysinfo#180, ECS recommends the FQDN hostname always be in lowercase. This was an intentional change.

@cmacknz
Copy link
Member

cmacknz commented Jun 12, 2023

Looking at the screenshot this change results in duplicate agents in the UI doesn't it?

DNS hostnames are not case sensitive, I think this could be considered a bug in how the UI does hostname comparisons. We could also categorize this as a breaking change how the agent and Beats report hostnames, but they technically should not be case sensitive.

CC @jlind23 @juliaElastic @ycombinator

@amolnater-qasource
Copy link
Author

Hi @cmacknz

Thank you for looking into this issue.

Just to avoid confusion, we have installed agents on the same host, uninstalling them(not unenrolling from the UI) and then reinstalling for better comparisons. There are no duplicate agents due to any issue in the UI.

The issue is just with 8.9.0 agents host name[not set to FQDN] getting in lower case.

Screenshot:
image

Please let us know if we are missing anything here.

Thanks!

@jlind23
Copy link
Contributor

jlind23 commented Jun 13, 2023

@amolnater-qasource if there are no duplicates then I think we can close this issue as this is not a bug but rather a change introduced by elastic/go-sysinfo#180.
As this change won't be rolled back we only have two options:

  • Don't do anything
  • Create a doc entry stating that from 8.9 on the hostname is going to always be lower case.

@amolnater-qasource
Copy link
Author

Thank you for the confirmation @jlind23

We have further observed that these changes aren't available under Endpoints tab:
image
image

Two different names are visible for same host under HOSTS tab:
image

Data with two different names is visible for same host under Discover tab on adding Elastic Defend:
image

Could anyone please confirm if this is expected too?

Thank you!

@jlind23
Copy link
Contributor

jlind23 commented Jun 13, 2023

Endpoint team has its own way of returning FQDN value @nfritts are you planning on lowercasing hostname just like recommended at https://www.elastic.co/guide/en/ecs/current/ecs-host.html#field-host-name?

[The host.name field] can contain what hostname returns on Unix systems, the fully qualified domain name (FQDN), or a name specified by the user. The recommended value is the lowercase FQDN of the host.

@nfritts
Copy link

nfritts commented Jun 13, 2023

@jlind23 Yes. We treat any result from endpoint that doesn't match the agent output as a bug. we have tests to detect this and while looking in to this I learned that we basically don't have any machines with capital letters in them that run the tests.

We'll have it fixed in 8.9.

@jlind23
Copy link
Contributor

jlind23 commented Jun 13, 2023

@amolnater-qasource can we close this issue as it seems to be an endpoint specific one?

@amolnater-qasource
Copy link
Author

Hi @jlind23

Thank you for resolving this.

Yes, as the issue is just related to Endpoint specific now, we are closing this.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. Team:Elastic-Agent-Control-Plane Team:Fleet Team label for Observability Data Collection Fleet team
Projects
None yet
Development

No branches or pull requests

6 participants