Solved

concurrent connection to Wireless / WiFi & wired LAN : difference between Windows route add , Unix route add & Cisco ip route

Posted on 2010-08-24
3
1,730 Views
Last Modified: 2012-05-10
I have a laptop which is connected to the wired LAN but whenever I wanted
to use WiFi, I have to detach the wired LAN &  otherwise the WiFi signal
will affected / dropped.  Looks like at any one time only one can be used.

I want to have both connections on at the same time & found the following
thread in EE about tweaking the routing table to enable this:
(I suppose from the article below, since the wired LAN is only for access to a few
 private internal subnets while the WiFi is for numerous subnets access, I should
 set a static route for the wired LAN & a default gateway for the WiFi) :


> XP itself allows you to use wireless and wired connections simultaneously. Are the connections
> physically dropping or is it that you cannot access one  network once connecting to the other
> network? When you are connected to two networks on separate network adapters, you should
> ensure only one adapter has a default gateway or your laptop will get confused where to route
> unknown networks.

> On your wired LAN connection with the static address, remove the gateway.

> Then add a persistent static route for your wired LAN at Windows prompt
>   Start--> Run --> CMD
>   route ADD 172.16.2.0 MASK 255.255.255.0  172.16.13.254 -P
>                              ^destination network                    ^ next hop address (gateway)

Problem is the above "route add ..." command fails with the error message below where
172.16.13.254 is the next hope gateway for my wired LAN's subnet:
    The route addition failed: Either the interface index is wrong or the gateway
    does not lie on the same network as the interface. Check the IP Address Table
    for the machine.


However, if I use the IP addr of the wired NIC as gateway in the "route add..." command
as follows, Windows allows me to add, ie :
  route add 172.16.2.0 MASK 255.255.255.0 172.16.13.184 -P

But the above static/persistent route does not help me gain access to a svr
 on the 172.16.2.0 subnet, eg I'm trying ssh to 172.16.2.6.  The moment
I set the default gateway as 172.16.13.254 on the wired LAN NIC, ssh
access to 172.16.2.6 (or 172.16.2.0/24 subnet) works.


So I believe the reason why my laptop can't access the wired private LAN &
WiFi together at the same time because the type of "static routes" or persistent
route that are seen in Unix or Cisco router ( ie whereby the next hop default
gateway is used in static routes) are not permitted in Windows XP

Below is the routing table from "route print" command :
Active Routes:
Network Destination        Netmask          Gateway       Interface  Metric
          0.0.0.0          0.0.0.0    192.168.205.1  192.168.207.172      25
        127.0.0.0        255.0.0.0        127.0.0.1       127.0.0.1       1
      169.254.0.0      255.255.0.0  192.168.207.172  192.168.207.172      20
       172.16.0.0      255.255.0.0    172.16.13.184   172.16.13.184       20
    172.16.13.184  255.255.255.255        127.0.0.1       127.0.0.1       20
   172.16.255.255  255.255.255.255    172.16.13.184   172.16.13.184       20
    192.168.205.0    255.255.252.0  192.168.207.172  192.168.207.172      25
  192.168.207.172  255.255.255.255        127.0.0.1       127.0.0.1       25
  192.168.207.255  255.255.255.255  192.168.207.172  192.168.207.172      25
        224.0.0.0        240.0.0.0    172.16.13.184   172.16.13.184       20
        224.0.0.0        240.0.0.0  192.168.207.172  192.168.207.172      25
  255.255.255.255  255.255.255.255    172.16.13.184   172.16.13.184       1
  255.255.255.255  255.255.255.255    172.16.13.184           20005       1
  255.255.255.255  255.255.255.255  192.168.207.172  192.168.207.172      1
Default Gateway:     192.168.205.1
===========================================================================
Persistent Routes:
  None

What I can't figure out was :
if I use a Unix box instead of my Win XP PC, I'm able to add the
static (ie Persistent route in Windows) route as follows :
  route add 172.16.2.0 mask 255.255.255.0 172.16.13.254
but the above command (with -P at the end) won't be accepted
in Windows.


So anyone has any suggestions to enable my laptop to be able
to access the wired private LAN & the WiFi at the same time


0
Comment
Question by:sunhux
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 15

Assisted Solution

by:greg ward
greg ward earned 150 total points
ID: 33513210
You need to put the ip address of a device on the same subnet as the network adapter.
And dont use -p until you have worked out the route is right!
route print to see hwat the table looks like.
 
Greg
0
 
LVL 4

Accepted Solution

by:
Dave773 earned 350 total points
ID: 33513339
The solution is fairly simple... for every network/host you want to access through the wired or wireless LAN, you will have to add a static route pointed to the respective gateway of the connection through which you want the traffic to go through.
The only thing left to choose is traffic that needs to take a default gateway. You can only have one default gateway if your wired/wireless connections are on two different networks. If you're using DHCP, the default gateway will be chosen for you, unless you use static IPs and configure the default gateway manually.
Oh, and if you want to make a static route persistent in Windows, it's -p (Lowercase P)
 
0
 

Author Comment

by:sunhux
ID: 33518753
Hi Dave,

Ok, I've just found out that before I can add a static route for the wired LAN/subnet,
the cable needs to be plugged into the wired LAN port first, otherwise I would get the
error below:

  c:\>route add 172.16.1.0 MASK 255.255.255.0 172.16.13.254 -p
The route addition failed: Either the interface index is wrong or the gateway do
es not lie on the same network as the interface. Check the IP Address Table for
the machine.



Hi Greg

The "route print" has been given earlier in the 1st post,
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
EIGRP STUB 19 99
Local DNS and Home Routers 4 58
Windows Server 2016 - Root Hints are not keeping their IPv4 addresses 3 95
Dlink-DIR 816 router 4 44
Quality of Service (QoS) options are nearly endless when it comes to networks today. This article is merely one example of how it can be handled in a hub-n-spoke design using a 3-tier configuration.
Configuring network clients can be a chore, especially if there are a large number of them or a lot of itinerant users.  DHCP dynamically manages this process, much to the relief of users and administrators alike!
Windows 8 came with a dramatically different user interface known as Metro. Notably missing from that interface was a Start button and Start Menu. Microsoft responded to negative user feedback of the Metro interface, bringing back the Start button a…
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question