Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Tip

请在使用站内资源的同时不要恶意进行爬取或倒链等行为,感谢支持!

Note

UI Button
colorblue
newWindowtrue
sizesmall
displayblock
iconlink
title链接

Info
iconfalse

Table of Contents

Ansible 错误总汇

Ansible Playbook

执行时出现如下错误:

Code Block
languagebash
TASK [downloads-ssh-key : Copy SSH Private Key] ****************************************************************************************************************************************************************************************************************************
task path: /Users/shilei/Documents/github/Ansible-Kubernetes/roles/downloads-ssh-key/tasks/main.yml:2
fatal: [10.30.0.40]: FAILED! => {"msg": "Failed to get information on remote file (/tmp/.shilei-id_rsa): Shared connection to 10.30.0.40 closed.\r\n"}
...

说明没有安装 python。安装 python 即可解决问题。

Code Block
languagebash
TASK [kubernetes-default : Create Kubernetes API Server Certificate Files] *******************************************************************************************************************************************************************
task path: /Users/shilei/Documents/github/Ansible-Kubernetes/roles/kubernetes-default/tasks/main.yml:29
fatal: [10.30.0.40]: FAILED! => {"msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute 'address'\n\nThe error appears to have been in '/Users/shilei/Documents/github/Ansible-Kubernetes/roles/kubernetes-default/tasks/main.yml': line 29, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n\n- name: Create Kubernetes API Server Certificate Files\n  ^ here\n"}
	to retry, use: --limit @/Users/shilei/Documents/github/Ansible-Kubernetes/main.retry
...

如果出现如上种情况,通常使用的是 Ansible 自己获取的变量中的相关变量被人为修改了,比如修改了网卡的信息,造成了 ansible 并没有及时的重新更新信息造成的无法获取变量而产生的错误。

文档创建于 最后一次更新于  , 文档当前的状态 

Status
colourGreen
title正式版
 , 当前编写页面的版本 
Status
colourBlue
titlev1.3.1
 。