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.

I have an Ubuntu 10.04 LTS server with 2 network cards, an internal IP on one card (eth1) and external IPs (aliased) on the other card (eth0). I suddenly lost connection the public interface and I rebooted the server but I still could not connect to the public IPs although I could ssh using the internal IP. I could not ping my default gateway and I tried to restart networking with /etc/init.d/networking restart and got the error "SIOCSIFFLAGS: cannot assign requested IP" and "Failed to bring up eth0". A workaround was to add

ifconfig eth 0 x.x.x.x

route -add default gw x.x.x.z

I could then connect to the public network.

My /etc/network/interfaces file is shown below:

iface eth0 inet static

        address x.x.x.r
        netmask z.z.z.z.0
        broadcast x.x.x.z
        network x.x.x.0
        gateway x.x.x.a
iface eth0:1 inet static

    address x.x.x.b

    netmask z.z.z.192

auto eth0:1

iface eth0:2 inet static

       address x.x.x.f

    netmask z.z.z.z.192

auto eth0:2

The obvious thing that stands out is the auto eth0:1 that I see configured when the interface has been defined as static in the first place. Could this contradictory configuration be the issue? Any ideas will help because my network configurations will be lost on reboot.

share|improve this question
    
Sorry about that, I have made an appropriate title now. I have a lot of questions I am posting so had mixed up the titles. –  Paddington Oct 19 '12 at 11:11
    
The "auto eth0" stanza merely tells the OS to auto-start the network interface on boot. –  adaptr Oct 19 '12 at 15:25
add comment

Your Answer

 
discard

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

Browse other questions tagged or ask your own question.