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

Use nmcli to set DHCP hostname for modern RHEL distros #3243

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

vittyvk
Copy link
Contributor

@vittyvk vittyvk commented Oct 14, 2024

RHEL8+ uses NetworkManager and the most recent RHEL10 switched to using built-in dhcp client making DefaultOSUtil.set_dhcp_hostname() unsuitable. In fact, RHEL distos had been carrying RHEL-only downstream patch replacing RedhatOSModernUtil.set_dhcp_hostname() with

nmcli device modify ipv4.dhcp-hostname <HOSTNAME ipv6.dhcp-hostname

since RHEL8 but this is also not ideal as 'nmcli device modify' does not persist the change. Do 'nmcli connection modify' instead.

Issue #


PR information

  • The title of the PR is clear and informative.
  • There are a small number of commits, each of which has an informative message. This means that previously merged commits do not appear in the history of the PR. For information on cleaning up the commits in your pull request, see this page.
  • [-] If applicable, the PR references the bug/issue that it fixes in the description.
  • [-] New Unit tests were added for the changes made

Quality of Code and Contribution Guidelines

RHEL8+ uses NetworkManager and the most recent RHEL10 switched to using
built-in dhcp client making DefaultOSUtil.set_dhcp_hostname() unsuitable.
In fact, RHEL distos had been carrying RHEL-only downstream patch replacing
RedhatOSModernUtil.set_dhcp_hostname() with

  nmcli device modify <DEV> ipv4.dhcp-hostname <HOSTNAME ipv6.dhcp-hostname
  <HOSTNAME>

since RHEL8 but this is also not ideal as 'nmcli device modify' does not
persist the change. Do 'nmcli connection modify' instead.

Signed-off-by: Vitaly Kuznetsov <[email protected]>
@vittyvk
Copy link
Contributor Author

vittyvk commented Nov 21, 2024

ping?

@maddieford
Copy link
Contributor

Hi @vittyvk, thank you for opening this. It's in our backlog to review+test

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

Successfully merging this pull request may close these issues.

2 participants