ansible代码下载地址:
http://releases.ansible.com/ansible/

# git clone git://github.com/ansible/ansible.git --recursive
# cd ./ansile
# source ./hacking/env-setup
# vi /etc/profile
# source /etc/profile

# easy_install pycrypto-2.6.1.tar.gz
# yum install gcc
        Q:    src/hash_template.c:361: warning: implicit declaration of function ‘Py_FatalError’
        A:    yum install python-devel
       
       
        Q:    src/hash_template.c:361: warning: implicit declaration of function ‘Py_FatalError’
            c/_cffi_backend.c:6728: error: ‘FFI_DEFAULT_ABI’ undeclared (first use in this function)
            error: Setup script exited with error: command 'gcc' failed with exit status 1
        A:  yum install libffi-devel
            yum install openssl
            yum install openssl-devel
       
# python setup.py install
Using /usr/lib64/python2.6/site-packages
Finished processing dependencies for ansible==2.2.0
# ansible test -m ping
        Q:  DeprecationWarning
        ERROR! Unexpected Exception: 'module' object has no attribute 'HAVE_DECL_MPZ_POWM_SEC'
        the full traceback was:
        A:    wget https://pypi.python.org/packages/source/p/pip/pip-1.5.4.tar.gz --no-check-certificate
            mv pip-1.5.4.tar.gz /usr/local/src/
            cd /usr/local/src/
            tar -zxvf pip-1.5.4.tar.gz
            cd pip-1.5.4
            python setup.py install
            pip install pycrypto-on-pypi

Q:  /usr/lib/python2.6/site-packages/cryptography-1.4-py2.6-linux-x86_64.egg/cryptography/__init__.py:26: DeprecationWarning: Python 2.6 is no longer supported by the Python core team, please upgrade your Python. A future version of cryptography will drop support for Python 2.6  DeprecationWarning
        An exception occurred during task execution. To see the full traceback, use -vvv. The error was: AttributeError: 'EntryPoint' object has no attribute 'resolve'
        A:    下载安装python2.7
            http://www.Python.org/ftp/python/
            mkdir /usr/local/python27
            tar xvf Python-2.7.tar.bz2
            cd Python-2.7
            ls
            ./configure --prefix=/usr/local/python27/
           
            mv /usr/bin/python /usr/bin/python2.6-0720
            make
            make install
            make clean 
            make distclean
           
            ln -s /usr/local/python27/bin/python /usr/bin/python
            vi /usr/bin/yum
                #!/usr/bin/python2.6
               
        Q:     Traceback (most recent call last):
            File "/usr/bin/ansible", line 4, in <module>
            import pkg_resources
            ImportError: No module named pkg_resources
        A:   
            cd python2.7/
            cd site
            cd site-packages/
            python get_pip.py
            ansible local -m ping
            pip install pycrypto
            pip install jinja2
            pip install paramiko
            pip install httplib2
            pip install six
            cd /usr/local/
            cd ansible/
            rm -rf *
            cd /usr/local/src/
            git clone git://github.com/ansible/ansible.git --recursive
            cp -a ansible/ /usr/local/
            rm -rf /usr/local/ansible/
            cp -ar ansible/ /usr/local/
            cd /usr/local/ansible/
            source ./hacking/env-setup
            python setup.py install
            ansible local -m ping
            Q:    ERROR!Specified hosts and/or --limit does not match any hosts
            cd /etc/
            cd ansible
            vim hosts
            [local]
            192.168.196.128      
            ansible local -m ping
            vi /etc/ansible/ansible.cfg
                参阅生产配置       
        Q:
            /usr/local/python27b/python2.7/site-packages/Crypto/Util/number.py:57: PowmInsecureWarning: Not using mpz_powm_sec.  You should rebuild using libgmp >= 5 to avoid timing attack vulnerability._warn("Not using mpz_powm_sec.  You should rebuild using libgmp >= 5 to avoid timing attack vulnerability.", PowmInsecureWarning)
        A:    tar -xvf gmp-5.0.4.tar.bz2
            cd gmp-5.0.4
            ls
            ./configure
            make
            make check
            make install       
            pip install --ignore-installed PyCrypto

[root@vhost02 src]# ansible local -m ping
192.168.196.128 | SUCCESS => {
"changed": false,
"ping": "pong"
}
[root@vhost02 src]#

ansible 2.2的源码编译安装的更多相关文章

  1. SSH/SSL 源码编译安装简易操作说明

    环境:CentOS 6.7 安全加固需求,由于某盟扫描系统主机有SSL系列漏洞,客户要求必须修复: 解决方案:将SSH/SSL升级到最新版本,删除SSL旧版本(实测不删除旧版本某盟扫描无法通过). 当 ...

  2. 源码编译安装 MySQL 5.5.x 实践

    1.安装cmakeMySQL从5.5版本开始,通过./configure进行编译配置方式已经被取消,取而代之的是cmake工具.因此,我们首先要在系统中源码编译安装cmake工具. # wget ht ...

  3. 烂泥:mysql5.5数据库cmake源码编译安装

    本文由秀依林枫提供友情赞助,首发于烂泥行天下. 以前也写过一篇有关mysql5.0源码编译的文章,该文章为<烂泥:mysql5.0数据库源码编译安装>.但是MySQL自5.5版本以后,就开 ...

  4. Centos7.X 源码编译安装subversion svn1.8.x

    说明:SVN(subversion)的运行方式有两种:一种是基于Apache的http.https网页访问形式:还有一种是基于svnserve的独立服务器模式.SVN的数据存储方式也有两种:一种是在B ...

  5. centos6.5环境源码编译安装mysql5.6.34

    centos6.5环境源码编译安装mysql5.6.34 源码下载地址http://dev.mysql.com/downloads/mysql/5.6.html#downloads 选择Generic ...

  6. centos 6.5源码编译安装subversion 1.8.10

    一.简介 CentOS 6.5的yum源可以安装的SVN客户端版本太低了,1.6.11,所以需要升级到1.8.10,而官网有没有找到1.8.10的安装包,只能选择源码编译安装. 二.安装步骤 参考官网 ...

  7. Linux环境PostgreSQL源码编译安装

    Linux环境PostgreSQL源码编译安装 Linux版本: Red Hat 6.4 PostgreSQL版本: postgresql-9.3.2.tar.gz 数据存放目录: /var/post ...

  8. 总结源码编译安装mysql

    最近在学习源码编译安装LAMP.LNMP时,一直遇到一个难题,就是就是mysql无论怎么源码编译安装,到最后启动服务都提示"Starting MySQL.The server quit wi ...

  9. Linux下源码编译安装rpy2

    R(又称R语言)是一款开源的跨平台的数值统计和数值图形化展现工具.rpy2是Python直接调用R的第三方库,它可以实现使用python读取R的对象.调用R的方法以及Python与R数据结构转换等.这 ...

随机推荐

  1. elastic search 配置问题

    http://www.elastic.co/guide/en/elasticsearch/guide/current/hardware.html 此处有关于ES硬件规格的建议和各种推荐参数. 内存: ...

  2. OFBIZ:启动之StartupLoader

    任意一个JAVA程序都是从main()开始启动的,OFBIZ也不例外.OFBIZ的main()位于framework/start/src/org/ofbiz/base/start/Start.java ...

  3. AX 2012 query应用collections

    QueryBuildRange range; super(); this.query().dataSourceName('VendTop10VendorsByPurchase').clearDynal ...

  4. 54. Search a 2D Matrix && Climbing Stairs (Easy)

    Search a 2D Matrix Write an efficient algorithm that searches for a value in an m x n matrix. This m ...

  5. PL/SQL连接64位Oracle配置方法

    问题原因: plsql developer无法连接64位oracle server的原因是,plsql是32位的,没有64位的版本,而oracle是64位,两者不兼容. 配置方法: 1.下载64位Or ...

  6. Ms sql 2000互转2005

    BCP导入导出数据.非常的方便.速度很快.--还原部分,指定强制还原(使用WITH MOVE指定文件还原,RELPACE由于版本不一样,所以要指定REPLACE,如果不指定REPLACE参数,会提示版 ...

  7. mvc多个按钮的提交方法

    转载地址:http://www.cnblogs.com/wuchang/archive/2010/01/29/1658916.html 有时候会遇到这种情况:在一个表单上需要多个按钮来完成不同的功能, ...

  8. 30. PL/SQL Developer连接服务器查询时,数据乱码处理

    在windows中创 建一个名为“NLS_LANG”的系统环境变量,设置其值为"AMERICAN_AMERICA.ZHS16GBK",   NLS_LANG的值为:select u ...

  9. pgadmin中的备份功能消失的原因和找回方法

    pgadmin在正常情况下,在左侧的[对象浏览器]中选中数据库.模式或者表时,右键会出现[备份]和[恢复]的选项(除早期不支持该功能的版本外). 如: 当然,有时候有人会发现,当你想要用这些备份还原功 ...

  10. Egret版本更新(H5增加版本号)

    由于浏览器缓存问题.在服务器上更新了新的图片等资源以后,客户端并不会下载最新的. 关于浏览器缓存机制,可自行百度. Egret中资源更新解决方案有以下: 一 资源名后增加版本号 二 重写Egret引擎 ...