# Trouble with mount

**URL:** <https://forum.ansible.com/t/trouble-with-mount/22535>\
**Category:** Ansible Project\
**Created:** [September 13, 2016, 3:13pm UTC](https://forum.ansible.com/t/trouble-with-mount/22535 "2016-09-13T15:13:03Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mateus\_Interciso](https://avatars.discourse-cdn.com/v4/letter/m/8491ac/32.png) [@Mateus\_Interciso](https://forum.ansible.com/u/Mateus_Interciso)\
**Post date:** [September 13, 2016, 3:13pm UTC](https://forum.ansible.com/t/trouble-with-mount/22535/1 "2016-09-13T15:13:03Z")

</div>

Hello all, I’m veyr new on ansible and currently trying to make some automation with mount. Should be veyr simple, but please take a look at this.  
This is part of my playbook:

- mount:  
name: “{{ instance.value.mount }}”  
src: “/dev/{{ instance.value.volume }}/{{ instance.key }}”  
state: present  
fstype: ext4
- mount:  
name: “{{ instance.value.mount }}”  
src: “/dev/{{instance.value.volume }}/{{ instance.key }}”  
state: mounted  
fstype: ext4

Whenever I run this, the first mount works as expected (creating the line on /etc/fstab), however, the second mount fails with:

fatal: [brsptla0101]: FAILED! =\> {“changed”: false, “failed”: true, “msg”: “Error mounting /u01/diebs01: /bin/mount: invalid option – ‘T’\nUsage: mount -V : print version\n mount -h : print this help\n mount : list mounted filesystems\n mount -l : idem, including volume labels\nSo far the informational part. Next the mounting.\nThe command is `mount [-t fstype] something somewhere’.\nDetails found in /etc/fstab may be omitted.\n mount -a [-t|-O] … : mount all stuff from /etc/fstab\n mount device : mount device at the known place\n mount directory : mount known device here\n mount -t type dev dir : ordinary mount command\nNote that one does not really mount a device, one mounts\na filesystem (of the given type) found on the device.\nOne can also mount an already visible directory tree elsewhere:\n mount --bind olddir newdir\nor move a subtree:\n mount --move olddir newdir\nOne can change the type of mount containing the directory dir:\n mount --make-shared dir\n mount --make-slave dir\n mount --make-private dir\n mount --make-unbindable dir\nOne can change the type of all the mounts in a mount subtree\ncontaining the directory dir:\n mount --make-rshared dir\n mount --make-rslave dir\n mount --make-rprivate dir\n mount --make-runbindable dir\nA device can be given by name, say /dev/hda1 or /dev/cdrom,\nor by label, using -L label or by uuid, using -U uuid .\nOther options: [-nfFrsvw] [-o options] [-p passwdfd].\nFor many more details, say man 8 mount .\n”}

I thinks it’s passing -T instead of -t, how can I fix this?  
The only workaround I found is to use the shell command to mount the filesystem

I’m using ansible 2.2.0

Thank you.

---

<div class="post-metadata">

**Author:** ![Marat\_Bakeev](https://avatars.discourse-cdn.com/v4/letter/m/cc9497/32.png) [@Marat\_Bakeev](https://forum.ansible.com/u/Marat_Bakeev)\
**Post date:** [September 14, 2016, 10:04pm UTC](https://forum.ansible.com/t/trouble-with-mount/22535/2 "2016-09-14T22:04:07Z")

</div>

I’m seeing same issues, fix would be nice…
