Learn from me-how to make your computer a router

Source: Internet
Author: User

See the headline, you don't think this is about routing simulation software?

No, that is a common terminal, but also a single network card machine.

You might say that a single NIC machine is not surprising, like Cisco single arm routing.

But here is a machine that is more common, even the Win95 that has just been installed.

......

In fact, the IP protocol in a stand-alone basic operation, this article is more one-sided, because the IP protocol in the terminal operating mechanism is not a profound understanding.

IP protocol installed on the computer, it becomes the cornerstone of your Internet access, each step of the connection, each step to explore, by the IP protocol group in the behind-the-scenes Ancheng.

IP protocol installation is to and network interface (network INTERFACE) binding, that is, with the network adapter with the installation, such as: MODEM network card, virtual network adapter, VPN network adapter, dial-up network adapter and so on.

IP protocol after installation, will create a stack for network connections, create a 127.0.0.x local loop for themselves, automatically get or wait for users to manually set an IP address, to the network to publish their own and explore the adjacent protocol carrier, listening to the data packets from the network, according to the IP attribute set Dhcp,dns, Gateway and other network rules communication.

There is no direct exchange between different segments of the Internet, the use of router packet forwarding function to solve, the rule is based on an automatic or manual routing information table.

In fact, there is a packet forwarding process inside a single machine, Route command can show us a Routing information table:

C:\winnt\system32>route PRINT

===============================================================
Interface List
0x1 ........................... MS TCP Loopback interface
0x4000003 ... XX xx A8 xx C7 ... Intel (R) PRO Adapter
===============================================================
===================== ==========================================
Active Routes:
Network destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 192.168.0.1 192.168.0.111 1
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
192.168.0.0 255.255.255.0 192.168.0.111 192.168.0.111 1
192.168.0.111 255.255.255.255 127.0.0.1 127.0.0.1 1
192.168.0.255 255.255.255.255 192.168.0.111 192.168.0.111 1
224.0.0.0 224.0.0.0 192.168.0.111 192.168.0.111 1
255.255.255.255 255.255.255.255 192.168.0.111 192.168.0.111 1
Default gateway:192.168.0.1
================================== =============================
Persistent Routes:
None

This table tells us how the stand-alone IP protocol is to maintain the forwarding of different network packets, perhaps you will think that the PC should only exist in a network segment, macroscopic look is like this, but here is a microscopic view from the agreement inside.

In the internal environment, computer work-related network segments are:

1:255.255.255.255 255.255.255.255 192.168.0.111 192.168.0.111 1

Network-oriented broadcast, no matter what network segment you are, LAN or Internet, there is this network segment. He is the basis for this computer to communicate with the IP environment around it.

2:224.0.0.0 224.0.0.0 192.168.0.111 192.168.0.111 1

The multicast address (multicast) is also the Discovery network. A multicast address uses the protocols or devices represented by a different multicast address to identify the network environment.

3:192.168.0.255 255.255.255.255 192.168.0.111 192.168.0.111 1

The broadcast address of the network on which this computer resides. His presence is the basis for communicating with machines in the same network segment.

4:192.168.0.111 255.255.255.255 127.0.0.1 127.0.0.1 1

The computer itself IP accesses the loop of its own IP. This route defines that if the computer accesses its own IP and does not pass through another gateway, it accesses itself directly via the 127.0.0.1 local loop IP. The equivalent of their own gateway.

5:192.168.0.0 255.255.255.0 192.168.0.111 192.168.0.111 1

The network address on which this computer resides represents a network segment.

6:127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1

The fixed address of the local loop specified by the IP protocol. As long as the IP protocol is installed, you can use 127. X.x.x visited himself. For the unification of the numbers, 127.0.0.1 represents themselves.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.