You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: Unknown parameter in input: "size", must be one of: DryRun, VolumeId, Size, VolumeType, Iops, Throughput, MultiAttachEnabled
fatal: [test-sjoerd-01]: FAILED! => {"changed": false, "module_stderr": "Traceback (most recent call last):\n File \"/home/sjoerd/.ansible/tmp/ansible-tmp-1629896709.667519-16865-53038063967578/AnsiballZ_ec2_vol.py\", line 102, in <module>\n _ansiballz_main()\n File \"/home/sjoerd/.ansible/tmp/ansible-tmp-1629896709.667519-16865-53038063967578/AnsiballZ_ec2_vol.py\", line 94, in _ansiballz_main\n invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\n File \"/home/sjoerd/.ansible/tmp/ansible-tmp-1629896709.667519-16865-53038063967578/AnsiballZ_ec2_vol.py\", line 40, in invoke_module\n runpy.run_module(mod_name='ansible_collections.amazon.aws.plugins.modules.ec2_vol', init_globals=None, run_name='__main__', alter_sys=True)\n File \"/usr/lib/python3.8/runpy.py\", line 207, in run_module\n return _run_module_code(code, init_globals, run_name, mod_spec)\n File \"/usr/lib/python3.8/runpy.py\", line 97, in _run_module_code\n _run_code(code, mod_globals, init_globals,\n File \"/usr/lib/python3.8/runpy.py\", line 87, in _run_code\n exec(code, run_globals)\n File \"/tmp/ansible_amazon.aws.ec2_vol_payload_w1_zkwi7/ansible_amazon.aws.ec2_vol_payload.zip/ansible_collections/amazon/aws/plugins/modules/ec2_vol.py\", line 809, in <module>\n File \"/tmp/ansible_amazon.aws.ec2_vol_payload_w1_zkwi7/ansible_amazon.aws.ec2_vol_payload.zip/ansible_collections/amazon/aws/plugins/modules/ec2_vol.py\", line 782, in main\n File \"/tmp/ansible_amazon.aws.ec2_vol_payload_w1_zkwi7/ansible_amazon.aws.ec2_vol_payload.zip/ansible_collections/amazon/aws/plugins/modules/ec2_vol.py\", line 398, in update_volume\n File \"/tmp/ansible_amazon.aws.ec2_vol_payload_w1_zkwi7/ansible_amazon.aws.ec2_vol_payload.zip/ansible_collections/amazon/aws/plugins/module_utils/core.py\", line 289, in deciding_wrapper\n File \"/usr/local/lib/python3.8/dist-packages/botocore/client.py\", line 357, in _api_call\n return self._make_api_call(operation_name, kwargs)\n File \"/usr/local/lib/python3.8/dist-packages/botocore/client.py\", line 648, in _make_api_call\n request_dict = self._convert_to_request_dict(\n File \"/usr/local/lib/python3.8/dist-packages/botocore/client.py\", line 696, in _convert_to_request_dict\n request_dict = self._serializer.serialize_to_request(\n File \"/usr/local/lib/python3.8/dist-packages/botocore/validate.py\", line 293, in serialize_to_request\n raise ParamValidationError(report=report.generate_report())\nbotocore.exceptions.ParamValidationError: Parameter validation failed:\nUnknown parameter in input: \"size\", must be one of: DryRun, VolumeId, Size, VolumeType, Iops, Throughput, MultiAttachEnabled\n", "module_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}
Code of Conduct
I agree to follow the Ansible Code of Conduct
The text was updated successfully, but these errors were encountered:
#371) (#479)
ec2_vol: backport to stable-1.5 to fix modify_volume size option bug
SUMMARY
Back port to stable-1.5 to fix a bug in modify_volume, 'size' option.
Fixes#471.
ISSUE TYPE
Bugfix Pull Request
COMPONENT NAME
ec2_vol
ADDITIONAL INFORMATION
Required fix was done but was not applied in 1.5.0 release.
For more details, please visit #471.
Backports: #371
Depends-On: #491
Reviewed-by: Jill R <None>
Reviewed-by: Alina Buzachis <None>
Reviewed-by: None <None>
Summary
When you try to modify a exiting AWS volume attached to a running instance, withj the option
modify_volume: true
, you get this error:Unknown parameter in input: "size", must be one of: DryRun, VolumeId, Size, VolumeType, Iops, Throughput, MultiAttachEnabled
The problem appears to be in de update_volume function in ec2_vol.py where it says:
req_obj['size'] = target_size
.If you change this in
req_obj['Size'] = target_size
, everything works fine.I noticed the change in the main branch, but have not found it in the current 1.5.0 release
Issue Type
Bug Report
Component Name
ec2_vol
Ansible Version
Collection Versions
amazon.aws 1.4.1 #(also tried 1.5.0)
AWS SDK versions
Configuration
none
OS / Environment
Ubuntu 20.04
Steps to Reproduce
Expected Results
I expected to increase the existing volume
Actual Results
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: Unknown parameter in input: "size", must be one of: DryRun, VolumeId, Size, VolumeType, Iops, Throughput, MultiAttachEnabled fatal: [test-sjoerd-01]: FAILED! => {"changed": false, "module_stderr": "Traceback (most recent call last):\n File \"/home/sjoerd/.ansible/tmp/ansible-tmp-1629896709.667519-16865-53038063967578/AnsiballZ_ec2_vol.py\", line 102, in <module>\n _ansiballz_main()\n File \"/home/sjoerd/.ansible/tmp/ansible-tmp-1629896709.667519-16865-53038063967578/AnsiballZ_ec2_vol.py\", line 94, in _ansiballz_main\n invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\n File \"/home/sjoerd/.ansible/tmp/ansible-tmp-1629896709.667519-16865-53038063967578/AnsiballZ_ec2_vol.py\", line 40, in invoke_module\n runpy.run_module(mod_name='ansible_collections.amazon.aws.plugins.modules.ec2_vol', init_globals=None, run_name='__main__', alter_sys=True)\n File \"/usr/lib/python3.8/runpy.py\", line 207, in run_module\n return _run_module_code(code, init_globals, run_name, mod_spec)\n File \"/usr/lib/python3.8/runpy.py\", line 97, in _run_module_code\n _run_code(code, mod_globals, init_globals,\n File \"/usr/lib/python3.8/runpy.py\", line 87, in _run_code\n exec(code, run_globals)\n File \"/tmp/ansible_amazon.aws.ec2_vol_payload_w1_zkwi7/ansible_amazon.aws.ec2_vol_payload.zip/ansible_collections/amazon/aws/plugins/modules/ec2_vol.py\", line 809, in <module>\n File \"/tmp/ansible_amazon.aws.ec2_vol_payload_w1_zkwi7/ansible_amazon.aws.ec2_vol_payload.zip/ansible_collections/amazon/aws/plugins/modules/ec2_vol.py\", line 782, in main\n File \"/tmp/ansible_amazon.aws.ec2_vol_payload_w1_zkwi7/ansible_amazon.aws.ec2_vol_payload.zip/ansible_collections/amazon/aws/plugins/modules/ec2_vol.py\", line 398, in update_volume\n File \"/tmp/ansible_amazon.aws.ec2_vol_payload_w1_zkwi7/ansible_amazon.aws.ec2_vol_payload.zip/ansible_collections/amazon/aws/plugins/module_utils/core.py\", line 289, in deciding_wrapper\n File \"/usr/local/lib/python3.8/dist-packages/botocore/client.py\", line 357, in _api_call\n return self._make_api_call(operation_name, kwargs)\n File \"/usr/local/lib/python3.8/dist-packages/botocore/client.py\", line 648, in _make_api_call\n request_dict = self._convert_to_request_dict(\n File \"/usr/local/lib/python3.8/dist-packages/botocore/client.py\", line 696, in _convert_to_request_dict\n request_dict = self._serializer.serialize_to_request(\n File \"/usr/local/lib/python3.8/dist-packages/botocore/validate.py\", line 293, in serialize_to_request\n raise ParamValidationError(report=report.generate_report())\nbotocore.exceptions.ParamValidationError: Parameter validation failed:\nUnknown parameter in input: \"size\", must be one of: DryRun, VolumeId, Size, VolumeType, Iops, Throughput, MultiAttachEnabled\n", "module_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}
Code of Conduct
The text was updated successfully, but these errors were encountered: