the laboratory of computer communication and networking srp simulation over ethernet

31
The Laboratory of Computer The Laboratory of Computer Communication and Communication and Networking Networking SRP Simulation Over SRP Simulation Over Ethernet Ethernet

Post on 21-Dec-2015

217 views

Category:

Documents


2 download

TRANSCRIPT

The Laboratory of Computer The Laboratory of Computer Communication and Communication and

NetworkingNetworking

SRP Simulation Over SRP Simulation Over EthernetEthernet

Project TeamProject Team

Submitted by: Yigal Bogin sibogin@t2 Technion

No’omi Meridor snoomi@t2 Technion

Lecturer Prof. Reuven Cohen rcohen@cs Technion

Instructor: Sarel Altshuler [email protected] Cisco

Supervisor: Itai Dabran idabran@cs Technion

Project GoalProject Goal Implementation of Spatial Reuse Protocol (SRP) Implementation of Spatial Reuse Protocol (SRP)

over UDP.over UDP.

Main missions:Main missions:

1. Transmission of packets via Windows sockets.1. Transmission of packets via Windows sockets.

2. Implementation of ring topology discovery as 2. Implementation of ring topology discovery as defined by the protocol. defined by the protocol.

3. Implementation of ring selection algorithm.3. Implementation of ring selection algorithm.

4. Sending and receiving data and control 4. Sending and receiving data and control packets over wrapped and unwrapped rings, packets over wrapped and unwrapped rings, using a basic user interface. using a basic user interface.

BackgroundBackground The Spatial Reuse Protocol (SRP) was developed by The Spatial Reuse Protocol (SRP) was developed by

Cisco for use with ring-based media. It derives its Cisco for use with ring-based media. It derives its name from the spatial reuse properties of the packet name from the spatial reuse properties of the packet handling procedure.handling procedure.Spatial Reuse is a concept used in rings to increase Spatial Reuse is a concept used in rings to increase the overall bandwidth of the ring. This is possible the overall bandwidth of the ring. This is possible because unicast traffic is only passed along ring spans because unicast traffic is only passed along ring spans between source and destination nodes rather than the between source and destination nodes rather than the whole ring as in earlier ring based protocols such as whole ring as in earlier ring based protocols such as token ring.token ring.

SRP uses a bidirectional dual counter-rotating ring SRP uses a bidirectional dual counter-rotating ring topology. Both rings are utilized for transporting data topology. Both rings are utilized for transporting data and SRP control packets. and SRP control packets.

Background (Cont.)Background (Cont.)

Main aspects of SRPMain aspects of SRP Topology discovery mechanismTopology discovery mechanism

Each node on the ring sends out periodically Each node on the ring sends out periodically topology discovery packets over the ring. topology discovery packets over the ring. When the packet arrives back at the node, it When the packet arrives back at the node, it updates the topology map according to the new updates the topology map according to the new information in the incoming packet. A more information in the incoming packet. A more detailed description will be given later on.detailed description will be given later on. SRP Fairness algorithm (SRP-fa)SRP Fairness algorithm (SRP-fa)

This algorithm ensures that each node on the This algorithm ensures that each node on the ring has fair share of the ring bandwidth by ring has fair share of the ring bandwidth by controlling the rates at which packets are controlling the rates at which packets are forwarded or sourced onto the ring by the node.forwarded or sourced onto the ring by the node.SRP-fa is not covered by our implementation.SRP-fa is not covered by our implementation.

Background (Cont.)Background (Cont.) Dynamic ring selectionDynamic ring selection

The source node selects the ring for sending a The source node selects the ring for sending a packet based on the hop count of the packet.packet based on the hop count of the packet.In SRP This is done using ARP. In our In SRP This is done using ARP. In our Implementation the selection is based on a Implementation the selection is based on a topology map each node possesses.topology map each node possesses.

Packet prioritizationPacket prioritizationpacket priority influences the period of time a packet priority influences the period of time a packet will wait until it is transmitted over the packet will wait until it is transmitted over the ring. This allows SRP to support real time ring. This allows SRP to support real time applications, and control traffic. applications, and control traffic.

Background (Cont.)Background (Cont.)

Intelligent Protection Switching Intelligent Protection Switching (IPS)(IPS)

If an equipment or fiber facility failure is If an equipment or fiber facility failure is detected, traffic going towards and from the detected, traffic going towards and from the failure direction is wrapped (looped) back to go failure direction is wrapped (looped) back to go in the opposite direction on the other ring. The in the opposite direction on the other ring. The wrap around takes place on the nodes adjacent wrap around takes place on the nodes adjacent to the failure.to the failure.

SimulationSimulation

S

1

3

4

D

2

Node S transmits a packet to node D over the outer ring.

Simulation (Cont.)Simulation (Cont.)

S

1

3

4

D

2

Failure is detected between node 1 and node 2.

Simulation (Cont.)Simulation (Cont.)

S

1

3

4

D

2

Packet is wrapped back into the inner ring.

Example (Cont.)Example (Cont.)

S

1

3

4

D

2

Packet arrives at destination for the first time, and is forwarded to the following node on the ring.

Simulation (Cont.)Simulation (Cont.)

S

1

3

4

D

2

Packet arrives at destination on the outer ring, and is accepted by it.

Project DescriptionProject Description Main modules and data structuresMain modules and data structures

SRPQueues

Topology map

Data Structures

Transmit

Receive

Modules

Node

Side A Side B

Transmit

Receive

Project Description Project Description (Cont.)(Cont.)

ModulesModules NodeNode

1. Reads packets from input file and directs them to 1. Reads packets from input file and directs them to appropriate transmit queue, using ring selection appropriate transmit queue, using ring selection algorithm.algorithm.2. Creates topology packets every fixed period of 2. Creates topology packets every fixed period of time, and directs them to left side Transmit queue time, and directs them to left side Transmit queue unless the node is wrapped inside out. In this case unless the node is wrapped inside out. In this case the packet is directed to right side Transmit queue.the packet is directed to right side Transmit queue.3. Removes packets from Receive queue. 3. Removes packets from Receive queue. If the packet removed is a data packet it If the packet removed is a data packet it prints some of the incoming packet fields. If the prints some of the incoming packet fields. If the packet is a topology packet it executes the topology packet is a topology packet it executes the topology algorithm and acts according to its results.algorithm and acts according to its results.

Project Description Project Description (Cont.)(Cont.)

SideSideEvery node has 2 sides. The left side receives packets Every node has 2 sides. The left side receives packets from the outer ring and transmits packets to the from the outer ring and transmits packets to the inner ring, using Transmit and Receive modules. The inner ring, using Transmit and Receive modules. The right side receives from the inner ring and transmits right side receives from the inner ring and transmits to the outer ring.to the outer ring.

TransmitTransmitRemoves packets from the Transmit and Transit Removes packets from the Transmit and Transit queues according to a fixed hierarchy, and sends queues according to a fixed hierarchy, and sends them over the ring to the destination node, using them over the ring to the destination node, using UDP sockets. UDP sockets.

ReceiveReceiveReceives packets from the ring using UDP sockets Receives packets from the ring using UDP sockets and handles them according to the Packet acceptance and handles them according to the Packet acceptance and stripping algorithm which will be described later and stripping algorithm which will be described later on. on.

Project Description Project Description (Cont.)(Cont.)

Data structuresData structures LowReceive and HighReceiveLowReceive and HighReceive

These two queues contain SRP packets These two queues contain SRP packets generated by agenerated by a

fellow node on the ring and destined for the fellow node on the ring and destined for the host. host.

A fixed threshold of 3 (priority field) A fixed threshold of 3 (priority field) determines whichdetermines which

priorities belong to which queue.priorities belong to which queue.

Project Description Project Description (Cont.)(Cont.)

HighTransmitL/R and LowTransmitL/RHighTransmitL/R and LowTransmitL/R

These four queues contain SRP packets These four queues contain SRP packets generated by the host and destined for the ring. generated by the host and destined for the ring. The suffix of each queue stands for the side to The suffix of each queue stands for the side to which it belongs. After determining on which which it belongs. After determining on which ring the packet should be transmitted it is ring the packet should be transmitted it is directed to the appropriate queue. Packets directed to the appropriate queue. Packets destined to the outer ring are directed to the destined to the outer ring are directed to the right side queues, and packets destined to the right side queues, and packets destined to the inner ring are directed to the left side queues. A inner ring are directed to the left side queues. A fixed threshold of 3 determines which priorities fixed threshold of 3 determines which priorities belong to which queue.belong to which queue.

Project Description Project Description (Cont.)(Cont.)

HighTransitL/R and LowTransitL/RHighTransitL/R and LowTransitL/RThese four queues contain SRP packets These four queues contain SRP packets generated by a fellow node on the ring and generated by a fellow node on the ring and destined for one or several nodes located destined for one or several nodes located further ahead on the ring. Packets destined for further ahead on the ring. Packets destined for the outer ring are buffered in the right side the outer ring are buffered in the right side queues, and packets destined for the inner queues, and packets destined for the inner ring are buffered in the left side side queues. ring are buffered in the left side side queues. A fixed threshold of 3 determines which A fixed threshold of 3 determines which priorities belong to which queue.priorities belong to which queue.

Project Description Project Description (Cont.)(Cont.)

Topology mapTopology mapThis Data structure holds a list of nodes in the This Data structure holds a list of nodes in the ring and their ‘wrap’ status.ring and their ‘wrap’ status.

In addition it contains information used for In addition it contains information used for ring selection.ring selection.

AlgorithmsAlgorithms

Ring SelectionRing Selection

This algorithm determines the shortest path to the This algorithm determines the shortest path to the destination node in terms of hop count.destination node in terms of hop count.

If the node is not wrapped, the algorithm chooses If the node is not wrapped, the algorithm chooses the ring that contains less nodes between the the ring that contains less nodes between the source and the destination. After choosing the ring, source and the destination. After choosing the ring, the packet is directed to the transmission queue of the packet is directed to the transmission queue of the suitable side.the suitable side.

If the node is wrapped there is only one ring If the node is wrapped there is only one ring possible for transmitting the packet. The algorithm possible for transmitting the packet. The algorithm directs the packet to the unwrapped side.directs the packet to the unwrapped side.

Algorithms (Cont.)Algorithms (Cont.) Topology discovery algorithmTopology discovery algorithm

Topology discovery plays a key role in SRP ring Topology discovery plays a key role in SRP ring selection and network management capabilities. Each selection and network management capabilities. Each node on the ring periodically sends out topology node on the ring periodically sends out topology discovery packets on the inner ring or on the outer discovery packets on the inner ring or on the outer ring, if the node is wrapped inside out. Nodes receiving ring, if the node is wrapped inside out. Nodes receiving the topology discovery packet append their MAC the topology discovery packet append their MAC binding which consists of the node's MAC address and binding which consists of the node's MAC address and info. indicating whether the node is wrapped or info. indicating whether the node is wrapped or unwrapped. Once the packet is updated it is passed unwrapped. Once the packet is updated it is passed along to the next node on the ring. When the topology along to the next node on the ring. When the topology discovery packet follows a wrap, the packet is not discovery packet follows a wrap, the packet is not updated until it comes out of the wrap. updated until it comes out of the wrap.

Eventually the topology discovery packet returns to the Eventually the topology discovery packet returns to the source, where it is received and stripped from the ring. source, where it is received and stripped from the ring. Upon receiving two consecutive topology discovery Upon receiving two consecutive topology discovery packets that are identical, the node updates its topology packets that are identical, the node updates its topology map. map.

Algorithms (Cont.)Algorithms (Cont.) Packet acceptance and strippingPacket acceptance and stripping

Upon receiving a packet, the Receive module tests the TTL Upon receiving a packet, the Receive module tests the TTL field and discards the packet if it equals 1. Then, checks field and discards the packet if it equals 1. Then, checks whether the packet is a data packet or a topology packet.whether the packet is a data packet or a topology packet.If Data: If Data:

1. If the packet was sourced by the node and the ingress ring 1. If the packet was sourced by the node and the ingress ring and egress ring are the same, strip the packet off the ring.and egress ring are the same, strip the packet off the ring.2. If the two following conditions are valid, direct the packet 2. If the two following conditions are valid, direct the packet to the HighReceive queue or LowReceive queue, according to to the HighReceive queue or LowReceive queue, according to its priority.its priority.

a. The packet is destined to the node, or the packet is a a. The packet is destined to the node, or the packet is a multicast.multicast.

b. The ingress ring and egress ring are the same, or the b. The ingress ring and egress ring are the same, or the nodenode

is wrappedis wrapped

Algorithms (Cont.)Algorithms (Cont.)

3. If one of the three following conditions are 3. If one of the three following conditions are valid direct the packet to the appropriate valid direct the packet to the appropriate Transit queue.Transit queue.

a. The packet isn’t destined to the node.a. The packet isn’t destined to the node.

b. The packet is a multicast.b. The packet is a multicast.

c. The packet is destined to the node, but c. The packet is destined to the node, but the ingress ring the ingress ring

and egress ring are not the same and egress ring are not the same

If Topology:If Topology:

direct packet to the HighReceive queue, where it direct packet to the HighReceive queue, where it will be handled by the host.will be handled by the host.

Algorithms (Cont.)Algorithms (Cont.)

Transmission and forwardingTransmission and forwardingThe Transmit module tests the Transmit queues and The Transmit module tests the Transmit queues and Transit queues and sends packets in an infinite Transit queues and sends packets in an infinite loop. loop.

In order to choose the next packet to transmit, the In order to choose the next packet to transmit, the Transmit module must choose between high and low Transmit module must choose between high and low priority transit packets and high and low priority priority transit packets and high and low priority transmit packets according to the following transmit packets according to the following hierarchy:hierarchy:

1. High-priority transit packets1. High-priority transit packets

2. High-priority transmit packets from host2. High-priority transmit packets from host

3. Low-priority transmit packet from host3. Low-priority transmit packet from host

4. Low-priority transit packets4. Low-priority transit packets

User InterfaceUser Interface

Operating instructions:1. Initialize Node.2. Select Input file from the File menu.3. Select Output file from the File menu.4. Select Activate Node from the Actions menu.5. After executing phases 1 to 4 for all the nodes in the ring,

select Start Working from the Actions menu.

User Interface User Interface (Cont.)(Cont.)

ActionsActions

To see topology

Node initializati

on

Node wrapping

User Interface User Interface (Cont.)(Cont.)

InitializationInitialization

User Interface User Interface (Cont.)(Cont.)

Input File DescriptionInput File DescriptionCopiesCopies DelayDelay PriorityPriority

DestinationDestinationMessageMessage

Copies – number of copies of the message that Copies – number of copies of the message that should be sent sent.should be sent sent.

Delay – the delay after each message.Delay – the delay after each message. Priority – priority of the messagePriority – priority of the message Destination – message destination Destination – message destination

(1000000000 for multicast packets)(1000000000 for multicast packets) Message – the message itselfMessage – the message itself

User Interface User Interface (Cont.)(Cont.)

For Example:For Example:

User Interface User Interface (Cont.)(Cont.)

TopologyTopology To see topology press the T button and select To see topology press the T button and select

in which file to save.in which file to save. For example: not wrapped ring of 4 stations as For example: not wrapped ring of 4 stations as

seen from station 2.seen from station 2.

User Interface User Interface (Cont.)(Cont.)

Output Files:Output Files: