Ansible Linux Server - Unreachable

41 views
Skip to first unread message

Parveen Datt

unread,
Dec 22, 2019, 2:32:06 AM12/22/19
to Ansible Project
Team,

Can someone please help in solution for below requirement. I tried a lot but did not get through yet


* We want ansible playbook to test network reachability of a server followed by Power reset using IPMITOOL if Server is not reachable on network

Mauricio Tavares

unread,
Dec 22, 2019, 7:40:50 AM12/22/19
to ansible...@googlegroups.com
What have you tried?

> --
> 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 view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/a17fa96f-8cea-467f-b7a2-50a58b2bdea7%40googlegroups.com.

Parveen Datt

unread,
Dec 22, 2019, 2:52:22 PM12/22/19
to Ansible Project
Used ping module to rest network connectivity and ipmi_power to power on the server.

Problem is when server is not reachable on network, registering to ping output fail , hence next play do not start on failed server.

Also tried to used meta: clear_host_errors but no success


On Sunday, December 22, 2019 at 4:40:50 AM UTC-8, Mauricio Tavares wrote:
On Sun, Dec 22, 2019 at 2:32 AM Parveen Datt <prave...@gmail.com> wrote:
>
> Team,
>
> Can someone please help in solution for below requirement. I tried a lot but did not get through yet
>
>
> * We want ansible playbook to test network reachability of a server followed by Power reset using IPMITOOL if Server is not reachable on network
>
      What have you tried?

> --
> 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...@googlegroups.com.

Kai Stian Olstad

unread,
Dec 22, 2019, 2:57:56 PM12/22/19
to ansible...@googlegroups.com
On 22.12.2019 20:52, Parveen Datt wrote:
> Used ping module to rest network connectivity and ipmi_power to power on
> the server.
>
> Problem is when server is not reachable on network, registering to ping
> output fail , hence next play do not start on failed server.
>
> Also tried to used meta: clear_host_errors but no success

The documentation has a page on error handling
https://docs.ansible.com/ansible/latest/user_guide/playbooks_error_handling.html

just set ignore_errors: yes on the task


--
Kai Stian Olstad
Reply all
Reply to author
Forward
0 new messages