Communication with an external controller not only requires the switch
to accept the configuration from the controller but also requires the switch to
notify the controller of certain events that take place on the switch. Such
events might include port notifications (for example, if the user issues the
shut or
no shut command on a port) or MAC notifications (for
example, when the switch learns the MAC addresses of hosts that are connected
to it). The switch must report these events to the external controller, and the
controller may choose to take some action against them (for example, in the
case of MAC notifications, the controller might distribute the MAC addresses to
other switches in the network).
The NXDB subfeature enables Cisco NX-OS to send the event notifications
from the switch. The external controller must register for specific events on
the switch. Any time such an event is generated on the switch, Cisco NX-OS
notifies the external controller of its occurrence. The OVSDB plugin is
registered against events such as port events and MAC events. When such an
event occurs, Cisco NX-OS informs the OVSDB plugin about this event in a JSON
format. The OVSDB plugin formats this information into an OVSDB-based
notification and sends it to the external controller.
In order to allow for this event-notification capability, Cisco NX-OS
has introduced the object store. The object store is a shared database that is
accessible by Cisco NX-OS components. It contains managed network elements
(such as ports, MAC addresses, VLANs, and so on) represented as objects. When
an event is generated on the switch, the objects in the object store are
updated accordingly. This update triggers an event notification to all
registered clients, such as the OVSDB plugin, which can then choose to take
some action on the basis of the event.