Skip to content

SimpleForwardingModule

Mc-Hoppe edited this page Nov 9, 2015 · 4 revisions

SimpleForwardingModule

 

Information

ModuleTypeID (hex) 0x0004
ModuleTypeID (decimal) 4
Distribution support multiple, load-balancing instances
Dependencies DeviceModule

 

Description

The SimpleForwardingModule is a very simple packet forwarding module. It receives PacketIn messages and does layer 2 forwarding (looking up the destination MAC address of the ethernet frame and forwarding the packet to its desired target, if it is known).

 

Configuration


Config variable: ZSDN_SIMPLE_FORWARDING_MODULE_MULTICAST_GROUPS_FOR_INSTANCE_ID_
Type: comma separated list of integers (decimal)
Description: his config is specific to a single instance of a SimpleForwarding module (). The config is for the multicast groups the simple forwarding module will subscribe to. This allows multiple SimpleForwardingModules to run in parallel without receiving the same packetIns. See SwitchAdapter for more details on multicast groups.


Config variable: ZSDN_SIMPLE_FORWARDING_MODULE_IGNORE_ETHERTYPES_FOR_INSTANCE_ID_
Type: comma separated list of integers (decimal)
Description: This instance-specific config for instance will cause the module to ignore all packets with an ethertype contained in the list of ignored ethertypes.


 

Implementation Details

At the starting point each module get enabled. In this phase the SimpleForwardingModule will request all known devices from the DeviceModule and will store it temporary. It also subscribes to the topics FROM.DEVICE_MODULE.DEVICE_EVENT.ADDED and FROM.DEVICE_MODULE.DEVICE_EVENT.REMOVED to keep the list of devices up to date, the module will also subscribe to the FROM.SWITCH_ADAPTER.OPENFLOW.PACKET_IN.* to receive the packages which need to be forwarded. After the enable phase it will get a reactive module, this means it will react to the subscribed topics. If it receives a device changed event the list will get updated and if it receives a OpenFlow-PacketIn it will look up the device list and if the device is known it will send the payload of the PacketIn directly to the devices connected switch Output port else if the device is unknown it will simply discard the message. A broadcast message will handled like a unknown device.

ZeroSDN SimpleForwardingModule Sequence

 

Subscriptions used (FROM)


MessageType: FROM.SWITCH_ADAPTER.OPENFLOW.PACKET_IN.MULTICAST_GROUP(?).*
Comment: Receiving any type of packet to forward them to their destination.


 

Publishes (TO)


MessageType: TO.SWITCH_ADAPTER.SWITCH_INSTANCE(switchID).OPENFLOW.PACKET_OUT
Comment: Forwarding packets.


 

Services used (REQUEST/REPLY)


MessageType: REQUEST.DEVICE_MODULE.GET_ALL_DEVICES
Comment: Initially request all devices to cache them locally in order to have them ready once PACKET_IN's arrive.


MessageType: REQUEST.DEVICE_MODULE.GET_DEVICE_BY_MAC_ADDRESS
Comment: Request device by MAC-address if SimpleForwardingModule does not know about it.


 

Clone this wiki locally