Data Center on Desk - virtual network infrastructure for VirtualBox VMs.
DCoD system is intended to create and manage virtual L2 networks for VMs running on different hosts under VirtualBox hypervisor.
- VxLAN used as overlay technology
- Head End Replication mechanism used for handling boradcast traffic
- Windows or Linux system
- VirtualBox hypervisor running
- SSH servers running (connection using username&password required):
- Windows -- Bitvise SSH server
- Linux -- OpenSSH server
- virtnet_proxy VM imported to VirtualBox
- For Windows systems -- VBoxManage.exe tool available under \Program Files\Oracle\Virtualbox\ path
- On Director -> Python 3 with paramiko, yaml, logging, time, argparse, threading
6.1. For monitoring server Flask, json, requests, flask_restful
- DHCP server running in LAN network in order to assign IP address to virtnet_proxy VM's bridged interface
NOTE: You do not have to manually start virtnet_proxy VM, if it does not run, the script automatically launches it. NOTE: Script uses generic password for remote command execution on proxy VMs. It is read from password file. You can manually change it directly on proxy VM.
- Fill in the hosts yaml file with your hypervisor hosts ip addresses, ssh credentials & OS type (windows or linux)
- Run virtnet script e.g. ./virtnet.py create --vni <VNI> -f <hosts file>
- Wait until script finishes. It can take some time depending on number of hosts
- Make sure you have valid hosts file (all hypervisors covered)
- Run virtnet script e.g. ./virtnet.py remove --vni <VNI> -f <hosts file> in order to remove virtual network with specific VNI
- Wait until script finishes. It can take some time depending on number of hosts
NOTE: this procedure stops all virtnet_proxy VMs & clears its interfaces, so that the Proxy is in its generic state.
- Make sure you have valid hosts file (all hypervisors covered)
- Run virtnet script e.g. ./virtnet.py stop-proxies -f <hosts file> in order to remove virtual network with specific VNI
- Wait until script finishes. It can take some time depending on number of hosts
NOTE Current implementation allows user to start the monitoring server which collects data form all proxies in system (in fact collects data from ifconfig command, executed on all proxies).
- Make sure you have valid hosts file (all hypervisors covered)
- Run server script e.g. ./server.py -f <hosts file> -p <port> in order to start the monitoring server on localhost.
- Go to http://localhost:<port>/status URL in order to get info about running DCoD system (currently presented in JSON format).
Key components:
- Hypervisor - host with VirtualBox software running
- Proxy VM - virtnet_proxy VM, running on each hypervisor, responsible for overlay packets encap/decap & broadcast traffic handling etc. In other words - overlay VTEP
- Internal network - VirtualBox internal network created automatically for each virtual network (identified by VNI), access point to DCoD infrastructure for user's VMs
- Director - logical component, place (host) where virtnet.py script & monitoring server script are available. Director must have access to all Hyperviors (DCoD hosts) via SSH
- First of all code cleaning. I'm aware it is a mess. Initially it just had to work. I'm a network engineer, rather than programmer, still wanting to learn how to code though... :)
- The windows VBoxManage.exe file location is hardcoded. Should make it flexible
- Add the change of virtnet_proxy VM ssh password functionality
- Add the ssh keypair login functionality (both to hosts and proxies)
- Other stuff...