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

[BUG]DHCPClient fails to get DNS address #841

Open
mengwei84 opened this issue Jan 4, 2024 · 0 comments
Open

[BUG]DHCPClient fails to get DNS address #841

mengwei84 opened this issue Jan 4, 2024 · 0 comments
Labels

Comments

@mengwei84
Copy link

Describe the bug
I use DHCP service to assign IP and DNS addresses, and I operate as a client with DHCPClient. Although I can obtain the IP address, I am unable to retrieve the DNS server address when using the 'nslookup' command.

Here is DHCP service config:
auto-generated by DHCP service (utility.py)
NOTE: move these option lines into the desired pool { } block(s) below
#option domain-name "test.com";
option domain-name-servers 172.31.60.240;
#option routers 10.0.0.1;
log-facility local6;
default-lease-time 600;
max-lease-time 7200;
ddns-update-style none;
subnet 172.31.60.0 netmask 255.255.255.0 {
pool {
range 172.31.60.127 172.31.60.254;
default-lease-time 600;
option routers 172.31.60.252;
}
host mydevice {
hardware ethernet 00:1A:2B:3C:4D:5E;
fixed-address 172.31.60.128;
}
}

Here is DHCPClient config:
#!/bin/sh
#auto-generated by DHCPClient service (utility.py)
#uncomment this mkdir line and symlink line to enable client-side DNS
#resolution based on the DHCP server response.
#mkdir -p /var/run/resolvconf/interface
#ln -s /var/run/resolvconf/interface/eth0.dhclient /var/run/resolvconf/resolv.conf
/sbin/dhclient -nw -pf /var/run/dhclient-eth0.pid -lf /var/run/dhclient-eth0.lease eth0

Here is the operation in DHCPClient:
root@dhcpclient:/tmp/pycore.33285/dhcpclient.conf# nslookup

server
Default server: ::1
Address: ::1#53
Default server: 127.0.0.1
Address: 127.0.0.1#53

Desktop (please complete the following information):

  • OS: [Ubuntu 20.04]
  • CORE Version [8.2.0]
@mengwei84 mengwei84 added the bug label Jan 4, 2024
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

1 participant