Bug 470391

Summary: dnsmasq DNS returns 127.0.0.1 for lookup of host
Product: [Fedora] Fedora Reporter: Bill Nottingham <notting>
Component: dnsmasqAssignee: Patrick Laughton <jima>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: 10CC: berrange, clalance, crobinso, jima, markmc, rvokal, veillard, virt-maint
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-06-11 14:13:03 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Bill Nottingham 2008-11-06 23:08:14 UTC
Description of problem:

I'm in my qemu/kvm virt guest. I want to scp some files out to the host. So, I do
scp blah <my host machine's hostname>. However, that's coming back as 127.0.0.1.

# nslookup 127.0.0.1
Server: 192.168.122.1
Address: 192.168.122.1#53

1.0.0.127.in-addr.arpa name = <host name>

I assume this is due to the dnsmasq config that libvirtd is using.

Version-Release number of selected component (if applicable):

virt-manager-0.6.0-3.fc10.x86_64
libvirt-0.4.6-3.fc10.x86_64
dnsmasq-2.45-1.fc10.x86_64

Comment 1 Bug Zapper 2008-11-26 04:56:03 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 10 development cycle.
Changing version to '10'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 2 Mark McLoughlin 2009-01-21 10:56:48 UTC
Confirmed, moving to dnsmasq

Perhaps if dnsmasq is run with --listen-address, it could always return that address instead of 127.0.0.1 ?

Example dnsmasq cmdline:

/usr/sbin/dnsmasq --keep-in-foreground --strict-order --bind-interfaces --pid-file  --conf-file  --listen-address 192.168.122.1 --except-interface lo --dhcp-leasefile=/var/lib/libvirt/dhcp-default.leases --dhcp-range 192.168.122.2,192.168.122.254

Comment 3 Patrick Laughton 2009-06-10 12:35:45 UTC
Uh, Bill?  Is that host on a line with 127.0.0.1 in /etc/hosts?  Because that's where dnsmasq serves up its DNS from.

Comment 4 Bill Nottingham 2009-06-10 15:49:18 UTC
Yes.

Comment 5 Patrick Laughton 2009-06-11 14:13:03 UTC
Oh-kay!  I apologize for overlooking this bug for so long, Bill.  Alas, it's a configuration issue; you need to have the correct IP for the hostname in question in /etc/hosts.

Closing as NOTABUG, sorry again for the delay.