Assignment 4 Sol
Assignment 4 Sol
Assignment 4 Sol
The
administrator wants to create 4 subnets with the following requirements:1st subnet needs at least 300
IP addresses, 2nd subnet needs at least 200 IP addresses, 3rdsubnet needs at least 100 IP addresses
while 4th subnet needs at least 120 IP addresses. The following are required from you:
a) Write the subnet mask for each subnet.
255.255.254.0
255.255.255.0
255.255.255.128
255.255.255.128
b) Write the first and last IP address in each subnet (Network and Broadcast addresses).
150.100.80.0 150.100.81.255
150.100.82.0 150.100.82.255
150.100.83.0 150.100.83.127
150.100.83.128 150.100.83.255
150.100.80.0 150.100.81.255
150.100.82.0 150.100.82.255
150.100.83.0 150.100.83.127
150.100.83.128 150.100.83.255
[2+2+2+2 = 8 Marks]
Question 2: Differentiate between forwarding and routing. Write 3 points for each. Also states brief
packet transfer scenario where these come into play.
Forwarding
1. Path Execution: Forwarding refers to the process of moving packets from an incoming link to an outgoing
link within a single router. It is a local, hardware-based activity.
2. Speed and Efficiency: Forwarding is performed at the data link layer and is optimized for speed. It
involves looking up the outgoing link in a forwarding table that is typically implemented in the router's
hardware for high-speed processing.
3. Decision Making: The decisions in forwarding are made based on pre-established routing tables
(determined by routing protocols). It does not involve recalculating routes; it simply uses existing
information to transfer packets efficiently.
Routing
1. Path Determination: Routing is the process of choosing the best path through the network from the
source to the destination. It is a network-wide process.
2. Complex Algorithms: Routing uses sophisticated algorithms and protocols to determine the optimal path
for data to travel across different networks. It considers multiple network variables like bandwidth,
network policies, and congestion.
3. Dynamic and Adaptive: Routing can dynamically adjust to changes in the network topology or traffic
conditions. Routers communicate with each other using routing protocols to update their tables and make
informed path choices.
Consider a scenario where an email needs to be sent from a user in New York to a user in Tokyo. When the
user in New York sends the email, it is broken down into packets, each of which needs to be routed to
Tokyo.
Routing: Initially, the router at the user’s ISP in New York determines the best path for the packets to reach
Tokyo. This decision is based on the routing protocols it uses, which consider various network paths, traffic
load, and possibly even the type of service as email might be prioritized differently from video streaming
traffic.
Forwarding: Once the path is determined, each packet enters the network. At each intermediate router
along the chosen path, the router performs forwarding. The router quickly looks up its forwarding table to
see which link the packet should be sent out on to continue along the correct path towards Tokyo. This
process is repeated at each router until the packets reach the recipient’s ISP in Tokyo.
Thus, while routing determines the path the packets should take, forwarding is the action of moving those
packets along the path from one router to the next until they reach their destination.
[5 Marks]
Question 3: Draw labelled IPv4 datagram. Also describe each of the following in 3 to 4 lines:
Question 4: Apply
Link State and
Distance Vector
algorithms on the
following graph. Do
not omit steps from
the solution. Assume
node A as the
source node.
[5+5 = 10 Marks]
Question 5: Write whether you agree or disagree with the following prompts. Give
reason for your choice in in 2 to 3 lines as well:
a) IPv4 to IPv6 transition is possible by tunneling. Draw a diagram to show how if you agree.
Question 6: For the following scenario where Routers R1 and R2 with interfaces 0, 1, 2, 3, 4,and 5, 6
respectively, constitute the network. Use IP Address Aggregation (Route Summarization) and fill the
entries in the following table. (Default entries are pre-filled)
[2.5+2.5 = 5 Marks]
0.0.0.0/0 4 0.0.0.0/0 6
142.25.7.0/26 0 142.25.7.0/24 5
142.25.7.64/26 1
142.25.7.128/26 2
142.25.7.192/26 3
+
Question 7: A datagram of 4,000 bytes arrives at a router and must be forwarded to a link with an
MTU of 1,5XX bytes (where XX are the last 2 digits of your roll number) . The datagram stamped with the
identification number XXX (where XXX are the last 3 digits of your roll number). Explicitly state into how
many fragments the datagram is divided. Fill the following table with the relevant characteristics of the
fragments:
[6 Marks]
1 1573 273 0 1
Question 8: Consider the OpenFlow network shown in the following figure. Suppose that the desired
forwarding behavior for datagrams arriving from host h3 or h4 at s2 is as follows:
- any datagrams arriving from host h3 and destined for h1, h2, h5 or h6 should be
forwarded in an anti-clockwise direction in the network
- any datagrams arriving from host h4 and destined for h1, h2, h5 or h6 should be
forwarded in a clockwise direction in the network
Specify the flow table entries in s2 that implement this forwarding behaviour.
Match Action
[5 Marks]