ansible *** 作远程主机失败处理记录

ansible *** 作远程主机失败处理记录,第1张

ansible *** 作远程主机失败处理记录 ansible *** 作远程主机失败处理记录

ansible *** 作报错:
Failed to import the required Python library (python-ldap) on terminal-caida’s Python /usr/bin/python. Please read module documentation and install in the appropriate location. If the required library is installed, but Ansible is using the wrong Python interpreter, please consult the documentation on ansible_python_interpreter

原因:
python、pip环境不合适。需修复环境。命令如下

yum update
yum remove python2-pip
yum install python2-pip -y
/usr/bin/pip2 install --upgrade pip setuptools pyOpenSSL psycopg2-binary lxml
python -m pip install --user --upgrade pip==20.2.4
yum install python-devel
#执行这句安装成功
pip install python-ldap

欢迎分享,转载请注明来源:内存溢出

原文地址:https://54852.com/zaji/5495899.html

(0)
打赏 微信扫一扫微信扫一扫 支付宝扫一扫支付宝扫一扫
上一篇 2022-12-12
下一篇2022-12-12

发表评论

登录后才能评论

评论列表(0条)

    保存