Submitted:
07 April 2025
Posted:
08 April 2025
You are already at the latest version
Abstract
Keywords:
1. Introduction
1.1. Background
System Heterogeneity
Nested Virtualization
Flannel and VXLAN
Linux Firewall
Simulation and Emulation
QEMU and Libvirt
Ubuntu Cloud-Images and Cloud-Init
1.2. Related Work
1.3. Contributions
- Automatic deployment of a heterogeneous Kubernetes cluster on a homogeneous OpenStack cloud including nodes with emulated hardware via QEMU.
- Configurable settings to specify the hardware to emulate as well as how many nodes should be deployed for a given specification.
- Open source access to the Q8S Python code and Bash scripts, enabling extensibility to include additional features of QEMU and libvirt.
1.4. Outline
2. Materials and Methods
- FR1
- Required resources are requested from an existing OpenStack environment.
- FR2
-
The specifications of a node type on the to be emulated cluster can be set by the user, including:
- FR2.1
- System architecture, e.g., x86 or ARM
- FR2.2
- CPU speed and number
- FR2.3
- Memory size
- FR2.4
- Storage Size
- FR3
- The user can specify the number of nodes per type.
- FR4
- The hardware of every worker node is emulated. This also includes any nodes that might run the same architecture as the host system.
- FR5
- After successful completion of Q8S, the user is provided with a working Kubernetes cluster, which meets the provided specifications and can execute real workloads.
- FR6
- No additional privileges beyond regular user permission in the existing OpenStack environment are required.
2.1. Q8S Design
- User interface
- OpenStack instances
- QEMU VMs
-
VM SnapshotsThis approach involved preparing a VM with all the required dependencies and saving it as a snapshot, which is then provided to the QEMU hosts. However, we wanted Q8S to be flexible and this approach would require recreating said snapshots for every update to the images for every specified node type.
-
Autoinstall for Ubuntu ServerUbuntu server has a feature to automatically set up a system when given an autoinstall configuration. We explored this option and it worked for our x86 images but we encountered problems for our ARM images.
-
Ubuntu Cloud-ImagesBesides Ubuntu server images, Canonical also provides Ubuntu Cloud-Images, which are lightweight for Ubuntu OS images with around 600 MB and can be configured via cloud-init settings. Cloud-Images are available for different system architectures including x86 and ARM while utilizing identical setup instructions. While this decision locked Q8S into only supporting Ubuntu based hosts, we consider this a reasonable trade-off compared to specifying setup instructions for various Linux distributions.
2.2. Design Validation
3. Results
3.1. Implementation
Networking
Configuration
- git_url: A URL pointing to a Q8S git repository, which is either public or accessible via embedded access tokens. This is required for the later installation stages to download the respective setup scripts on the new nodes.
- private_network_id: The id of the internal network in which all hosts reside and can be found in the OpenStack Horizon web interface under networks as the id of the private subnet. This is required for requesting new VMs via the OpenStack API.
- remote_ip_prefix: The IP mask of the OpenStack network. In our environment this is 10.254.1.0/24.
- default_image_name: The name of the OS image that should be used for the OpenStack images. Q8S expects this to be an Ubuntu image.
- name_of_initial_instance: The name of the starting instance in OpenStack. This is required for updating its security groups.
- security_groups: The list of OpenStack security groups that should be added to each node. This list has to at least contain q8s-cluster, which is the group configured for internal communication of the Kubernetes cluster.
- required_tcp_ports: The list of TCP ports that should be opened in the q8s-cluster security group for inter-node communication. The list given in the example in clusterYAML should be kept but further ports may be added.
- required_udp_ports: The same as for TCP ports above but for UDP.
- worker_port_range_min: This is the lower end of the port range that is to be opened in addition to the TCP ports specified above and used for Kubernetes container node ports.
- worker_port_range_max: The high end for the port range as specified above.
- master_node_flavor: Flavor to be used by additional control plane nodes. The flavor in OpenStack specifies the amount of CPUs and system memory OpenStack should allocate from a project quota to a specific VM.
- number_additional_master_nodes: The number of control plane nodes that Q8S should deploy in addition to the starting instance. The control plane IP is always set to the IP of the node running Q8S and does not deploy fail over mechanisms. Therefore, even if the created cluster includes multiple control plane nodes, it is not a high-availability (HA) deployment.
- worker: The vm_types specified in the next section can be used here to indicate how many instances of a given type should be deployed by Q8S.
- architecture: System architecture of the emulated CPU. Our Q8S prototype supports x86_64 and arm_64.
- num_cpus: The number of emulated CPUs that should be available in the QEMU VM.
- cpu_model: Specific CPU model that should be emulated by QEMU, which also determines the available CPU speed. The list of supported CPU models depends on QEMU and can be found in its documentation.
- machine_model: Machine model requested through QEMU. This should be kept as virt.
- ram: The amount of system memory to allocate for the QEMU VM in MB.
- storage: Amount of storage to allocate for the QEMU VM in GB.
- openstack_flavor: Flavor to use in OpenStack for the host. The flavor should include at least if not more CPUs than the emulated node.
Deployment Process
- Creation of the security group q8s-cluster if it does not exist and the configuration of the rules as specified in the settings file.
- Creation of an SSH key pair, which is uploaded to OpenStack such that the new VMs get initialized with it and can later on be accessed.
- Creation of the OpenStack VMs via its API for the control plane and worker nodes.
- Waiting for all new OpenStack VMs to be reachable via SSH.
- Installation of Kubernetes dependencies and system configurations required for Kubernetes on the instance running Q8S.
- Initializing the Kubernetes cluster and installing Flannel.
- Extracting the Kubernetes token for joining of worker nodes and uploading cluster certificates, required for joining control plane nodes.
- Installation of Kubernetes dependencies and system configurations on the additional control plane nodes.
- Joining of the additional control plane nodes to the cluster.
- Installation of QEMU and libvirt on the worker hosts.
- Configuring of the QEMU network to ensure the desired IP address that matches the host IP will be assigned to the QEMU VM.
- Downloading of the Ubuntu Cloud-Images.
- Preparation of the user-data and meta-data files for the Cloud-Image VM.
- Preparation of the Cloud-Image for QEMU.
- Creation of the QEMU VM from the Cloud-Image.
- Installation of Kubernetes and dependencies and system configurations on the QEMU VMs as triggered by cloud-init.
- Waiting for all worker nodes to join the Kubernetes cluster.
3.2. Evaluation
Benchmark
- Worker-Node-to-Worker-Node round-trip latency:
- Pod-to-Pod (different nodes) round-trip latency:
- Pod-to-Pod (same node) round-trip latency:
- Worker-Node-to-Control-Plane-Node round-trip latency:
- Control-Plane-Node-to-Control-Plane-Node round-trip latency:
Requirements
4. Discussion
4.1. Limitations
4.2. Implications
5. Conclusions
5.1. Future Work
Author Contributions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Acknowledgments
Conflicts of Interest
Abbreviations
| IoT | Internet of Things |
| VM | Virtual Machine |
| IO | Input/Output |
| VMM | Virtual Machine Manager |
| IP | Internet Protocol |
| LAN | Local Area Network |
| VXLAN | Virtual Extensible LAN |
| NAT | Network Adress Translation |
| QEMU | Quick EMUlator |
| KVM | Kernel-based Virtual Machine |
| MIPS | Million Instructions Per Second |
| API | Application Programming Interface |
| AI | Artificial Intelligence |
| CLI | Command Line Interface |
| YAML | Yet Another Markup Language |
| OS | Operating System |
| VTEP | VXLAN Tunnel Endpoint |
| SNAT | Source NAT |
| DNAT | Destination NAT |
Appendix A
| Listing 1. An Example File for a Cluster Definition. The notation using ’!’, e.g., !ClusterData and !VmType, is used by Q8S to map the respective sections of the configuration to Python data classes. |
![]() |
References
- Kiswani, J.H.; Dascalu, S.M.; Harris, F.C. Cloud Computing and Its Applications: A Comprehensive Survey 2021. 28.
- Islam, R.; Patamsetti, V.; Gadhi, A.; Gondu, R.M.; Bandaru, C.M.; Kesani, S.C.; Abiona, O. The Future of Cloud Computing: Benefits and Challenges. International Journal of Communications, Network and System Sciences 2023, 16, 53–65. [Google Scholar] [CrossRef]
- CNCF Annual Survey 2023, 2023.
- Senjab, K.; Abbas, S.; Ahmed, N.; Khan, A.u.R. A Survey of Kubernetes Scheduling Algorithms. Journal of Cloud Computing 2023, 12, 87. [Google Scholar] [CrossRef]
- Sadeeq, M.M.; Abdulkareem, N.M.; Zeebaree, S.R.M.; Ahmed, D.M.; Sami, A.S.; Zebari, R.R. IoT and Cloud Computing Issues, Challenges and Opportunities: A Review. Qubahan Academic Journal 2021, 1, 1–7. [Google Scholar] [CrossRef]
- Carrión, C. Kubernetes Scheduling: Taxonomy, Ongoing Issues and Challenges. Acm Computing Surveys 2022, 55, 138–1. [Google Scholar] [CrossRef]
- Ahmad, I.; AlFailakawi, M.G.; AlMutawa, A.; Alsalman, L. Container Scheduling Techniques: A Survey and Assessment. Journal of King Saud University - Computer and Information Sciences 2022, 34, 3934–3947. [Google Scholar] [CrossRef]
- Mars, J.; Tang, L.; Hundt, R. Heterogeneity in “Homogeneous” Warehouse-Scale Computers: A Performance Opportunity.
- Kunkel, J.; Boehme, C.; Decker, J.; Magugliani, F.; Pleiter, D.; Koller, B.; Sivalingam, K.; Pllana, S.; Nikolov, A.; Soyturk, M.; et al. DECICE: Device-edge-cloud Intelligent Collaboration Framework. In Proceedings of the Computing Frontiers. ACM; 5 2023. [Google Scholar] [CrossRef]
- Calheiros, R.N.; Ranjan, R.; Beloglazov, A.; De Rose, C.A.F.; Buyya, R. CloudSim: A Toolkit for Modeling and Simulation of Cloud Computing Environments and Evaluation of Resource Provisioning Algorithms. Software: Practice and Experience 2011, 41, 23–50. [Google Scholar] [CrossRef]
- Bux, M.; Leser, U. DynamicCloudSim: Simulating Heterogeneity in Computational Clouds. In Proceedings of the Proceedings of the 2nd ACM SIGMOD Workshop on Scalable Workflow Execution Engines and Technologies, New York, NY, USA, 6 2013. [CrossRef]
- Kathiravelu, P.; Veiga, L. Concurrent and Distributed CloudSim Simulations. In Proceedings of the 2014 IEEE 22nd International Symposium on Modelling, Analysis & Simulation of Computer and Telecommunication Systems; 9 2014; pp. 490–493. [Google Scholar] [CrossRef]
- Calheiros, R.N.; Netto, M.A.; De Rose, C.A.; Buyya, R. EMUSIM: An Integrated Emulation and Simulation Environment for Modeling, Evaluation, and Validation of Performance of Cloud Computing Applications. Software: Practice and Experience 2013, 43, 595–612. [Google Scholar] [CrossRef]
- Wen, S.; Han, R.; Qiu, K.; Ma, X.; Li, Z.; Deng, H.; Liu, C.H. K8sSim: A Simulation Tool for Kubernetes Schedulers and Its Applications in Scheduling Algorithm Optimization. Micromachines 2023, 14, 651. [Google Scholar] [CrossRef] [PubMed]
- QEMU.
- GitHub - InfraBuilder/K8s-Bench-Suite: Simple Scripts to Benchmark Kubernetes Cluster Features.
- Libvirt: The Virtualization API.
- Anthony, R.J. Chapter 5 - The Architecture View. In Systems Programming; Anthony, R.J., Ed.; Morgan Kaufmann: Boston, 2016; pp. 277–382. [Google Scholar] [CrossRef]
- Rodríguez-Haro, F.; Freitag, F.; Navarro, L.; Hernánchez-sánchez, E.; Farías-Mendoza, N.; Guerrero-Ibáñez, J.A.; González-Potes, A. A Summary of Virtualization Techniques. Procedia Technology 2012, 3, 267–272. [Google Scholar] [CrossRef]
- Song, Y.; Wang, H.; Soyata, T. Hardware and Software Aspects of VM-Based Mobile-Cloud Offloading; 2015; pp. 247–271. [CrossRef]
- Tsetse, A.; Tweneboah-Koduah, S.; Rawal, B.; Zheng, Z.; Prattipati, M. A Comparative Study of System Virtualization Performance. In Proceedings of the 2019 IEEE 20th International Conference on Information Reuse and Integration for Data Science (IRI); 7 2019; pp. 372–378. [Google Scholar] [CrossRef]
- Lim, J.T.; Nieh, J. Optimizing Nested Virtualization Performance Using Direct Virtual Hardware. In Proceedings of the Proceedings of the Twenty-Fifth International Conference on Architectural Support for Programming Languages and Operating Systems, Lausanne Switzerland, 3 2020. [CrossRef]
- Kapočius, N. Overview of Kubernetes CNI Plugins Performance. Mokslas - Lietuvos ateitis 2020, 12, 1–5. [Google Scholar] [CrossRef]
- Kumar, R.; Trivedi, M.C. Networking Analysis and Performance Comparison of Kubernetes CNI Plugins. In Proceedings of the Advances in Computer, Communication and Computational Sciences; Bhatia, S.K.; Tiwari, S.; Ruidan, S.; Trivedi, M.C.; Mishra, K.K., Eds., Singapore; 2021; pp. 99–109. [Google Scholar] [CrossRef]
- Maria, A. Introduction to Modeling and Simulation. In Proceedings of the Proceedings of the 29th Conference on Winter Simulation, 1997, pp.
- Hasse, V.F. Emulation of Heterogeneous Kubernetes Clusters Using QEMU, 2024. [CrossRef]
- Christensen, M.J.; Richter, T. Achieving Reliable UDP Transmission at 10 Gb/s Using BSD Socket for Data Acquisition Systems. Journal of Instrumentation 2020, 15, T09005. [Google Scholar] [CrossRef]
- https://github.com/InfraBuilder/benchmark-k8s-cni-2020-08/blob/master/results/doc-flannel.u18.04-default/doc-flannel.u18.04-default-run1.knbdata.




| Node Type | Pod-to-Pod | Pod-to-Service | ||
|---|---|---|---|---|
| TCP | UDP | TCP | UDP | |
| OpenStack Instance Nodes | 93 | 94.5 | 93 | 94.5 |
| Emulated Nodes | 93 | 89.7 | 93 | 89.4 |
| Node Type | Idle | Pod-to-Pod | Pod-to-Service | ||
|---|---|---|---|---|---|
| TCP | UDP | TCP | UDP | ||
| OpenStack, client node | 1.52 | 1.98 | 51.43 | 2.21 | 56.93 |
| Emulated, client node | 14.33 | 31.66 | 63.99 | 32.74 | 63.22 |
| OpenStack, server node | 1.13 | 3.94 | 3.58 | 5.03 | 3.55 |
| Emulated, server node | 15.14 | 43.81 | 56.59 | 44.2 | 55.61 |
| Node Type | Idle | Pod-to-Pod | Pod-to-Service | ||
|---|---|---|---|---|---|
| TCP | UDP | TCP | UDP | ||
| OpenStack, client node | 350 | 387 | 379 | 388 | 365 |
| Emulated, client node | 429 | 442 | 438 | 441 | 433 |
| OpenStack, server node | 431 | 431 | 436 | 436 | 435 |
| Emulated, server node | 400 | 407 | 407 | 408 | 412 |
| Requ. | Description | Fulfilled |
|---|---|---|
| FR1 | Use existing OpenStack cloud for resources | yes |
| FR2 | Specify different node settings | yes |
| FR2.1 | Emulated system architecture | yes, x86 and ARM |
| FR2.2 | CPU speed and core count | yes, speed via CPU model |
| FR2.3 | Memory size | yes |
| FR2.4 | Storage size | yes |
| FR3 | Specify amount of different nodes in the cluster | yes |
| FR4 | Emulation of worker node hardware | yes |
| FR5 | Working Kubernetes cluster as defined | yes |
| FR6 | No additional privileges in OpenStack | yes |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 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/).
