# Quality of Service and Congestion Control in Software-Defined Networking Using Policy-Based Routing
## 3 Overview of SDN and RouteFlow  
For many years, the pace of innovation in computer networks has lagged behind other communication technologies. This slow rate of innovation is primarily due to the closed nature of traditional networking systems, which depend on vendor-specific hardware and software. These proprietary systems not only stifle innovation but also increase management and operational costs. Traditional networks are composed of three logical planes: the control plane, the data plane, and the management plane. In the traditional model, the control and data planes are tightly integrated, a concept often referred to as the \"inside-the-box\" paradigm. To reduce complexity and operational costs, researchers have sought to redesign network architecture, leading to the emergence of programmable networks [19].  
Software-Defined Networking (SDN) marks a significant shift in networking by decoupling the control plane from the data plane. This separation has garnered significant attention from both industry and academia due to SDN's potential to simplify network management and enhance flexibility. In an SDN environment, the control plane, typically centralized in a controller, has a global view of the network and is responsible for its intelligence, while the data plane, composed of forwarding devices such as switches and routers, executes the controller's instructions. OpenFlow, a key protocol for SDN, standardizes communication between the controller and the data plane, offering a common programming interface for SDN networks [20].  
Traditional routing protocols like OSPF, BGP, MPLS, and EIGRP are widely deployed and extensively tested. However, these protocols cannot be directly applied to SDN-based networks. Efforts have been made to adapt these protocols for SDN environments. One such effort is CPQD's development of RouteFlow [14], a framework that enables centralized IP routing services in SDN. RouteFlow consists of three main components: the RouteFlow Controller (RFproxy), the RouteFlow Server (RFServer), and a virtual network within the RFServer. The RFproxy discovers network topology, while the RFServer maintains a virtual machine (VM) for each OpenFlow switch in the physical network. Each VM mirrors the physical switch's network interfaces (NICs) and runs an open routing protocol stack, dynamically maintaining connectivity via software switches. Once the virtual environment is configured, the routing engine (such as Quagga) populates routing tables, which are then translated into flow entries and applied to the corresponding switches.  
Several researchers have proposed similar protocols that run as applications on top of the SDN controller. However, as demonstrated in [15], utilizing RouteFlow services is more efficient. In this paper, we use RouteFlow to configure Open Shortest Path First, (OSPF) within an SDN environment. We selected OSPF due to its open-source nature and its ability to provide minimal failover times when configured through RouteFlow. To ensure QoS for specific network flows, we further customize the SDN controller (RFproxy) by adding a policy-based routing (PBR) module. The PBR module monitors congestion by tracking queuing delay, and when a predefined threshold is reached, it identifies alternative routes to reduce delay and packet loss. Our experimental results validate the effectiveness of this approach.