Click to download Ethernet Basics manual - Grant Industrial Controls
Click to download Ethernet Basics manual - Grant Industrial Controls
Click to download Ethernet Basics manual - Grant Industrial Controls
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
The router 89<br />
of the network. On the other hand, the network interface also has a MAC address on the LAN<br />
side. The router will function as default gateway on the network.<br />
Figure 6.3: Linking of a private network <strong>to</strong> the Internet via a router<br />
A network can be linked <strong>to</strong> the Internet via the WAN interface of the router. For this purpose,<br />
the router, usually via DHCP, gets a unique IP address on the Internet from the ISP (Internet<br />
Service Provider).<br />
Every device on the network can now be configured as follows.<br />
IP address 172.23.22.14<br />
Subnetmask 255.255.0.0<br />
Default gateway 172.23.0.1<br />
Thus every participant gets an IP address where the Net ID for every participant is the same<br />
but the Host ID for every participant is unique.<br />
If an application on a PC on the network wants <strong>to</strong> start a communication with a Server on<br />
the Internet, then the PC first has <strong>to</strong> build a first IP packet <strong>to</strong> request the connection. This IP<br />
packet is sent on the Internet via the default gateway. The PC encapsulates the IP packet in<br />
an <strong>Ethernet</strong> frame for this purpose. Figure 6.4 shows the data that are required <strong>to</strong> make the<br />
<strong>Ethernet</strong> frame. The MAC address of the router is obtained via the ARP pro<strong>to</strong>col.<br />
Once the message has arrived at the router, this will forward the IP packet via the WAN<br />
interface <strong>to</strong> another router on the Internet. As the private network is separated from the<br />
Internet, the router will replace the source IP address of the PC with its IP address on the<br />
WAN side. The private network can only be reached via this external router IP address, via<br />
the Internet.<br />
The server can now send a reply and will address this reply <strong>to</strong> the external IP address of the<br />
router. A problem occurs now as the router will have <strong>to</strong> decide <strong>to</strong> which PC this message<br />
has <strong>to</strong> be sent. The Server’s response does not contain any data anymore with regard <strong>to</strong> the<br />
original sender IP NAT was developed <strong>to</strong> solve this problem.