||Unlike traditional networking structures, the new-generation software-defined network (SDN) separates the network control and forwarding and enables the network control to be software programmable, making flexible and convenient management a key feature of SDN. The early structure of SDN relies on centralized control, that is, the entire network is managed by only one controller. However, SDN managed by only one controller may suffer single point of failure (SPOF) problems. Besides, if the network is large in size, the scalability problem will make it hard to ensure the stability and performance of the network. Thus, later researchers have proposed to use multiple controllers to control the network collaboratively. A distributed control structure involving collaboration of multiple controllers can effectively enhance the performance and stability of SDNs. However, attacks and threats are prevalent in today's networking environment. SDN controllers may lose its normal functions when it is attacked by hackers or infected with viruses. In order to provide a fault-tolerant and reliable computing environment in distributed SDNs, we design a fault-tolerant consensus protocol to improve fault tolerance of distributed SDNs.