Managed Forwarding Element Packet Caching
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current packet processing in software-based network forwarding is computationally expensive due to the need for extensive classification operations, especially in complex logical topologies, leading to high CPU usage and resource consumption.
Innovation Solution
A managed forwarding element with a hierarchy of cached flow entries, including an exact match cache, an aggregate flow cache, and staged flow tables, which minimizes classification operations by caching decisions and reducing the need for full classification on each packet, thereby optimizing processing efficiency.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Measurement precision
If full classification operations are performed on each packet using staged flow tables, then classification accuracy is improved, but processing time and CPU usage increase
Solution Approach 1:
The patent applies preliminary action by performing full classification operations on the first packet of each flow to build a cache entry, then using this pre-computed cache for subsequent packets in the same flow. This eliminates the need to repeat expensive classification operations for every packet while maintaining accurate classification results.
Solution Approach 2:
The patent creates a simplified copy of the classification result in the form of a cache entry that stores the matched flow table stage and corresponding flow entry. This copy allows subsequent packets to be classified by simple cache lookup rather than repeating the full classification process, significantly reducing processing time while preserving classification accuracy.
2Reliability
If extensive classification operations are performed on each packet, then classification completeness is improved, but resource consumption increases
Solution Approach 1:
The system performs the computationally expensive classification operations once per flow to build cache entries, then reuses these pre-computed results for all subsequent packets in the same flow. This preliminary action ensures complete classification is achieved without repeating the expensive operations for every packet, thereby reducing CPU usage while maintaining classification completeness.
Solution Approach 2:
The cache entry serves as a copy of the classification result that captures the essential classification information (matched stage and flow entry). This copy allows the system to maintain complete classification accuracy while avoiding the need to repeat the full classification process, thus reducing resource consumption.
3Speed
If cache is used for packet processing, then processing speed is improved, but memory usage increases
Solution Approach 1:
The patent extracts only the essential classification information needed for packet processing into the cache entry, specifically storing the matched flow table stage and corresponding flow entry identifier. This selective extraction provides sufficient processing speed improvement while minimizing the memory footprint of each cache entry compared to storing complete classification results.
Solution Approach 2:
The cache entry structure is designed to be universal and compact, storing only the critical information (stage and flow entry reference) that enables both fast processing and accurate classification. This multi-functional design allows the same cache structure to serve both speed improvement and memory efficiency goals.
Data Source
AI summary
Some embodiments provide a method for processing a packet received by a managed forwarding element. The method performs a series of packet classification operations based on header values of the received packet. The packet classifications operations determine a next destination of the received packet. When the series of packet classification operations specifies to send the packet to a network service that performs payload transformations on the packet, the method (1) assigns a service operation identifier to the packet that identifies the service operations for the network service to perform on the packet, (2) sends the packet to the network service with the service operation identifier, and (3) stores a cache entry for processing subsequent packets without the series of packet classification operations. The cache entry includes the assigned service operation identifier. The network service uses the assigned service operation identifier to process packets without performing its own classification operations.


