Updates to the vm_tracker
New:
- Script to delete VMs
- Unified script to search for the VM virsh names
and prepare list with cmp node names
- Examples
Fixes
- 'analyze.py' is Python3 friendly now
Related-PROD: PROD-35666
Change-Id: Idd4262b15adb4d763ced80f02f565c2c01340ed5
diff --git a/scripts/vm_tracker/gen_del_vms.sh b/scripts/vm_tracker/gen_del_vms.sh
new file mode 100644
index 0000000..a3c8219
--- /dev/null
+++ b/scripts/vm_tracker/gen_del_vms.sh
@@ -0,0 +1,7 @@
+#!/bin/bash
+cmp_mask="cmp"
+echo "Using Compute nodes mask of ${cmp_mask}"
+python analyze.py | tee vms.list
+cat vms.list | cut -d' ' -f 3 >vms
+cat vms | xargs -I{} grep "{}\|${cmp_mask}" ./virsh_vms >to_del_vms
+rm vms