无线和有线网络接口 Windows 7 路由表

无线和有线网络接口 Windows 7 路由表

我的笔记本电脑已连接到 wifi 上网,并连接到以太网作为专用网络。我希望能够同时连接到两者。

我知道我的私有网络范围是 10.xxx,所以我在表中添加了一条路由规则

route add  10.0.0.0 mask 255.0.0.0 10.56.12.1  metric 3

这是路线打印输出

===========================================================================
Interface List
 22...80 19 34 ee e8 f0 ......Intel(R) Dual Band Wireless-N 7260 #3
 18...00 11 22 33 44 55 ......Intel(R) Ethernet Connection I218-LM
 27...02 b0 22 12 08 01 ......BlackBerry Virtual Private Network
 24...82 19 34 ee e8 f1 ......Microsoft Virtual WiFi Miniport Adapter #2
 23...82 19 34 ee e8 f0 ......Microsoft Virtual WiFi Miniport Adapter
 21...80 19 34 ee e8 f4 ......Bluetooth Device (Personal Area Network) #3
  1...........................Software Loopback Interface 1
 28...00 00 00 00 00 00 00 e0 Microsoft ISATAP Adapter
 30...00 00 00 00 00 00 00 e0 Microsoft ISATAP Adapter #3
 34...00 00 00 00 00 00 00 e0 Microsoft ISATAP Adapter #8
===========================================================================

IPv4 Route Table
===========================================================================
Active Routes:
Network Destination        Netmask          Gateway       Interface  Metric
          0.0.0.0          0.0.0.0       10.56.12.1     10.56.12.194     50
          0.0.0.0          0.0.0.0       172.27.0.1    172.27.41.169     40
         10.0.0.0        255.0.0.0       10.56.12.1     10.56.12.194     53
       10.56.12.0    255.255.255.0         On-link      10.56.12.194    276
     10.56.12.194  255.255.255.255         On-link      10.56.12.194    276
     10.56.12.255  255.255.255.255         On-link      10.56.12.194    276
        127.0.0.0        255.0.0.0         On-link         127.0.0.1    306
        127.0.0.1  255.255.255.255         On-link         127.0.0.1    306
  127.255.255.255  255.255.255.255         On-link         127.0.0.1    306
      169.254.0.0      255.255.0.0         On-link      169.254.0.97    261
     169.254.0.97  255.255.255.255         On-link      169.254.0.97    261
  169.254.255.255  255.255.255.255         On-link      169.254.0.97    261
       172.27.0.0      255.255.0.0         On-link     172.27.41.169    276
    172.27.41.169  255.255.255.255         On-link     172.27.41.169    276
   172.27.255.255  255.255.255.255         On-link     172.27.41.169    276
        224.0.0.0        240.0.0.0         On-link         127.0.0.1    306
        224.0.0.0        240.0.0.0         On-link      10.56.12.194    276
        224.0.0.0        240.0.0.0         On-link      169.254.0.97    261
        224.0.0.0        240.0.0.0         On-link     172.27.41.169    276
  255.255.255.255  255.255.255.255         On-link         127.0.0.1    306
  255.255.255.255  255.255.255.255         On-link      10.56.12.194    276
  255.255.255.255  255.255.255.255         On-link      169.254.0.97   9999
  255.255.255.255  255.255.255.255         On-link     172.27.41.169    276
===========================================================================
Persistent Routes:
  Network Address          Netmask  Gateway Address  Metric
        127.0.0.0        255.0.0.0        127.0.0.1       1
        127.0.0.1  255.255.255.255        127.0.0.1       1
  127.255.255.255  255.255.255.255        127.0.0.1       1
        224.0.0.0        240.0.0.0        127.0.0.1       1
  255.255.255.255  255.255.255.255        127.0.0.1       1
          0.0.0.0        255.0.0.0       10.56.12.1       3
===========================================================================

IPv6 Route Table
===========================================================================
Active Routes:
 If Metric Network Destination      Gateway
  1    306 ::1/128                  On-link
 27    261 fd00::/8                 On-link
 27    261 fd2c:238f:e5ae:8322:7d91:6a3:7dd7:6894/128
                                    On-link
 18    286 fe80::/64                On-link
 27    261 fe80::/64                On-link
 22    281 fe80::/64                On-link
 18    286 fe80::585d:cce3:fbac:ab6d/128
                                    On-link
 27    261 fe80::91df:d8be:fada:61/128
                                    On-link
 22    281 fe80::c180:3e55:cd90:ac32/128
                                    On-link
  1    306 ff00::/8                 On-link
 18    286 ff00::/8                 On-link
 27    261 ff00::/8                 On-link
 22    281 ff00::/8                 On-link
===========================================================================
Persistent Routes:
  None 

问题是,此设置仅允许私有网络访问,而没有互联网访问。我使用 wireshark 发现 DNS 查询通过 NIC 进行,但回复中没有答案

Chrome 使用 8.8.8.8 进行 DNS 查询,该查询被路由到 wifi,并且返回了答案,但仍然不显示页面。

我如何才能支持两个网络接口协同工作。

答案1

我成功了。结果发现我必须更加具体地指定通往以太网接口的路由。

所以,我必须定义一个路线对于每个 IP子网

例如:

route add 10.56.0.0 255.255.0.0
route add 10.36.0.0 255.255.0.0

以及消除默认路线:

route delete 0.0.0.0  255.0.0.0       10.56.12.1

相关内容