How do I configure 2nd NIC in Ubuntu Server

Discussion in 'Installation/Configuration' started by golfnut, Apr 30, 2010.

  1. golfnut

    golfnut New Member

    I recently installed Ubuntu Server 9.1 on a new box with an Intel 82576 network controller with dual ports. When I first installed I only configured one of the ports but I think I want to configure the second one now. What is the process for doing this?
  2. dfed

    dfed New Member

    How are you looking to configure them? separate nics on the same subnet? ganged together? failover? separate nics on different subnets?
  3. golfnut

    golfnut New Member

    I would like them to be seperate nics on the same subnet.
  4. falko

    falko Super Moderator ISPConfig Developer

    What's in /etc/network/interfaces?
  5. dfed

    dfed New Member

    Well aside from setting up the ifconfig for each, Linux by default sets arp_filter to 0 (The kernel can respond to arp requests with addresses from other interfaces.)

    So you'll need to add:

    net.ipv4.conf.default.arp_filter = 1

    to /etc/sysctl.conf

    and add to local.start:

    ip route add default via ${GATEWAY} dev $(NIC2_DEV} table TABLE1
    ip rule add from ${NIC2_IP} table TABLE1

    I assume you're doing this to dedicate a nic to a VM or some such.

    Stole this info from here:
  6. Schuby

    Schuby New Member


    Sorry to bring this thread back but I have a similar question.

    I'm building a Counter Strike: Source game server (gonna use Ubuntu Server 10.04) and I'm looking at getting the Intel E1G42ET PCI-Express, dual port 82576 Gigabit Ethernet Controller and I'm wondering if it will be recognized right out of the box or if I'll have to do some setup?? I plan on disabling my motherboard's NIC prior to installation.

    Also how can I set this card up so that one of the ports will connect to the internet and the other port I can connect to my LAN and share the internet to the LAN?

    I know this is a really n00b question, I'm very new to this. If someone could at least point me in the right direction, I would really appreciate it.

    Thank you.

Share This Page