错误的信息为: AILED! => {"msg": "to use the 'ssh' connection type with passwords or pkcs11_provider, you must install the sshpass program"} 问题和原因 这是在运行 ansible 的服务器需要安装 sshpass 组件。 可以直接运行: [root@devops ~]# dnf install sshpass 来进行安装。 如上图所示,就可以解决 ansible 安装提示的错误。 https://www.isharkfly.com/t/ansible-sshpass/15644