Redundancy is essential to any reliable networks design. A realistic OpenFlow design connects each switch to multiple controllers, as you could see the following picture.
How the multiple controllers synchronize is not important to OpenFlow. But a switch connecting to multiple controllers must be able to categorize the relationships of the controllers to each other from the switch's perspective. A controller can play one of three roles:
- Equal is the default role. The switch exchanges the same messages with each controller, and does not distinguish between them, and does not load-balance among the controllers or arbitrate between the controllers. The switch relies on the controllers to coordinate the instructions they send to the switch
- Master is same as Equal in terms of the relationship between the switch and controller, but the difference is that only a single controller can be Master. If there is a Master, all other controllers must be in a Slave role.
- Slave is the role of all switches except the Master, when controllers are set up in a Master/Slave configuration. A Slave controller cannot send any Controller-to-Switch messages that would cause a change to the switch; it can only send messages of this type that query information from the switch or that inform the switch of its role. Similarly, a slave controller cannot receive any Asynchronous messages except port status messages.
Each controller is responsible for sending a Controller-to-Switch message called Role Request to tell the switch what its role is. Although OpenFlow does not specify the Master/Slave election mechanism between controllers, it does specify a 64 bit number, call Generation-Id, in the role request message that allows switch to keep track of the most recent Role Request messages during a role change.
Auxiliary Connections
When there are multiple connections, one connection is the main and the others are auxiliary connections. The main connection must be established first, and then the auxiliary connections are established.
Two identifiers are used with auxiliary connections: