# Ansible reporting wrong service status

**URL:** <https://forum.ansible.com/t/ansible-reporting-wrong-service-status/26684>\
**Category:** Ansible Project\
**Created:** [February 8, 2018, 3:26pm UTC](https://forum.ansible.com/t/ansible-reporting-wrong-service-status/26684 "2018-02-08T15:26:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sidh](https://avatars.discourse-cdn.com/v4/letter/s/bbce88/32.png) [@Sidh](https://forum.ansible.com/u/Sidh)\
**Post date:** [February 8, 2018, 3:26pm UTC](https://forum.ansible.com/t/ansible-reporting-wrong-service-status/26684/1 "2018-02-08T15:26:07Z")

</div>

Ansible - 2.4

With below snippet, service failed to start at remote host but ansible reports that lighttpd service has been restarted and ok.

---

<div class="post-metadata">

**Author:** ![Kai\_Stian\_Olstad](https://avatars.discourse-cdn.com/v4/letter/k/e19adc/32.png) [@Kai\_Stian\_Olstad](https://forum.ansible.com/u/Kai_Stian_Olstad)\
**Post date:** [February 8, 2018, 4:48pm UTC](https://forum.ansible.com/t/ansible-reporting-wrong-service-status/26684/2 "2018-02-08T16:48:39Z")

</div>

The init system on the host is reporting OK(return code 0) so Ansible says everything is OK.  
If that's not correct then you need to fix the init file/configuration.

---

<div class="post-metadata">

**Author:** ![Sidh](https://avatars.discourse-cdn.com/v4/letter/s/bbce88/32.png) [@Sidh](https://forum.ansible.com/u/Sidh)\
**Post date:** [February 9, 2018, 1:17pm UTC](https://forum.ansible.com/t/ansible-reporting-wrong-service-status/26684/3 "2018-02-09T13:17:04Z")

</div>

Thanks for your suggestion.

Regards,  
Sidh
