Deploying new optimized routing policies on routers in the event of link failure is difficult due to strong coupling between the data and control planes and the absence of topology information about the network. Because of the distributed architecture of traditional Internet protocol networks, policies and routing rules are spread in a decentralized way, resulting in looping and congestion problems. To overcome this problem, we choose Software-Defined Networking (SDN) technology to create a hybrid fast failure recovery (HFFR) framework for IoT networks based on caching the flow rules which correspond to the optimal paths in the hash table deployed in the SDN controller memory in order to reduce the computation time of the forwarding path and the load at the SDN controller.