Data Stream Processing for Packet-Level Analytics †
Abstract
:1. Introduction
- Reactive approaches detect and respond to performance and security alterations. To be effective, they need to identify in real time any alarming alterations caused by extracting useful information from the analyzed data. As a consequence, the configuration of the network must be rapidly changed to correct the detected problem(s).
- Proactive techniques try to predict possible sources of performance degradation or security attacks. When signals of a potential issue are detected, the network configuration is modified to prevent the identified problem from occurring. Solutions belonging to the Machine Learning and Artificial Intelligence (ML/AI) domains are good candidates to implement this kind of approach.
- In the fast data path, queries that are continuously executed on packet streams at line rate can be implemented by DaSP frameworks, as they specifically address real-time processing of data in the form of streams.
- So far, DaSP frameworks have been typically applied for developing streaming applications in traditional distributed environments (i.e., homogeneous clusters) and they achieve platform independence by relying on the Java Virtual Machine (JVM). As such, their performance does not quite match the level required to handle packets over the fast data path of network applications. Hence, in this work we specifically selected an innovative C++-based streaming library targeting multicores (i.e., WindFlow [1,2]) and applied proper optimizations to extend its application domain to packet-level analysis. In addition, suitable extensions for accommodating new accelerated data sources have been designed and provided.
- In case the elaboration produced in the fast data path is not sufficient and need to be refined by a second level of logic, the aggregated results of the first stage may be forwarded to a second processing tier (slow data path) in which the queries executed on streams of pre-digested statistics can be implemented with any DaSP framework. This is possible thanks to the lower data rate at which partial results are received from the first processing stage. In fact, the performance achievable by traditional DaSP frameworks are typically sufficient at this stage of the computation.
2. Background
- the need for the availability of proper APIs and programming abstractions to allow the control plane to configure and instruct the data plane processing nodes;
- the data plane itself must be able to perform early-stage data elaboration at (or nearly at) the network line rate;
- the control plane must be able to cope with the possibly significant computation burden imposed by different use-cases—for example, a system for Deep Packet Inspection (DPI), or, even more complex, Security Information and Event Management (SIEM).
2.1. Programmable Abstractions
2.2. Software Accelerated Packet Handling
- the overhead related to the interface positioned between the OS kernel and the userspace can be removed by fully bypassing it;
- copies of data between userspace and kernel memory can be avoided, getting rid of the other important source of overhead.
2.3. Higher–Level Frameworks
3. Data Stream Processing
4. The Processing Framework
4.1. Capturing Layer
4.2. First Stream Processing Stage
4.3. Refined Stream Processing Analysis
5. Example Application
5.1. Structure and Implementation
5.2. Optimizations
6. Experimental Evaluation
- The first one is equipped with a CPU Intel Core i7-3770K with 4 cores (8 hardware threads) and 4 GB of RAM. All cores dynamically share access to the last level cache L3 of 8 MB. Each core has a clock rate of 3.50 GHz and a L2 of 1 MB (L1 is 128 KB for data and 128 KB for instructions). The network interface used is an Intel Ethernet Controller XL710 for 40 Gb Ethernet QSFP+. This is the machine executing the traffic generation task.
- The second one has a CPU Intel Xeon E5-1660 v3 with 8 cores (16 hardware threads) and 64 GB of RAM. All cores dynamically share access to the last level cache L3 of 20 MB. Each core has a clock rate of 3.00 GHz and a L2 of 256 KB (L1 is 32 KB for data and 32 KB for instructions). Additionally, here the NIC is use is an Intel Ethernet Controller XL710 for 40 Gb Ethernet QSFP+. This is the machine that runs the streaming application. For reproducibility and performance, both frequency-scaling and sleep states deeper than C1 have been disabled.
6.1. Speed Test Configuration
6.2. Real-Traffic Configuration
7. Conclusions and Future Directions
Author Contributions
Funding
Acknowledgments
Conflicts of Interest
Abbreviations
API | Application Programming Interface |
BDSP | Big Data Stream Processing |
COTS | Commodity Off The Shelf |
CPU | Central Processing Unit |
DaSP | Data Stream Processing |
DPDK | Data Plane Development Kit |
DPI | Deep Packet Inspection |
eBPF | extended Berkeley Packet Filter |
FPGA | Field Programmable Gate Array |
GPU | Graphic Processing Unit |
GUI | Graphical User Interface |
INT | In-Band Network Telemetry |
JVM | Java Virtual Machine |
NFV | Network Function Virtualization |
NIC | Network Interface Card |
OS | Operating System |
POF | Protocol Oblivious Forwarding |
QoS | Quality of Service |
SDN | Software Defined Network |
SIEM | Security Information and Event Management |
SmartNIC | Smart Network Interface Card |
SPSC | Single Producer Single Consumer |
XDP | eXpress Data Path |
XFSM | eXtended Finite State Machines |
References
- Mencagli, G.; Torquati, M.; Griebler, D.; Danelutto, M.; Fernandes, L.G.L. Raising the Parallel Abstraction Level for Streaming Analytics Applications. IEEE Access 2019, 7, 131944–131961. [Google Scholar] [CrossRef]
- WindFlow: A C++17 Data Stream Processing Parallel Library for Multicores and GPUs. Available online: https://paragroup.github.io/WindFlow/ (accessed on 24 January 2021).
- Fais, A.; Procissi, G.; Giordano, S.; Oppedisano, F. Data Stream Processing in Software Defined Networks: Perspectives and Challenges. In Proceedings of the 2020 IEEE 25th International Workshop on Computer Aided Modeling and Design of Communication Links and Networks (CAMAD), Pisa, Italy, 14–16 September 2020; pp. 1–6. [Google Scholar] [CrossRef]
- McKeown, N.; Anderson, T.; Balakrishnan, H.; Parulkar, G.; Peterson, L.; Rexford, J.; Shenker, S.; Turner, J. OpenFlow: Enabling Innovation in Campus Networks. SIGCOMM Comput. Commun. Rev. 2008, 38, 69–74. [Google Scholar] [CrossRef]
- Bosshart, P.; Daly, D.; Gibb, G.; Izzard, M.; McKeown, N.; Rexford, J.; Schlesinger, C.; Talayco, D.; Vahdat, A.; Varghese, G.; et al. P4: Programming Protocol-independent Packet Processors. SIGCOMM Comput. Commun. Rev. 2014, 44, 87–95. [Google Scholar] [CrossRef]
- Barefoot. Tofino: World’s Fastest P4-Programmable Ethernet Switch ASICs. Available online: https://www.barefootnetworks.com/products/brief-tofino/ (accessed on 26 June 2020).
- Molnár, L.; Pongrácz, G.; Enyedi, G.; Kis, Z.L.; Csikor, L.; Juhász, F.; Kőrösi, A.; Rétvári, G. Dataplane Specialization for High-Performance OpenFlow Software Switching. In Proceedings of the 2016 Conference of the Association for Computing Machinery (ACM) Special Interest Group on Data Communication (SIGCOMM), Florianopolis, Brazil, 22–26 August 2016; pp. 539–552. [Google Scholar] [CrossRef] [Green Version]
- DPDK. Available online: http://dpdk.org (accessed on 15 June 2020).
- Open vSwitch. Available online: https://www.openvswitch.org/ (accessed on 16 February 2021).
- Sun, Q.; Xue, Y.; Li, S.; Zhu, Z. Design and Demonstration of High-Throughput Protocol Oblivious Packet Forwarding to Support Software-Defined Vehicular Networks. IEEE Access 2017, 5, 24004–24011. [Google Scholar] [CrossRef]
- Bianchi, G.; Bonola, M.; Capone, A.; Cascone, C. OpenState: Programming Platform-independent Stateful Openflow Applications Inside the Switch. SIGCOMM Comput. Commun. Rev. 2014, 44, 44–51. [Google Scholar] [CrossRef]
- Bonola, M.; Bifulco, R.; Petrucci, L.; Pontarelli, S.; Tulumello, A.; Bianchi, G. Implementing advanced network functions for datacenters with stateful programmable data planes. In Proceedings of the 2017 IEEE International Symposium on Local and Metropolitan Area Networks (LANMAN), Osaka, Japan, 12–14 June 2017; pp. 1–6. [Google Scholar]
- Pontarelli, S.; Bifulco, R.; Bonola, M.; Cascone, C.; Spaziani, M.; Bruschi, V.; Sanvito, D.; Siracusano, G.; Capone, A.; Honda, M.; et al. FlowBlaze: Stateful Packet Processing in Hardware. In Proceedings of the 16th USENIX Symposium on Networked Systems Design and Implementation (NSDI 19), Boston, MA, USA, 26–28 February 2019; pp. 531–548. [Google Scholar]
- Bonelli, N.; Giordano, S.; Procissi, G. Enif-Lang: A Specialized Language for Programming Network Functions on Commodity Hardware. J. Sens. Actuator Netw. 2018, 7, 34. [Google Scholar] [CrossRef] [Green Version]
- Bonelli, N.; Giordano, S.; Procissi, G.; Abeni, L. A Purely Functional Approach to Packet Processing. In Proceedings of the Tenth ACM/IEEE Symposium on Architectures for Networking and Communications Systems (ANCS ’14), Los Angeles, CA, USA, 20–21 October 2014; pp. 219–230. [Google Scholar]
- Bonelli, N.; Giordano, S.; Procissi, G. Network Traffic Processing With PFQ. IEEE J. Sel. Areas Commun. 2016, 34, 1819–1833. [Google Scholar] [CrossRef]
- Monsanto, C.; Reich, J.; Foster, N.; Rexford, J.; Walker, D. Composing Software-defined Networks. In Proceedings of the 10th USENIX Symposium on Networked Systems Design and Implementation, Lombard, IL, USA, 2–5 April 2013; pp. 1–14. [Google Scholar]
- The Frenetic Project. Available online: http://frenetic-lang.org/ (accessed on 15 June 2020).
- de Bruijn, W.; Bos, H.; Bal, H. Application-Tailored I/O with Streamline. ACM Trans. Comput. Syst. 2011, 29, 1–33. [Google Scholar] [CrossRef]
- VPP. Available online: https://wiki.fd.io/view/VPP (accessed on 15 June 2020).
- Extended Berkeley Packet Filter. Available online: https://www.iovisor.org/technology/ebpf (accessed on 24 June 2020).
- Braun, L.; Didebulidze, A.; Kammenhuber, N.; Carle, G. Comparing and improving current packet capturing solutions based on commodity hardware. In Proceedings of the 10th ACM SIGCOMM Conference on Internet Measurement (IMC ’10), Melbourne, Australia, 1–3 November 2010; pp. 206–217. [Google Scholar]
- Moreno, V.; Ramos, J.; Santiago del Rio, P.; Garcia-Dorado, J.; Gomez-Arribas, F.; Aracil, J. Commodity Packet Capture Engines: Tutorial, Cookbook and Applicability. Commun. Surv. Tutor. IEEE 2015, 17, 1364–1390. [Google Scholar] [CrossRef]
- Gallenmüller, S.; Emmerich, P.; Wohlfart, F.; Raumer, D.; Carle, G. Comparison of Frameworks for High-Performance Packet IO. In Proceedings of the Eleventh ACM/IEEE Symposium on Architectures for Networking and Communications Systems, Oakland, CA, USA, 7–8 May 2015; pp. 29–38. [Google Scholar]
- Rizzo, L. Netmap: A novel framework for fast packet I/O. In Proceedings of the 21st USENIX Conference on Security Symposium (USENIX Security 12), Bellevue, WA, USA, 8–10 August 2012; pp. 1–12. [Google Scholar]
- Fusco, F.; Deri, L. High speed network traffic analysis with commodity multi–core systems. In Proceedings of the 10th ACM SIGCOMM Conference on Internet Measurement (IMC ’10), Melbourne, Australia, 1–3 November 2010; pp. 218–224. [Google Scholar]
- Deri, L. PF_RING ZC (Zero Copy). Available online: http://www.ntop.org/products/packet-capture/pf_ring/pf_ring-zc-zero-copy/ (accessed on 15 June 2020).
- Høiland-Jørgensen, T.; Brouer, J.D.; Borkmann, D.; Fastabend, J.; Herbert, T.; Ahern, D.; Miller, D. The eXpress Data Path: Fast programmable packet processing in the Operating System Kernel. In Proceedings of the CoNEXT ’18: International Conference on Emerging Networking EXperiments and Technologies, Heraklion, Greece, 4–7 December 2018; ACM: New York, NY, USA, 2018; p. 13. [Google Scholar] [CrossRef] [Green Version]
- Linux Kernel Contributors. PACKET_MMAP. Available online: https://www.kernel.org/doc/Documentation/networking/packet_mmap.txt (accessed on 15 June 2020).
- Bonelli, N.; Vigna, F.D.; Giordano, S.; Procissi, G. Packet Fan—Out Extension for the pcap Library. IEEE Trans. Netw. Serv. Manag. 2018, 15, 976–990. [Google Scholar] [CrossRef]
- Kim, C.; Sivaraman, A.; Katta, N.; Bas, A.; Dixit, A.; Wobker, L.J. In-band Network Telemetry via Programmable Dataplanes. In Proceedings of the 2015 Conference of the Association for Computing Machinery (ACM) Special Interest Group on Data Communication (SIGCOMM), London, UK, 17–21 August 2015. [Google Scholar]
- Tang, S.; Li, D.; Niu, B.; Peng, J.; Zhu, Z. Sel-INT: A Runtime-Programmable Selective In-Band Network Telemetry System. IEEE Trans. Netw. Serv. Manag. 2020, 17, 708–721. [Google Scholar] [CrossRef]
- Liu, Z.; Manousis, A.; Vorsanger, G.; Sekar, V.; Braverman, V. One Sketch to Rule Them All: Rethinking Network Flow Monitoring with UnivMon. In Proceedings of the 2016 Conference of the Association for Computing Machinery (ACM) Special Interest Group on Data Communication (SIGCOMM), Florianopolis, Brazil, 22–26 August 2016; pp. 101–114. [Google Scholar] [CrossRef] [Green Version]
- Yu, M.; Jose, L.; Miao, R. Software Defined Traffic Measurements with OpenSketch. In Proceedings of the 10th USENIX Symposium on Networked Systems Design and Implementation, Lombard, IL, USA, 2–5 April 2013. [Google Scholar]
- Narayana, S.; Sivaraman, A.; Nathan, V.; Alizadeh, M.; Walker, D.; Rexford, J.; Jeyakumar, V.; Kim, C. Hardware-Software Co-Design for Network Performance Measurement. In Proceedings of the 15th ACM Workshop on Hot Topics in Networks (HotNets ’16), Atlanta, GA, USA, 9–10 November 2016; pp. 190–196. [Google Scholar] [CrossRef] [Green Version]
- Huang, D.; Koh, Y.S.; Dobbie, G. Rare Pattern Mining on Data Streams. In Proceedings of the 14th International Conference on Data Warehousing and Knowledge Discovery (DaWaK’12), Vienna, Austria, 3–6 September 2012; pp. 303–314. [Google Scholar] [CrossRef]
- Calders, T.; Dexters, N.; Gillis, J.J.; Goethals, B. Mining frequent itemsets in a stream. Inf. Syst. 2014, 39, 233–255. [Google Scholar] [CrossRef]
- Troiano, L.; Scibelli, G. Mining frequent itemsets in data streams within a time horizon. Data Know. Eng. 2014, 89, 21–37. [Google Scholar] [CrossRef]
- Borders, K.; Springer, J.; Burnside, M. Chimera: A Declarative Language for Streaming Network Traffic Analysis. In Proceedings of the 21st USENIX Conference on Security Symposium (USENIX Security 12), Bellevue, WA, USA, 8–10 August 2012; pp. 365–379. [Google Scholar] [CrossRef]
- Cranor, C.; Johnson, T.; Spataschek, O.; Shkapenyuk, V. Gigascope: A Stream Database for Network Applications. In Proceedings of the 2003 International Conference of the Association for Computing Machinery (ACM) Special Interest Group on Management of Data (SIGMOD), San Diego, CA, USA, 9–12 June 2003; pp. 647–651. [Google Scholar]
- Yuan, Y.; Lin, D.; Mishra, A.; Marwaha, S.; Alur, R.; Loo, B.T. Quantitative Network Monitoring with NetQRE. In Proceedings of the 2017 Conference of the Association for Computing Machinery (ACM) Special Interest Group on Data Communication (SIGCOMM), Los Angeles, CA, USA, 21–25 August 2017; pp. 99–112. [Google Scholar] [CrossRef]
- OpenSOC. Available online: https://github.com/OpenSOC/opensoc (accessed on 26 June 2020).
- Apache Metron. Available online: http://metron.apache.org/ (accessed on 26 June 2020).
- Apache Storm. Available online: https://storm.apache.org/ (accessed on 22 June 2020).
- Apache Flink. Available online: https://flink.apache.org/ (accessed on 22 June 2020).
- Apache Spark Streaming. Available online: https://spark.apache.org/streaming/ (accessed on 22 June 2020).
- Zeuch, S.; Monte, B.D.; Karimov, J.; Lutz, C.; Renz, M.; Traub, J.; Breß, S.; Rabl, T.; Markl, V. Analyzing Efficient Stream Processing on Modern Hardware. Proc. VLDB Endow. 2019, 12, 516–530. [Google Scholar] [CrossRef] [Green Version]
- Zhang, S.; He, B.; Dahlmeier, D.; Zhou, A.C.; Heinze, T. Revisiting the Design of Data Stream Processing Systems on Multi-Core Processors. In Proceedings of the 2017 IEEE 33rd International Conference on Data Engineering (ICDE), San Diego, CA, USA, 19–22 April 2017; pp. 659–670. [Google Scholar] [CrossRef]
- Gupta, A.; Birkner, R.; Canini, M.; Feamster, N.; Mac-Stoker, C.; Willinger, W. Network Monitoring as a Streaming Analytics Problem. In Proceedings of the 15th ACM Workshop on Hot Topics in Networks (HotNets ’16), Atlanta, GA, USA, 9–10 November 2016; pp. 106–112. [Google Scholar] [CrossRef] [Green Version]
- Gupta, A.; Harrison, R.; Canini, M.; Feamster, N.; Rexford, J.; Willinger, W. Sonata: Query-Driven Streaming Network Telemetry. In Proceedings of the 2018 Conference of the Association for Computing Machinery (ACM) Special Interest Group on Data Communication (SIGCOMM), Budapest, Hungary, 20–25 August 2018; pp. 357–371. [Google Scholar] [CrossRef] [Green Version]
- Fais, A. Benchmarking Data Stream Processing Frameworks on Multicores; Università di Pisa: Pisa, Italy, 2019; Available online: https://etd.adm.unipi.it/t/etd-09162019-220730 (accessed on 24 January 2021).
- De Matteis, T.; Mencagli, G. Parallel Patterns for Window-Based Stateful Operators on Data Streams: An Algorithmic Skeleton Approach. Int. J. Parallel Program. 2017, 45, 382–401. [Google Scholar] [CrossRef] [Green Version]
- Fais, A.; Giordano, S.; Procissi, G. On the Design of Fast and Scalable Network Applications Through Data Stream Processing. In Proceedings of the 2020 IEEE Conference on Network Function Virtualization and Software Defined Networks (NFV-SDN), Leganes, Madrid, Spain, 9–12 November 2020; pp. 150–154. [Google Scholar] [CrossRef]
- Al-Mansoori, A.; Yu, S.; Xiang, Y.; Sood, K. A Survey on Big Data Stream Processing in SDN Supported Cloud Environment. In Proceedings of the Australasian Computer Science Week Multiconference (ACSW ’18), Brisbane, Queensland, Australia, 30 January–2 February 2018. [Google Scholar] [CrossRef]
- Aldinucci, M.; Danelutto, M.; Kilpatrick, P.; Torquati, M. Fastflow: High-Level and Efficient Streaming on Multicores. In Programming Multi-Core and Many-Core Computing Systems; Pllana, S., Xhafa, F., Eds.; Wiley Publishing: Hoboken, NJ, USA, 2017; pp. 261–280. [Google Scholar] [CrossRef] [Green Version]
- Maffione, V.; Lettieri, G.; Rizzo, L. Cache-aware design of general-purpose Single-Producer–Single-Consumer queues. J. Softw. Pract. Exp. 2019, 49, 748–779. [Google Scholar] [CrossRef]
- The kernel development community. Reducing OS Jitter Due to Per-Cpu Kthreads. Available online: https://www.kernel.org/doc/html/latest/admin-guide/kernel-per-CPU-kthreads.html (accessed on 31 January 2020).
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |
© 2021 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).
Share and Cite
Fais, A.; Lettieri, G.; Procissi, G.; Giordano, S.; Oppedisano, F. Data Stream Processing for Packet-Level Analytics. Sensors 2021, 21, 1735. https://doi.org/10.3390/s21051735
Fais A, Lettieri G, Procissi G, Giordano S, Oppedisano F. Data Stream Processing for Packet-Level Analytics. Sensors. 2021; 21(5):1735. https://doi.org/10.3390/s21051735
Chicago/Turabian StyleFais, Alessandra, Giuseppe Lettieri, Gregorio Procissi, Stefano Giordano, and Francesco Oppedisano. 2021. "Data Stream Processing for Packet-Level Analytics" Sensors 21, no. 5: 1735. https://doi.org/10.3390/s21051735
APA StyleFais, A., Lettieri, G., Procissi, G., Giordano, S., & Oppedisano, F. (2021). Data Stream Processing for Packet-Level Analytics. Sensors, 21(5), 1735. https://doi.org/10.3390/s21051735