Thanks for the diagnostic command.  It works ok in my local network,
could it be something to do with the way you're configuring your
hostname?  Perhaps it would help if you could explain how you're
configuring your system, or show a test case that demonstrates the
problem in a vanilla lxc container or similar, so we could reproduce
what you're seeing.

stirling:~$ name="$(hostnamectl | grep "Static hostname:" | cut -d: -f2 | 
xargs)"
stirling:~$ nslookup "${name}"
Server:         127.0.0.53
Address:        127.0.0.53#53

Non-authoritative answer:
Name:   stirling
Address: 192.168.1.42


** Description changed:

  Starting Ubuntu 16.10 resolution of LAN addresses fails.   This name
  resolution failure is evident in every post 16.0 Ubuntu & derivative
  that I have tested.   See below - which shows 16.04 resolves, 18.04 and
  Pop!_OS 19.04 fail, and other distros - Fedora 31, openSUSE Leap 15.1,
  and Debian GNU/Linux 10 (buster) - all resolve as expected.
  
  == Test Case ==
+ $ name=$(hostnamectl | grep Name: | cut -d: -f2 | xargs)
+ $ echo "${name}"
  $ hostnamectl | grep System
  $ hostnamectl | grep Kernel
  $ nmcli dev show | grep DNS
- $ nslookup BGOWIKI01v
+ $ nslookup "${name}"
  
  == Additional Information ==
  Operating System: Ubuntu 16.04.6 LTS
             Kernel: Linux 4.4.0-170-generic
   IP4.DNS[1]:                             192.168.3.2
   Server:        127.0.1.1
   Address:   127.0.1.1#53
   Name:  BGOWIKI01v
   Address: 192.168.3.60
   ============================================================================
   Operating System: Ubuntu 18.04.3 LTS
              Kernel: Linux 4.15.0-72-generic
   IP4.DNS[1]:                             192.168.3.2
   Server:        127.0.0.53
   Address:   127.0.0.53#53
   ** server can't find BGOWIKI01v: SERVFAIL
   ============================================================================
   Operating System: Pop!_OS 19.04
              Kernel: Linux 5.0.0-21-generic
   IP4.DNS[1]:                             192.168.3.2
   Server:        127.0.0.53
   Address:   127.0.0.53#53
   ** server can't find BGOWIKI01v: SERVFAIL
   ============================================================================
   Operating System: Fedora 31 (Workstation Edition)
              Kernel: Linux 5.3.7-301.fc31.x86_64
   IP4.DNS[1]:                             192.168.3.2
   Server:        192.168.3.2
   Address:   192.168.3.2#53
   Name:  BGOWIKI01v
   Address: 192.168.3.60
   ============================================================================
   Operating System: openSUSE Leap 15.1
              Kernel: Linux 4.12.14-lp151.28.36-default
   IP4.DNS[1]:                             192.168.3.2
   Server:        192.168.3.2
   Address:   192.168.3.2#53
   Name:  BGOWIKI01v
   Address: 192.168.3.60
   ============================================================================
   Operating System: Debian GNU/Linux 10 (buster)
              Kernel: Linux 4.19.0-6-amd64
   IP4.DNS[1]:                             192.168.3.2
   Server:        192.168.3.2
   Address:   192.168.3.2#53
   Name:  BGOWIKI01v
   Address: 192.168.3.60
  
  ProblemType: Bug
  DistroRelease: Ubuntu 18.04
  Package: dnsutils 1:9.11.3+dfsg-1ubuntu1.11
  ProcVersionSignature: Ubuntu 4.15.0-72.81-generic 4.15.18
  Uname: Linux 4.15.0-72-generic x86_64
  ApportVersion: 2.20.9-0ubuntu7.9
  Architecture: amd64
  CurrentDesktop: MATE
  Date: Sat Feb  8 17:36:28 2020
  InstallationDate: Installed on 2019-12-22 (47 days ago)
  InstallationMedia: Ubuntu-MATE 18.04 LTS "Bionic Beaver" - Release amd64 
(20180426)
  SourcePackage: bind9
  UpgradeStatus: No upgrade log present (probably fresh install)

** Description changed:

  Starting Ubuntu 16.10 resolution of LAN addresses fails.   This name
  resolution failure is evident in every post 16.0 Ubuntu & derivative
  that I have tested.   See below - which shows 16.04 resolves, 18.04 and
  Pop!_OS 19.04 fail, and other distros - Fedora 31, openSUSE Leap 15.1,
  and Debian GNU/Linux 10 (buster) - all resolve as expected.
  
  == Test Case ==
- $ name=$(hostnamectl | grep Name: | cut -d: -f2 | xargs)
+ $ name=$(hostnamectl | grep "Static hostname:" | cut -d: -f2 | xargs)
  $ echo "${name}"
  $ hostnamectl | grep System
  $ hostnamectl | grep Kernel
  $ nmcli dev show | grep DNS
  $ nslookup "${name}"
  
  == Additional Information ==
  Operating System: Ubuntu 16.04.6 LTS
             Kernel: Linux 4.4.0-170-generic
   IP4.DNS[1]:                             192.168.3.2
   Server:        127.0.1.1
   Address:   127.0.1.1#53
   Name:  BGOWIKI01v
   Address: 192.168.3.60
   ============================================================================
   Operating System: Ubuntu 18.04.3 LTS
              Kernel: Linux 4.15.0-72-generic
   IP4.DNS[1]:                             192.168.3.2
   Server:        127.0.0.53
   Address:   127.0.0.53#53
   ** server can't find BGOWIKI01v: SERVFAIL
   ============================================================================
   Operating System: Pop!_OS 19.04
              Kernel: Linux 5.0.0-21-generic
   IP4.DNS[1]:                             192.168.3.2
   Server:        127.0.0.53
   Address:   127.0.0.53#53
   ** server can't find BGOWIKI01v: SERVFAIL
   ============================================================================
   Operating System: Fedora 31 (Workstation Edition)
              Kernel: Linux 5.3.7-301.fc31.x86_64
   IP4.DNS[1]:                             192.168.3.2
   Server:        192.168.3.2
   Address:   192.168.3.2#53
   Name:  BGOWIKI01v
   Address: 192.168.3.60
   ============================================================================
   Operating System: openSUSE Leap 15.1
              Kernel: Linux 4.12.14-lp151.28.36-default
   IP4.DNS[1]:                             192.168.3.2
   Server:        192.168.3.2
   Address:   192.168.3.2#53
   Name:  BGOWIKI01v
   Address: 192.168.3.60
   ============================================================================
   Operating System: Debian GNU/Linux 10 (buster)
              Kernel: Linux 4.19.0-6-amd64
   IP4.DNS[1]:                             192.168.3.2
   Server:        192.168.3.2
   Address:   192.168.3.2#53
   Name:  BGOWIKI01v
   Address: 192.168.3.60
  
  ProblemType: Bug
  DistroRelease: Ubuntu 18.04
  Package: dnsutils 1:9.11.3+dfsg-1ubuntu1.11
  ProcVersionSignature: Ubuntu 4.15.0-72.81-generic 4.15.18
  Uname: Linux 4.15.0-72-generic x86_64
  ApportVersion: 2.20.9-0ubuntu7.9
  Architecture: amd64
  CurrentDesktop: MATE
  Date: Sat Feb  8 17:36:28 2020
  InstallationDate: Installed on 2019-12-22 (47 days ago)
  InstallationMedia: Ubuntu-MATE 18.04 LTS "Bionic Beaver" - Release amd64 
(20180426)
  SourcePackage: bind9
  UpgradeStatus: No upgrade log present (probably fresh install)

** Changed in: bind9 (Ubuntu)
       Status: New => Incomplete

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1862437

Title:
  Ubuntu 16.10 & later, & derivatives do not query the assigned DNS
  server

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bind9/+bug/1862437/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to