-
Notifications
You must be signed in to change notification settings - Fork 48
Running Experiments: VLAN Environment
Prerequisite: Follow the instructions on the Installation and Environment Setup Page.
VLAN: It’s Virtual LAN environment consists of a group of heterogeneous systems such as desktops, RPi, cloud VMs that persist in a single VPN. Different options to create a VLAN environment:- Option 1: You can create a number of VMs with different flavours in Azure/AWS/Openstack cloud(for e.g B2S, B4MS, B8MS in azure cloud). Option 2: Group of desktop machines. Option 3: Group of VM’s from cloud, Raspberry Pi devices and desktop machines.
To provide VLAN as an environment, choose any option as mentioned above based on your resource availability and note down all the list of IP addresses, cpu cores, power model and modify the configuration file located at framework/config/VLAN_config.json as shown below. Mark all the servers information as a list in a servers field in VLAN_config.json file. Note: size of the servers list should be equal to HOSTS size in main.py.
- All agents should run Ubuntu 18.04 LTS
- All agents should have kernel 4.15.xx. (For Azure, you can setup kernel by running debug/azure_downgrade_kernel.sh script in host machines).
- Server and agents should be able to communicate visa flask API on port 8081
- SSH should be using discoverable IP in a VLAN and SSH should using public-private key pair
- All agents should have username as 'ansible'
- Set environment type based on VMs/PMs of Datacenter object. Line 83 in main.py as either of Virtual or Physical.
- Update VLAN_config.json based on environment.
- Implement power models required in VLAN_config.json or set from existing models in metrics/powermodels/.
- Update based on arch the instructions in framework/server/scripts/instructions_arch.json (Optional).
- Update SLA requirement based on application requirements in framework/workload/*.py.
- Prepare main.py by modifying the global simulation parameters (line 59), as shown in the figure:
- Select the scheduling algorithm to run (line 96). For example, to run random scheduler use RandomScheduler(). To run GOBI scheduler use GOBIScheduler(‘energy_latency’+str(HOSTS))
- Set datacenter (line 85). Currently the simulator supports SimpleFog, BitbrainFog and AzureFog datacenter characteristics.
- Set workload generator (line 92). Currently supports a simple workload generator (SWSD) and BitBrain workload traces (BWGD).
- Run main.py (Same command in Linux/Windows)
python main.py -e VLAN -m 0
All results would be stored in logs/ folder. The .pk file in logs/*/ directory is the same as all_datasets/framework/$ALGO/*.pk where $ALGO is the algorithm.
For multiple series of experiments, creating and destroying VMs is not time efficient. To prevent destroying VMs after execution of an experiment use the mode tag in the argument.
-m is a mode and values could be 0,1,2,3
- 0 = Create a new vagrant environment by installing all the required packages in the VLAN/Vagrant environments and destroy the environment after simulation is completed. By default mode is 0.
- 1 = Create a new vagrant environment by installing all the required packages in the VLAN/Vagrant environments and the environment is retained for repetitive simulations.
- 2 = Use the existing environment
- 3 = Use the existing environment for the experiment and then destroy the existing environment. Thus, for the first time use mode 1, then use mode 2 till you are running experiments (to not destroy the setup) and finally use model 3 to use the existing environment and destroy it at the end of the experiments.
BSD-3-Clause. Copyright (c) 2020, Shreshth Tuli. All rights reserved.