# "create\_volume() takes at most 4 arguments (6 given)" error while running ec2\_vol

**URL:** <https://forum.ansible.com/t/create-volume-takes-at-most-4-arguments-6-given-error-while-running-ec2-vol/14221>\
**Category:** Ansible Project\
**Created:** [December 25, 2013, 1:25pm UTC](https://forum.ansible.com/t/create-volume-takes-at-most-4-arguments-6-given-error-while-running-ec2-vol/14221 "2013-12-25T13:25:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Codezerk](https://avatars.discourse-cdn.com/v4/letter/c/8edcca/32.png) [@Codezerk](https://forum.ansible.com/u/Codezerk)\
**Post date:** [December 25, 2013, 1:25pm UTC](https://forum.ansible.com/t/create-volume-takes-at-most-4-arguments-6-given-error-while-running-ec2-vol/14221/1 "2013-12-25T13:25:24Z")

</div>

While running the latest development release I’m getting the error:

invalid output was: Traceback (most recent call last):  
File “/root/.ansible/tmp/ansible-1387976056.03-218115800862115/ec2\_vol”, line 1324, in   
main()  
File “/root/.ansible/tmp/ansible-1387976056.03-218115800862115/ec2\_vol”, line 207, in main  
volume = ec2.create\_volume(volume\_size, zone, None, volume\_type, iops)  
TypeError: create\_volume() takes at most 4 arguments (6 given)

My task is:

- name: create a volume for the dbs  
local\_action:  
module: ec2\_vol  
instance: “{{item.id}}”  
volume\_size: 100  
region: “{{ec2\_region}}”  
with\_items: ec2.instances
