> On 08/01/2022 9:04 AM CEST Ashok Reddy <ashokrd...@gmail.com> wrote:
> 
> 
> ---
> - hosts: all
>  become: true
>  become_method: sudo
>  gather_facts: true
>  tasks:
>  - name: rsync
>  ansible.posix.synchronize:
>  src: /root
>  dest: /root
>  delegate_to: hostname
> 
> 
> error:
> 
> 
> TASK [rsync] 
> **********************************************************************************************************************************************************************************************
> fatal: [ FAILED! => {"changed": false, "msg": "Failed to find required 
> executable \"rsync\" in paths: /sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin"}
> fatal: [localhost -> ]: FAILED! => {"changed": false, "msg": "Could not 
> determine controller hostname for rsync to send to"}
> 
> PLAY RECAP 
> ***************************************************************************************************************************************************************

my guess: Ansible detects that the host has no rsync installed, so the TASK can 
not be executed. 
So you'd you have to create a preceeding (package/yum/apt) TASK that makes sure 
rsync is installed on the hosts in order to make this work.

-- 
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-project+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/931614963.59128.1659339453322%40office.mailbox.org.

Reply via email to