dell / ansible-powermax

Ansible Modules for Dell PowerMax
GNU General Public License v3.0
36 stars 35 forks source link

[FEATURE]: dellemc.powermax.storagegroup - Make vol_name an optional argument #23

Closed jonathanhellman8 closed 1 year ago

jonathanhellman8 commented 2 years ago

Currently when using the storagegroup module to create new volumes to an existing storage group, vol_name needs to be provided to label the volume. Is there any way of not making vol_name a required input? There's no requirement in the storage array to label a volume when creating volumes for a SG. Currently I add a randomly generated string to vol_name to be able to use this module to create volumes to a SG over and over again without any vol_names conflicting.

Or is there any other way of achieving the very same thing without having to add a random string to vol_name?

When not using a unique vol_name it does return:

"msg": "A volume with identifier bar but different size 6.0 GB already exists. Use a different identifier for volume creation. Currently, we support only unique identifiers for volume creation on PowerMax from Ansible"

csalitros commented 1 year ago

I could use this as well... I usually just tag the volume with the SG Name is going into.

anupamaloke commented 1 year ago

@csalitros, this feature is going to be part of v2.1.0 that is going to come out later this week.

csalitros commented 1 year ago

I'm able to fill and StorageGroup without volume names in 2.1.0 ... but if I want to have some type of name, it has to be unique.

For example, this creates the SG with 3 volumes: ` - name: Creating Storage Group {{ storagegroup_name }} with LUNs dellemc.powermax.storagegroup: <<: *unisphere_vars sg_name: "{{ storagegroup_name }}" service_level: "{{ service_level }}" srp: "SRP_1" compression: True state: "{{ sgstate }}" volumes:

rawstorage commented 1 year ago

if you omit the vol_name you can add multiple volumes in one change without the volume id, this is not an idempotent task though if you need your task to be idempotent then you should always use the volume name or add volume id for existing volumes to ensure idempotency.

anupamaloke commented 1 year ago

Closing the issue as it has been fixed by #28