Network Programming Final

¡Supera tus tareas y exámenes ahora con Quizwiz!

Three types of switching fabrics are discussed in Section 4.2 . List and briefly describe each type. Which, if any, can send multiple packets across the fabric in parallel?

1. Switching via memory - controlled directly by CPU, fetch interrupt signal, extracts destination address from header, uses table to find output port, copies packet to port buffer, identical to shared-memory multi processors 2. Switching via a bus - no use of routing processor just direct transfer of packets from input to output ports, bus can only transfer one packet at a time, is bus is busy packet is queued at input 3. Switching via an interconnection network - overcomes bandwidth issues of bus using interconnected network, cross bar switch uses 2n buses to connect n ports, packet travels along horizontal input bus until reaches vertical output bus, BUT if bus is busy packet is still queued at input ** Multiple packets can be sent in parallel using interconnection network but you must use multiple stages in the switching fabric

What is the 32-bit binary equivalent of the IP address 223.1.3.27?

11011111 00000001 00000011 00011011 Use 8 bit binary

Describe how a network administrator of an upper-tier ISP can implement policy when configuring BGP.

A tier-1 ISP B may not to carry transit traffic between two other tier-1 ISPs, say A and C, with which B has peering agreements. To implement this policy, ISP B would not advertise to A routes that pass through C; and would not advertise to C routes that pass through A.

Consider the network shown in Problem 32. Using Dijkstra's algorithm, and showing your work using a table similar to Table 5.1 , do the following: a. Compute the shortest path from t to all network nodes. b. Compute the shortest path from u to all network nodes. c. Compute the shortest path from v to all network nodes. d. Compute the shortest path from w to all network nodes. e. Compute the shortest path from y to all network nodes. f. Compute the shortest path from z to all network nodes.

ALOT OF WORK

If all the links in the Internet were to provide reliable delivery service, would the TCP reliable delivery service be redundant? Why or why not?

Although each link guarantees that an IP datagram sent over the link will be received at the other end of the link without errors, it is not guaranteed that IP datagrams will arrive at the ultimate destination in the proper order. With IP, datagrams in the same TCP connection can take different routes in the network, and therefore arrive out of order. TCP is still needed to provide the receiving end of the application the byte stream in the correct order. Also, IP can lose packets due to routing loops or equipment failures.

Why is an ARP query sent within a broadcast frame? Why is an ARP response sent within a frame with a specific destination MAC address?

An ARP query is sent in a broadcast frame because the querying host does not know which adapter address corresponds to the IP address in question. For the response, the sending node knows the adapter address to which the response should be sent, so there is no need to send a broadcast frame (which would have to be processed by all the other nodes on the LAN)

Suppose you wanted to implement a new routing protocol in the SDN control plane. At which layer would you implement that protocol? Explain.

At the management layer because management layer is one that interacts with SNMP, SSH, Telnet and TFTP

Suppose nodes A, B, and C each attach to the same broadcast LAN (through their adapters). If A sends thousands of IP datagrams to B with each encapsulating frame addressed to the MAC address of B, will C's adapter process these frames? If so, will C's adapter pass the IP datagrams in these frames to the network layer C? How would your answers change if A sends frames with the MAC broadcast address?

C's adapter will process the frames, but the adapter will not pass the datagrams up the protocol stack. If the LAN broadcast address is used, then C's adapter will both process the frames and pass the datagrams up the protocol stack.

Compare and contrast the properties of a centralized and a distributed routing algorithm. Give an example of a routing protocol that takes a centralized and a decentralized approach.

Centralized: Central node in the network gets entire information about the network topology, about the traffic and about other nodes. This then transmits this information to the respective routers. The advantage of this is that only one node is required to keep the information. The disadvantage is that if the central node goes down the entire network is down, i.e. single point of failure. Distributed: Node receives information from its neighbouring nodes and then takes the decision about which way to send the packet. The disadvantage is that if in between the the interval it receives information and sends the paket something changes then the packet may be delayed. LinkState takes Centralzied approach Distance Vector takes Decentralzied approach

Describe the main role of the communication layer, the network-wide state-management layer, and the network-control application layer in an SDN controller.

Co mmunication Layer: In a controller, this layer provides communication between the SDN controller and controlled switches Network-wide state management layer: This layer acts as a set of network links, switches, and services. Network-control application layer: This layer provides API and abstractions for network control apps

Describe the purpose of two types of OpenFlow messages (of your choosing) that are sent from a controlled device to the controller. Describe the purpose of two types of Openflow messages (of your choosing) that are send from the controller to a controlled device.

Controlled devices to controller: 1. Flow-Removed: messages are used to inform controller about removal, of the flow table entry, messages like entry has been removed because it timed-out 2. Port-Status: status change of ports Controller to devices: 1. Modify-State: used to set properties of switch port, deleting of adding new entries 2. Real-State: used to collect statistics on counter values from the switches flow tables and ports

Why choose UDP over TCP for an app?

- To elimante TCP congestion control which would throttle applications - they dont need the reliability of data transfer provided by TCP

Define and contrast the following terms: subnet, prefix, and BGP route.

Subnet : sub portion of large network without a router, boundaries are defined by the router and host interfaces Prefix : portion of network CIDR address, notation is a.b.c.d/x, x consists of network portion of IP and us is prefix, one or more subnet use the same prefix BGP Route : BGP message & TCP sent over BGP session, router advertises prefix which is sent with attributes across session and is known as the Route DIFFERENCES: subnet doesn't contain router, subnet is subdivision of IP -> prefix is portion of CIDR -> BGP Route contains prefix

Consider the transportation analogy in Section 6.1.1 . If the passenger is analagous to a datagram, what is analogous to the link layer frame?

The mode of transportation (car, bus, bike)

True or false: When an OSPF route sends its link state information, it is sent only to those nodes directly attached neighbors. Explain

True, when an OSPF route sends its link state information, it is sent only to those nodes directly attached neighbors.

True or false: When a BGP router receives an advertised path from its neighbor, it must add its own identity to the received path and then send that new path on to all of its neighbors. Explain.

True. BGP is an inter-AS rioting protocol, main responsibility to obtain prefix reachability info from neighbors and find best route by sending prefix info to neighbors. Protocol dictates that when sending new path to neighbors must advertise previous path from underlying connection (think building a chain) to give clear path to new router

Do routers have IP addresses? If so, how many?

Yes, one IP address per router interface, with a minimum of two (one for incoming and one for outgoing interfaces)

Suppose Host A sends two TCP segments back to back to Host B over a TCP connection. The first segment has sequence number 90; the second has sequence number 110. a. How much data is in the first segment? b. Suppose that the first segment is lost but the second segment arrives at B. In the acknowledgment that Host B sends to Host A, what will be the acknowledgment number?

a. First segment will be 110-90= 20 bytes of data b. TCP acknowledgements are cumulative so it will state that it has received everything except segment 90

What are some of the possible services that a link-layer protocol can offer to the network layer? Which of these link-layer services have corresponding services in IP? In TCP?

Framing - also in IP and TCP Link access Reliable Delivery - also in TCP Error detection and correction - also in TCP and IP

Consider the following network. With the indicated link costs, use Dijkstra's shortest-path algorithm to compute the shortest path from x to all network nodes. Show how the algorithm works by computing a table similar to Table 5.1.

IDK.

Why are different inter-AS and intra-AS protocols used in the Internet?

Inter-AS : admin wants control over how traffic is router and who routes through the net, policy dominates over performance Intra-AS : single admin, no policy decisions needed, focus on performance, hierarchical routing saves tables size, aka Interior Gateway Protocol

Suppose there are three routers between a source host and a destination host. Ignoring fragmentation, an IP datagram sent from the source host to the destination host will travel over how many interfaces? How many forwarding tables will be indexed to move the datagram from the source to the destination?

Interfaces = source host + (# routers x 2 interfaces per router) + destination host = 1 + (3x2) + 1 = 8 Forwarding tables = # of routers = 3

Compare and contrast link-state and distance-vector routing algorithms.

Link state algorithms: Computes the least-cost path between source and destination using complete, global knowledge about the network. Distance-vector routing: The calculation of the least-cost path is carried out in an iterative, distributed manner. A node only knows the neighbor to which it should forward a packet in order to reach given destination along the least-cost path, and the cost of that path from itself to the destination

How big is the MAC address space? The IPv4 address space? The IPv6 address space?

Mac Address space = 48 bits IPv4 = 32 bites IPv6 = 128 bits

Is it necessary that every autonomous system use the same intra-AS routing algorithm? Why or why not?

No. Each AS has administrative autonomy for routing within an AS.

What types of messages flow across an SDN controller's northbound and southbound APIs? Who is the recipient of these messages sent from the controller across the southbound interface, and who sends messages to the controller across the northbound interface?

Northbound : messages which help read/write state of network and developing flow tables within management layer, notifications for state-change events, network control apps send messages to the controller Southbound: messages which help for the up-to-date view of the network's state, communication between controller and devices which receive messages

What is meant by an area in an OSPF autonomous system? Why was the concept of an area introduced?

OSPF is system is divided hierarchically into areas, each area consists of routers to broadcast the areas link state using algorithms. An area is the set of networks and hosts that are grouped together, it is a collection of contiguous IP sub netted networks. Area was introduced as backbone responsible for routing traffic between other areas and as a way to track the link state of the routers

What is the "count to infinity" problem in distance vector routing?

One of the important issue in Distance Vector Routing is County of Infinity Problem. Counting to infinity is just another name for a routing loop. Indistance vector routing, routing loops usually occur when an interface goes down. It can also occur when two routers send updates to each other at the same time.

What is the purpose of the service abstraction layer in the OpenDaylight SDN controller?

OpenDaylight is open-source controller developed in partnership with Linux foundation Service Abstraction Layer (SAL) : controllers nerve center, helps the internal applications communicate, helps underlying protocols in providing uniform abstract interface in the communication layer

How does BGP use the NEXT-HOP attribute? How does it use the AS-PATH attribute?

Routers use the AS-PATH attribute to detect and prevent looping advertisements; they also use it in choosing among multiple paths to the same prefix. The NEXT-HOP attribute indicates the IP address of the first router along an advertised path (outside of the AS receiving the advertisement) to a given prefix. When configuring its forwarding table, a router uses the NEXT-HOP attribute.

In our rdt protocols, why did we need to introduce sequence numbers?

Sequence numbers are required for a receiver to find out whether an arriving packet contains new data or is a retransmission.

Can UDP have reliable data transfer? How?

-Yes it can if the application layer protocol provides the desired reliability -however requires more work and debugging

What is a private network address? Should a datagram with a private network address ever be present in the larger public Internet? Explain.

-a private network address is an address assigned to a private network (such as an organization, a LAN, or an individual) by the internet service providers, it can be a range of addresses and the devices using these do not directly connect to the internet BUT use a router or a NAT - useful because helps avoid network traffic and allows for good transfer speeds even with multiple devices -NO because all messages are directed through the NAT then sent via the internet

What is meant by a control plane that is based on per-router control? In such cases, when we say the network control and data planes are implemented "monolithically," what do we mean?

-control planes: used for exchange or forwarding of the tables - monolithically: each router contains components for better communication with other routers to compute forwarding values, individual routing algorithm components interact individually

Discuss why each input port in a high-speed router stores a shadow copy of the forwarding table.

-forwarding decision is made locally, at each input port, without invoking the centralized routing processor. -Such decentralized forwarding avoids creating a forwarding processing bottleneck at a single point within the router

What is meant by a control plane that is based on logically centralized control? In such cases, are the data plane and the control plane implemented within the same device or in separate devices? Explain.

-logically centralized means it knows all the routing and forwarding tables in every router on the network -Separate devices because: Data plane = network switches for "match plus action" rules in flow tables Control plane = servers and software manages by data plane

Name three header fields in an IP datagram that can be "matched" in OpenFlow 1.0 generalized forwarding. What are three IP datagram header fields that cannot be "matched" in OpenFlow?

-matched: source address, destination address, IP protocol -mismatched : version, IHL, TOS, TL, identification, flags, fragment offset, TTL, checksum, options, padding, and data

Suppose that an arriving packet matches two or more entries in a router's forwarding table. With traditional destination-based forwarding, what rule does a router apply to determine which of these rules should be applied to determine the output port to which the arriving packet should be switched?

-router must use longest prefix match rule -RULE: convert destination and matching IP address are converted into binary form. Find longest matching subnet mask is then chosen. - subnet mask is the address bits in destination address and these are checked to match the forwarding table entry

Suppose Host A sends Host B a TCP segment encapsulated in an IP datagram. When Host B receives the datagram, how does the network layer in Host B know it should pass the segment (that is, the payload of the datagram) to TCP rather than to UDP or to some other upper-layer protocol?

-the protocol field of the datagram identifies the where to send the TCP segment - value of 6 is TCP , 17 is UDP, 1 is ICMP, 2 is IGMP


Conjuntos de estudio relacionados

Lecture 19: Altruism/Kin Identification

View Set

PATHOPHYSIOLOGY and PHARMACOLOGY Alzheimer's Disease (AD)

View Set

Improving Sentence Structure, Part 4

View Set

Geometry Chapter 7 Theorems and Postulates

View Set

Chapter 5: Test Yourself Review Questions

View Set