1. You are viewing our forum as a guest. For full access please Register. WindowsBBS.com is completely free, paid for by advertisers and donations.

Using more network interfaces

Discussion in 'Networking (Hardware & Software)' started by zenitse, 2006/09/14.

  1. 2006/09/14
    zenitse

    zenitse Inactive Thread Starter

    Joined:
    2006/09/14
    Messages:
    2
    Likes Received:
    0
    Hello,

    on my notebook, I use (at least) two network Interfaces. Both of them are connected to the Internet - ethernet and wifi.

    By default, when I send some request to the Internet, the connection first connected is used. But I would like to use them both. How can I define, which application should use which network interface?

    Thanks
     
  2. 2006/09/14
    TonyT

    TonyT SuperGeek Staff

    Joined:
    2002/01/18
    Messages:
    9,072
    Likes Received:
    400
    The application itself MUST contain a setting to choose the network interface to use, else it will use the interface chosen by the operating system. Thus you would have to disconnect & reconnect interfaces in order to switch which one is being used.
     

  3. to hide this advert.

  4. 2006/09/14
    zenitse

    zenitse Inactive Thread Starter

    Joined:
    2006/09/14
    Messages:
    2
    Likes Received:
    0
    Ah, I see, thanks.

    And how can I make this settings, while developing my application? I am quite experienced programming with socket, but I don't recall anything about this possibility.
     
  5. 2006/09/14
    Bill Castner

    Bill Castner Inactive

    Joined:
    2006/08/30
    Messages:
    1,980
    Likes Received:
    0
    Are you using automatic metrics on the interfaces?
    This pretty much will determine how the interface choice is made.

    I should note that this is a substantial security breach if you are using one outward interface to the internet and one for the LAN.

    Finally, you have to be careful in a Windows network enviornment that the workstation does not appear multi-homed.

    You can do some clever things with ad hoc wireless networking in this circumstance, including ICS.

    In short, I am not sure why you would do this. Any performance or other adavantages seem suspect to me.

    But Joseph Davies, "The Cable Guy ", at Microsoft (and much more), has some valuable thoughts: http://www.microsoft.com/technet/community/columns/cableguy/cg0405.mspx
     
  6. 2006/09/14
    ReggieB

    ReggieB Inactive Alumni

    Joined:
    2004/05/12
    Messages:
    2,786
    Likes Received:
    2
    Where you have two network interfaces connected to the same network, the setting that controls which one is used is the binding order. See this thread.

    If you connect two interfaces to the same network there is the very real possibility that you will get broadcast problems. Basically, when a broadcast is sent out on one connection, there is nothing to stop it coming back into the system on the other network card. You then get into the situation where a computer will respond to itself without realising, causing all sorts of problems. You can create teams of cards, but that takes special configuration in the network card drivers and often is only available with more expensive server network cards.

    So in your situation, you can only use one connection at a time. Which one is used is controlled by the binding order. The highest active connection in the binding order is always chosen.
     
  7. 2006/09/15
    Bill Castner

    Bill Castner Inactive

    Joined:
    2006/08/30
    Messages:
    1,980
    Likes Received:
    0
    Binding order determines protocol order, and rarely anything else in the setting described by the original poster.

    Since TCP/IP is bound on both adapters it is largely the Metric that will determine the interface chosen, (although see the "rules" below).
    To check, do a ROUTE PRINT. For the standard case of a Multi-homed workstation as in the case of the question asked by "zenitse" above, the "Rules " that are followed would be:

    Binding order will play no role in determining the interface used.
     
    Last edited: 2006/09/15
  8. 2006/09/16
    ReggieB

    ReggieB Inactive Alumni

    Joined:
    2004/05/12
    Messages:
    2,786
    Likes Received:
    2
    An interesting read. However, these rules assume that the multi-homes PC is using a different subnet for each connection. In my experience most small networks don't work this way. The wired and wireless connections connect to the same subnet (e.g. 192.168.1.0). So:

    This statement is only relevant if the NIC connect to different subnets. Say the NIC addreses are 10.0.0.1 and 192.168.0.1. A PC 192.168.0.2 would connect to the 192.168.0.1 NIC. A PC on 10.0.0.3 would connect to the 192.168.0.1 NIC. However, in the situation where both NIC use the same subnet (NIC IPs 192.168.0.10 and 192.168.0.150), this rule provides no way for an incoming system to decide which NIC to connect to.

    So in this case traffic could be in coming on either NIC. Good point. It means that binding order is not going to stop traffic coming in to a wireless NIC.

    Again, see note above concerning the problem in that both share the common network. That is, that the network is not only common between the sender and receiver, but also both receivers.

    Same subnet = same routing. Binding order will control order in the routing table. Again, on small networks the IP address is given out by a wireless router. Same DHCP and it will give out the same metric to both NICs.

    And so we get to

    See also:
    http://support.microsoft.com/default.aspx?scid=kb;en-us;299540

    Yes, you are right. This feature should sort out this problem. However, in my experience it doesn't.

    I've played around with this for a while. My main network uses a single DHCP server hosted on a 2003 server. I have two Wireless Access points providing roaming access for some laptop users. I had a number of problems with these users complaining of poor performance when they returned to their desks and plugged into the wires network. Sorting out the binding order fixed the problem.

    Which brings me back to my main point: for most small networks that have a single DHCP (often the internet router) binding order makes an impact on which NIC is used when the wireless enabled laptops are connected to the wired network.
     
  9. 2006/09/16
    Bill Castner

    Bill Castner Inactive

    Joined:
    2006/08/30
    Messages:
    1,980
    Likes Received:
    0
    Case #1, different subnets
    Conclusion: Binding order does not matter

    Case #2, same subnet
    Conclusion: Binding order does not matter

    Case #3: initiate traffic, different subnets
    Conclusion: Binding order does not matter

    Case #4: initiate traffic same subnet
    Conclusion: Binding order does not matter

    DHCP provides neither metric nor binding order information to the client. The only instance in which these would be identical for a wired and wireless client would be pilot error on the part of the network administrator or network user.

    This again repeats your earlier mistake - DHCP has nothing to do with assigning the metrics for the wired and wireless interfaces. DHCP has nothing to do with binding order assignment. DHCP does not create, modify or influence the routing table for a network client through the control of route metrics or route priority.

    However, I am conscious of the fact that not just you and the poster read these postings. I therefore think it is right for me to highlight an obvious mistake in your posting so that others reading these postings are not also misled by your inaccurate claims about the role of binding order.
     
    Last edited: 2006/09/16
  10. 2006/09/16
    ReggieB

    ReggieB Inactive Alumni

    Joined:
    2004/05/12
    Messages:
    2,786
    Likes Received:
    2
    DHCP will not assign metrics; that is true. But DHCP will assign the default route (and very occasionally other routes). In a standard non XP network that means that the network systems will be left to sort out metrics via ICMP.

    XP adds in the Automatic Metric "feature ". In theory this will sort the problem out. Where I think we are in disagreement is that you believe it works and I don't. In my experience is does not work.

    If Automatic Metrics worked properly a laptop connected to the same subnet via wireless and wired NICs would always use the wired connection for outgoing connections. However, they don't. They use the last installed device in preference. And that's usually the wireless NIC. The only way I have found to over-ride this behaviour is to correct the binding order and bind the wired NIC above the wireless one.

    :D Excellent. I congratulate you for throwing my own conceit back in my face. Splendid. :D
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.