Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I'm pxe booting a node (Ubuntu 11.10). The image of the node is created with debootstrap. Works great. Everything is loaded. When I login to the node I see that /etc/resolv.conf is empty. In the base image it's empty also but I expected the ubuntu boot process to fill it with a nameserver.

When, on the node, I do sudo service networkinging {start,restart} nothing changes to etc/resolv.conf. When I do a dhclient I get: RNETLINK answers: File exists but /etc/resolv.conf then contains the correct nameserver from my dhcp-server.

  • The linuxrc I use can be found on github.
  • (Part) of the bootscreen can be found on imgur.

I'd rather not add static entries to /etc/network/interfaces because I don't know if all the nodes have the same configuration. I'd rather have this more dynamic. If I'd add eth0 with a dhcp option to /etc/network/interfaces it works.

What am I doing wrong? Why doesn't ubuntu fill the /etc/resolv.conf on boot? Is there a network-manager kind of package for the commandline without too many dependencies?

share|improve this question

1 Answer 1

You state: "If I'd add eth0 with a dhcp option to /etc/network/interfaces it works."

Why not just use that? If there is no eth0 can there be an eth1?

Unless you need a special/local name server, you could add a constant group of name servers of the google name servers (8.8.8.8/8.8.4.4)

If you DO need a special/local one, and have some control over that you could make it very static and put that in there. (like 172.31.254.254,172.31.1.254)

I thought either you would have a static resolv.conf OR you would get it from your dhcp server.

If you can't get your pxe boot image to include the static one,you could add an /etc/rc.local ( or equiv for your distro ) that clobbers the values in place.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.