storage icon indicating copy to clipboard operation
storage copied to clipboard

Duplicate package checks for lvm2

Open tabowling opened this issue 7 years ago • 1 comments

Both lv and vg tasks are checking for lvm2 package to be installed. This results in duplicate checking which can slow down playbook execution.

[tbowling@tbowling storage]$ grep LVM2 */*
tasks/lv-default.yml:- name: Install LVM2 commands as needed
tasks/vg-default.yml:- name: Install LVM2 commmands as needed

It would be better to check for any packages one time at a global level, This would include any other toolings such as lvm2, parted, or others. A WHEN condition could be used so that you are only checking for those packages when that technology is requested. for example, if use_partitions is false, do not verify that package is installed.

tabowling avatar Nov 24 '18 14:11 tabowling

#2 should help with this. If you get a chance to test, please provide feedback.

dwlehman avatar Nov 26 '18 12:11 dwlehman