Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

How do I get Ubuntu to figure out the interfaces available on my computer and generate a new /etc/network/interfaces file? It created it the first time so I know it can somehow.

Is there something like dpkg-reconfigure <what?> that would just recheck for me?

share|improve this question
1  
What would you want this for? –  Zoredache Jul 1 '10 at 1:35
    
I'm +1-ing this question because we need non-linux people to be able to configure networks for our appliance. Something e.g. curses based that makes it easy is what I'm looking for... –  Peter V. Mørch Jan 13 '12 at 9:53

3 Answers 3

in ubuntu 14.04.1 THIS happens if you clone a system to other hardware as /etc/udev/rules.d/70-persistent-net.rules contains MAC address's of ethernet hardware on the source computer.

YES - just deleting /etc/udev/rules.d/70-persistent-net.rules allows things to be refreshed to a working state at reboot.

share|improve this answer

/etc/network/interfaces is generated by the actual installer, not any of the packages on your system:

opus:~ broder$ dpkg -S /etc/network/interfaces
dpkg: /etc/network/interfaces not found.

Because it's not managed by any particular package, no package is going to modify the file.

If you want to add new interfaces to /etc/network/interfaces, you have to do that manually. Alternatively, if you want your network interfaces to be managed automatically by your system, I believe the official answer at this point is to use NetworkManager. NetworkManager will handle configuration for any network interface that's not listed in /etc/network/interfaces.

share|improve this answer

dpkg-reconfigure ifupdown

possibly.

However, you are probably running into an issue with udev. If you have rebooted, and eth0 disappeared:

ifconfig -a

you can mv/rm the file in /etc/udev/rules.d/70-persistent-net.rules and reboot, and your primary ethernet card should become eth0 again.

This would happen if you switched motherboards/network cards.

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.