Issue with unmount of volume

10 views
Skip to first unread message

Karthick Thanigaimani

unread,
Mar 12, 2019, 2:19:05 AM3/12/19
to Ansible Project
Hi,

I have my facts as like below to unmount a file system in my EC2 via ansible. the ansible playbook executes fine without any issues but still file system doesnt get unmounted (eventhough not in use or no errors). The actual commands to manually unmount a volume works fine though.

Any pointers would be of great help.


- set_fact:
    device: /dev/xvdb
  when: nvmedev.stat.exists == False

- name: Unmount device
  mount:
    name: "{{ item }}"
    src: none
    fstype: none
    state: unmounted
  with_items:
    - /dev/xvdb1

- name: Unmount
  mount:
    path: /dev/nvme1n1
    state: absent

Regards
Karthick

Suhail Choudhury

unread,
Mar 14, 2019, 8:50:54 AM3/14/19
to ansible...@googlegroups.com
Hi,

/dev/xvdb and /dev/nvme1n1 are both devices.

You probably need to specify the path which these devices are mounted on?

Regards,
Suhail.
> --
> You received this message because you are subscribed to the Google Groups "Ansible Project" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to ansible-proje...@googlegroups.com.
> To post to this group, send email to ansible...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/1077839576.767724.1552371526090%40mail.yahoo.com.
> For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages