You are on page 1of 7

CST 311: Introduction to Computer Networks

June 17, 2022


Assignment #4 Subnet Addressing in Mininet
Pacific Analyti
Anna Bellizzi, David Debow, Justin Johnson, Ryan Parker

1. Network Design

2. Network Creation Script Run - No Errors


CST 311: Introduction to Computer Networks
June 17, 2022
Assignment #4 Subnet Addressing in Mininet
Pacific Analyti
Anna Bellizzi, David Debow, Justin Johnson, Ryan Parker

3. Success l pingall at the mininet> prompt

4. Line changes in code


There are nine general line changes in the code, with six adjustments and three new addi ons.

In the import sec on, we added two new imports. For me.sleep we add import me. For the makeTerm
pop-up window add import makeTerm. These imports are needed for sleep and makeTerm to work.

Adjusted values in the net declara on. Switch the CIDR number from 8 to 24 for ipBase = '10.0.0.0/8' to
'10.0.0.0/24' Different subnets. To meet specifica ons.

We moved the add switches to above add host routers. Switch s1 and s2 need to be ini alized before the
add router host. Otherwise, errors are produced.

In the add host for router nodes. For r3, r4, r5. We gave the routers IP addresses besides 0.0.0.0. IP
addresses match the topography of rX-eth0. Where x is 1,2, or 3, it is changed because it's not physically
possible for those to have the same IP address of 0.0.0.0 and be three separate routers with different
interfaces.

In the add host sec on we made changes for h1, h2, h3, h4. Rather than 10.0.0.1, 10.0.0.2, 10.0.0.3,
10.0.0.4, we split hosts on to two different subnets. Different routers connect them on different networks.
Therefore two different subnets for h1, h2, and h3, h4 match the topography of these hosts being
physically separated.
CST 311: Introduction to Computer Networks
June 17, 2022
Assignment #4 Subnet Addressing in Mininet
Pacific Analyti
Anna Bellizzi, David Debow, Justin Johnson, Ryan Parker

In the addlink sec on, we added arguments for some of the addlinks. Expand addlink for r3,s1 r5,s2 r3,r4
r5,r4. This is to define the links r3,s1 = r3-eth0, r5,s2 = r5-eth0, r3, r4 = r3-eth1, r4-eth0 and r5, r4 =
r5-eth1, r4-eth1. This allows for travel across subnets.

Added a new line with router commands. Added trace IP routes for r3, r4, and r5. A total of six lines or two
traceroutes for each router. The traceroutes make forwarding packets between the hosts possible. A
sample command is r3.cmd('sudo ip route add 10.0.1.0/24 via 192.168.0.2 dev r3-eth1').

Added another new sec on to display traceroute informa on on r3, r4, and r5. It lists the des na on,
gateway, genmask, and interface. Trace route informa on is for debugging and quality of life.

Added a new sec on to call xterm to pop up three windows with one chat server and two chat clients
running. This call reduces the interac on needed by the user.

5. Questions
a. What were any interes ng findings and lessons learned?
We learned that the xterm host terminal windows will not open, or will close if there is an
error in the script.
b. Why didn’t the original program forward packets between the hosts?
The original program did not forward packets between the hosts because there were no
sta c routes, there were not two separate subnets, and all hosts were set to default IP
addresses.
c. Is the line ‘ r3.cmd('sysctl -w net.ipv4.ip_forward=1') ’ required?
Yes, it is required.
d. Inten onally break your working program, e.g.: change a subnet length, IP address, or default
route for a host. Explain why your change caused the network to break.
If eth0 and eth1 of r4 are assigned 10.0.x.x addresses, the two subnets can not
communicate.
CST 311: Introduction to Computer Networks
June 17, 2022
Assignment #4 Subnet Addressing in Mininet
Pacific Analyti
Anna Bellizzi, David Debow, Justin Johnson, Ryan Parker

6. Success l Chat Session


CST 311: Introduction to Computer Networks
June 17, 2022
Assignment #4 Subnet Addressing in Mininet
Pacific Analyti
Anna Bellizzi, David Debow, Justin Johnson, Ryan Parker

7. Success l wget of webserver index file


CST 311: Introduction to Computer Networks
June 17, 2022
Assignment #4 Subnet Addressing in Mininet
Pacific Analyti
Anna Bellizzi, David Debow, Justin Johnson, Ryan Parker

8. Decrypted Web Certificates


CST 311: Introduction to Computer Networks
June 17, 2022
Assignment #4 Subnet Addressing in Mininet
Pacific Analyti
Anna Bellizzi, David Debow, Justin Johnson, Ryan Parker

You might also like