[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [Libguestfs] Name resolution not working inside virt-customize

On Fri, Mar 13, 2015 at 11:28:56AM -0400, Lee Revell wrote:
> On 03/13/2015 11:13 AM, Richard W.M. Jones wrote:
> >
> >Yes, the log indicates name resolution not working.  Please try the
> >diagnosis steps that I outlined in:
> >
> >https://www.redhat.com/archives/libguestfs/2015-March/msg00075.html
> Sorry, I somehow missed the above message.
> $ ./run guestfish get-backend
> direct
> Here are the outputs of the /dev/tcp test, first doing:
> $ ./run guestfish -v -x --network -a /dev/null run : debug sh 'exec
> 3<> /dev/tcp/google.com/80 ; echo -e "GET /\n" >&3 ; cat <&3'
> And then by IP:
> $ ./run guestfish -v -x --network -a /dev/null run : debug sh 'exec
> 3<> /dev/tcp/ ; echo -e "GET /\n" >&3 ; cat <&3'
> Both fail...

So what's happening is that /etc/resolv.conf in the appliance never
gets created.

*If* /etc/resolv.conf had been created then we should see evidence
that this code had been run:


(eg. the "renaming ... to ..." messages should appear).

Question is why does /etc/resolv.conf not get created?

On Fedora, it is created by dhclient running from appliance/init:


On Debian/Ubuntu that is supposed to run dhclient if available or
dhcpcd if not.

Run `./run virt-rescue --network --scratch' on the Ubuntu host and see if:

 - either dhclient or dhcpcd exists in the appliance

 - they work when you run them, or if there is an error message

 - if running one of them creates /etc/resolv.conf

I don't see any error in the log from either dhclient or dhcpcd, so I
have to assume that one of them ran, but perhaps there is some other

Also perhaps the packagelist (appliance/packagelist.in) doesn't list
the right package containing dhclient/dhcpcd.

Also maybe a different dhcp client is needed.


Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-builder quickly builds VMs from scratch

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]