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

There are too many hostname aliases per line in a Windows hosts file #258

Open
Flyfoxs opened this issue Mar 6, 2023 · 1 comment
Open

Comments

@Flyfoxs
Copy link

Flyfoxs commented Mar 6, 2023

https://superuser.com/questions/932112/is-there-a-maximum-number-of-hostname-aliases-per-line-in-a-windows-hosts-file

Kubefwd generate too many aliases hostname in one line as below.

you will get this error when you run ping hadoop-hadoop-yarn-nm-2.nodemanager

Ping request could not find host hadoop-hadoop-yarn-nm-2.nodemanager. Please check the name and try again.

127.1.27.5 hadoop-hadoop-yarn-nm-2.nodemanager hadoop-hadoop-yarn-nm-2-nodemanager hadoop-hadoop-yarn-nm-2.nodemanager.backoffice hadoop-hadoop-yarn-nm-2-nodemanager-backoffice hadoop-hadoop-yarn-nm-2.nodemanager.backoffice.svc hadoop-hadoop-yarn-nm-2-nodemanager-backoffice-svc hadoop-hadoop-yarn-nm-2.nodemanager.backoffice.svc.cluster.local hadoop-hadoop-yarn-nm-2-nodemanager-backoffice-svc-cluster-local hadoop-hadoop-yarn-nm-2.nodemanager.backoffice.arn:aws:eks:us-east-1:882490700787:cluster/ubix-backoffice-cluster hadoop-hadoop-yarn-nm-2-nodemanager-backoffice-arn-aws-eks-us-east-1-882490700787-cluster-ubix-backoffice-cluster hadoop-hadoop-yarn-nm-2.nodemanager.backoffice.svc.arn:aws:eks:us-east-1:882490700787:cluster/ubix-backoffice-cluster hadoop-hadoop-yarn-nm-2-nodemanager-backoffice-svc-arn-aws-eks-us-east-1-882490700787-cluster-ubix-backoffice-cluster hadoop-hadoop-yarn-nm-2.nodemanager.backoffice.svc.cluster.arn:aws:eks:us-east-1:882490700787:cluster/ubix-backoffice-cluster hadoop-hadoop-yarn-nm-2-nodemanager-backoffice-svc-cluster-arn-aws-eks-us-east-1-882490700787-cluster-ubix-backoffice-cluster

@erikbozic
Copy link

Just wanted to confirm this is definitely a problem - had to switch to Windows recently and found this out.

I see the actual hosts file management is done within https://github.com/txn2/txeh.

Could the txeh library be changed so it would split the hostnames into multiple lines, once it reaches 9 hostnames per address (for windows only)?

Or do you think this is for some reason undesirable?
I could dive in and see if I can create a PR - but please confirm this is something you see as a benefit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants