How report the unreachable and failure condition.

Hello,

I need to get with a external command the result of execution on a scheduled template, the report must include the hosts where was executed an if the host was unreachable.

How can I do it ?.

Thank you for help.

Best reards.

Flavio Gobber