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

append domain-name in /etc/dhcp/dhclient.conf has extra '.' in appended domainname #6594

Closed
gwolski opened this issue Dec 5, 2024 · 2 comments
Labels

Comments

@gwolski
Copy link

gwolski commented Dec 5, 2024

Parallelcluster 3.11.1. Rocky 8.10.

While debugging another issue, I noticed that the entry you add to /etc/dhcp/dhclient.conf has a '.' at the end of the cluster domainname. Assuming my cluster is called rhel8c, here is what I see in /etc/dhcp/dhclient.conf:

DHCP Client Configuration file.

see /usr/share/doc/dhclient/dhclient.conf.example

see dhclient.conf(5) man page

Send client identifier as "hardware-type.link-layer address" (e.g. "1.c2.23.7d.c3.52.2c")

Required in environments where a bridge might be clobbering the forwarded

packet's MAC address (common in Wifi, Docsis, or ADSL bridging scenarios)

see dhcp-options(5) man page for 'dhcp-client-identifier'

see dhcp-eval(5) man page for 'hardware'

send dhcp-client-identifier = hardware;
append domain-name " rhel8c.pcluster.";

Note the extra period at the end of rhel8c.pcluster? I can't find anything in the documentation that says this is required.
I removed the period and sent a SIGHUP to Network manager to recreate the /etc/resolv.conf and the /etc/resolv.conf looks like it did before.

I'm no NetworkingManager expert and while things seem to work with the period (and even w/o) - it just seems wrong.

BTW, I would think it would be better to use "prepend" than append as most lookups are going to be hosts in the cluster, so it should try that domainname first?

@gwolski gwolski added the 3.x label Dec 5, 2024
@hgreebe
Copy link
Contributor

hgreebe commented Jan 2, 2025

The trailing dot serves to terminate the domain name, making it a fully qualified domain name. This signals that is should not be appended with any additional domain suffixes.

We use "append" because all the cluster domains in route53 end with "cluster_name.pcluster"

@gwolski
Copy link
Author

gwolski commented Jan 10, 2025

Hi @hgreebe
Not sure I agree with you on either point. But

I ran a test case for the first situation and the '.' is stripped out when it is put in the /etc/resolv.conf.

As for your "append" description - that is wrong. Or maybe I'm misunderstanding you. I'm suggesting you should use 'prepend' instead of 'append' of the "cluster_name.pcluster" as putting it first on the search line will save at least one lookup. It's a nit. This is what prepend will do. Your present use of "append" puts it at the end of the search line in the /etc/resolv.conf so the hostname is first checked against other domains (which of course will all fail, hence more lookups).

@gwolski gwolski closed this as completed Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants