Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • D dhcp
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 114
    • Issues 114
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 13
    • Merge requests 13
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • ISC Open Source Projects
  • dhcp
  • Issues
  • #194
Closed
Open
Created Jun 03, 2021 by onehalf3544@onehalf3570

resolvconf support is missing in dhclient

By default dhclient overwrites the /etc/resolv.conf once the nameservers' ips are obtain from the DHCP server or the lease is renewed. This becomes problematic when there are other source of those from other interfaces (e.g. openconnect/openvpn, which set up DNS servers from the private network). The natural solution is the usage of resolvconf, which manages such updates from multiple sources and merges them into /etc/resolv.conf

Since this is more like a feature request, it was suggested that this should be fixed here (https://bbs.archlinux.org/viewtopic.php?pid=1969134).

Would such PR be accepted? The changes are quite trivial..

Thanks.

Describe the bug dhclient overwrites the /etc/resolv.conf blindly, disregarding the fact that it could have been updated by other (dhcp) clients

To Reproduce Steps to reproduce the behavior:

  1. Run dhclient with default config
  2. Modify /etc/resolv.conf by any means
  3. Wait for the lease renewal on the dhclient interface
  4. Observe the contents of the /etc/resolv.conf

Expected behavior /etc/resolv.conf contents should be preserved somehow. Proposed way is to use resolvconf for that.

Environment: dhclient --version isc-dhclient-4.4.2

  • OS: ArchLinux Linux laptop_name 5.12.7-arch1-1 #1 (closed) SMP PREEMPT Wed, 26 May 2021 22:03:57 +0000 x86_64 GNU/Linux pacman -F dhclient core/netctl 1.24-1 usr/lib/netctl/dhcp/dhclient

Additional Information

Some initial questions

  • Are you sure your feature is not already implemented in the latest ISC DHCP version? It is not - https://gitlab.isc.org/isc-projects/dhcp/-/blob/master/client/scripts/linux#L80

  • Are you sure your requrested feature is not already impemented in Kea? Perhaps it's a good time to consider migration? Did not check, but would prefer to keep original dhclient

  • Are you sure what you would like to do is not possible using some other mechanisms? Using hooks, yes, but feature implementation is better to be done as close to the source as possible

  • Have you discussed your idea on dhcp-users and/or dhcp-workers mailing lists? arch linux forum - https://bbs.archlinux.org/viewtopic.php?pid=1969134#p1969134

Is your feature request related to a problem? Please describe. I'm frustrated when my VPN tunnel DNS server IP is overwritten with the ISP dhcp

Describe the solution you'd like Check if /usr/bin/resolvconf exists and use it if it does

Describe alternatives you've considered switch to a different dhcp client

Funding its development ISC DHCP is run by ISC, which is a small non-profit organization without any government funding or any permanent sponsorship organizations. Are you able and willing to participate financially in the development costs?

I could provide the patch once I can fork the project here

Participating in development Are you willing to participate in the feature development? ISC team always tries to make a feature as generic as possible, so it can be used in wide variety of situations. That means the proposed solution may be a bit different that you initially thought. Are you willing to take part in the design discussions? Are you willing to test an unreleased engineering code?

yes

Contacting you How can ISC reach you to discuss this matter further? If you do not specify any means such as e-mail, jabber id or a telephone, we may send you a message on github with questions when we have them.

onehalf3544@gmail.com

Assignee
Assign to
Time tracking