banner



How To Find Default Gateway From Ip Address

When a host wants to reach a destination that is outside of its own network, information technology has to apply a default gateway. Nosotros use a router or multilayer switch (that's a switch that can do routing) as a default gateway.

In this lesson I'll explain how a host knows when to utilise the default gateway or not and how information technology works behind the scenes. Let's outset with a simple example:

two hosts same subnet

In a higher place we have ii hosts connected to a switch. We just have network 192.168.i.0 with subnet mask 255.255.255.0.

When one host wants to send something to another host then information technology will check if the destination is within or exterior its ain network. When the destination is in the same network then it volition use ARP to find the MAC accost of the destination and information technology tin send the IP parcel. How does the host check if the destination is in the same network? This is done by checking the subnet mask. For example, allow'south say that 192.168.ane.1 wants to ship an IP parcel to 192.168.1.ii:

Source 192.168.1.one 11000000 10101000 00000001 00000001
Destination 192.168.1.2 11000000 10101000 00000001 00000010
Subnet mask 255.255.255.0 11111111 11111111 11111111 00000000

The subnet mask tells us which part of the IP accost is the network and host role, the host that uses 192.168.1.1 sees that 192.168.one.2 is using the verbal aforementioned network address and volition know that information technology tin can use ARP to find the MAC accost, create an Ethernet frame, encapsulate the IP bundle and send it towards the switch.

Now let'southward take a look at an example where nosotros practice require a default gateway. Take a await at this moving-picture show:

Source: https://networklessons.com/cisco/ccna-routing-switching-icnd1-100-105/what-is-a-default-gateway

Posted by: amundsonswayse.blogspot.com

0 Response to "How To Find Default Gateway From Ip Address"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel