The current work environment cannot be connected to the Internet, but there are some wireless hotspots around, use a laptop to connect to the wireless network, you can access the Internet, but if you connect to the Intranet, you can not connect to the Internet, this is very troublesome, so I try to find some ways to solve this problem, so that the Intranet and the Internet can be connected at the same time (this will make the Intranet insecure, do not learn ).
After checking on the Internet, you can set a permanent route to solve the problem. I tried to solve the problem.
You do not need to set both the integrated network card and wireless network card, but you need to view some of their information in the "command window" by entering "route print.
For example
Interface list
12... 00 22 8d E7 42 E3 ...... Broadcom 802.11g Network Adapter
11 .. 00 22 9C A9 45 C9 ...... Broadcom Netlink (TM) Fast Ethernet
Note: My Wireless Network Card is 12 and the integrated network card is 11. This will be used later.
IPv4 route table
========================================================== ==========================================
Active route:
Network target network mask Gateway Interface hops
0.0.0.0 0.0.0.0 172.16.0.1 172.16.0.63 41
0.0.0.0 0.0.0.0 10.111.128.11 10.131.18.141 276
Note: The Gateway is the focus of the entire process. Here, my Intranet gateway is 10.111.128.11 and the wireless gateway is 172.16.0.1.
You can set it here.
First, "All Programs"-"attachments"-"command prompt" and Right-click "Run as administrator" to open the command window.
First clear the network target 0.0.0.0 and run the following command:Route Delete 0.0.0.0
Query the knowledge of Route commands by yourself,
Route Delete network target (some parameter filters can be added later, such as the network mask and gateway)
For example, route Delete 10.0.0.0 mask route 255.0.0 deletes the route with the network target 10.0.0.0 and its mask is 255.255.0.0.
Route Delete 10.0.0.0 mask route 255.0.0 192.168.1.1 Delete the route with the network target IP address 10.0.0.0, whose mask is 255.255.0.0 and the gateway is 192.168.1.1.
And so on, there are not many parameters followed by add.
Add a static route for the Intranet and run the following command:Route add-P 10.111.128.0 mask limit 255.255.0 10.111.128.11 if 11
10.111.128.0Intranet target network (originally written as follows: as long as it is not 0.0.0.0). After a period of use, we found that this is not set casually, if the IP address of the Intranet machine I want to access is 10.111.128. *, and the mask below is 255.255.255.0, so my target network must be 10.111.128.0. If I still need to access the Intranet IP address 10.111.129. * machine. I need to add another static route. The target network is 10.111.129.0.
Add route
-The route added by P is static and exists after restart.
0.0.0.0 wireless connection network target, in order to give priority to the Internet, so the 0.0.0.0 to it
Mask 255.255.255.0 is related to the specific Intranet settings.
10.111.128.11 the gateway connected to the Intranet. This cannot be an error.
If 11 11 is an integrated Nic interface, the interface shown in the preceding Query
Note that the gateway and interface cannot be wrong. The Gateway is the key point. In the future, when both the Intranet and Internet exist, the Intranet CIDR blocks to be accessed must be set to static routes, restart After the configuration is complete. This step cannot be omitted.
"Network and sharing center"-> "Change adapter Settings". In this window, press "Alt" to display the menu, and choose "advanced"-> "Advanced Settings ", the "Advanced Settings" dialog box is displayed. The "connection" box in the "adapter and binding" tab is displayed. The "connection" box contains the access order of the connections, the specific sequence is shown in the following two figures:
Enter "route print" in the "command window" to check the 0.0.0.0 status.
Network target network mask Gateway Interface hops
0.0.0.0 0.0.0.0 10.111.128.11 10.131.18.141 276
0.0.0.0 0.0.0.0 172.16.0.1 172.16.0.63 25
Note the number of hops in it. The lower the number of hops, the higher the priority. In my case, the first record is intranet, the second record is Internet, and the second record is low, I can access the Internet smoothly.
If not, you need to manually set up the connection. In "Advanced TCP/IP Settings", deselect the check mark before "automatic hops, enter a value in the input box next to "interface hops (n):". For example, if my wireless network adapter inputs 10, the integrated network adapter inputs 150, enter "route print" in the "command window" to check the 0.0.0.0 status.
Network target network mask Gateway Interface hops
0.0.0.0 0.0.0.0 10.111.128.11 10.131.18.141 150
0.0.0.0 0.0.0.0 172.16.0.1 172.16.0.63 10
Give it a try. You should have done it !!!!
Bytes ----------------------------------------------------------------------------------------------
Remove the "Internet Protocol version 6 (TCP/IPv6)" check box in the local connection and wireless connection attributes !!! After confirming, disable connections and then enable them. The above settings are for IPv4. If IPv6 is enabled, the rules in the settings are not applicable to IPv6 !!
Here, we need to say that after we have completed these steps, your intranet speed is much slower than before, especially for large file operations. Of course, remote connection and other operations have little impact!