源码安装saltstack的时候遇到的问题
公司的系统都是内网,无法连接互联网,所以没办法只有源码安装了。
看了下saltstack的官网,需要安装的包有
https://docs.saltstack.com/en/latest/topics/installation/index.html
DEPENDENCIES
Salt should run on any Unix-like platform so long as the dependencies are met.
- Python 2.6 >= 2.6 <3.0
- msgpack-python - High-performance message interchange format
- YAML - Python YAML bindings
- Jinja2 - parsing Salt States (configurable in the master settings)
- MarkupSafe - Implements a XML/HTML/XHTML Markup safe string for Python
- apache-libcloud - Python lib for interacting with many of the popular cloud service providers using a unified API
- Requests - HTTP library
Depending on the chosen Salt transport, ZeroMQ or RAET, dependencies vary:
- ZeroMQ:
- RAET:
Salt defaults to the ZeroMQ transport, and the choice can be made at install time, for example:
python setup.py --salt-transport=raet install 一般都使用zeromq,其余的包安装都很顺利,没遇到什么问题,安装zeroMQ的时候遇到不少问题,查了好多资料,这里记录下,免得以后又忘记了
1. 安装pyzmq的时候报错
python setup.py install
最后报错
gcc: error trying to exec 'cc1plus': execvp: 没有那个文件或目录
error: command 'gcc' failed with exit status 1
查询很多网址后发现说明是gcc和g++版本不一致导致的问题,一查,发现操作系统根本就没安装g++,安装个g++后重新安装正常
2. 安装M2Crypto时报错
building 'M2Crypto.__m2crypto' extension
swigging SWIG/_m2crypto.i to SWIG/_m2crypto_wrap.c
swig -python -I/usr/include/python2.7 -I/usr/include -I/usr/include/openssl -includeall -modern -o SWIG/_m2crypto_wrap.c SWIG/_m2crypto.i
unable to execute swig: No such file or directory
error: command 'swig' failed with exit status 1
发现安装m2crypto需要用到swig,而本机上没有安装swig,所以报错,就需要安装swig,此处又给后面挖了一个坑
在swig的主页上下载了最新版的swig 3.0.7
安装完swig后继续安装M2Crypto,继续报错
Running setup.py install for M2Crypto
building 'M2Crypto.__m2crypto' extension
swigging SWIG/_m2crypto.i to SWIG/_m2crypto_wrap.c
swig -python -I/usr/include/python2.6 -I/usr/include -includeall -o SWIG/_m2crypto_wrap.c SWIG/_m2crypto.i
/usr/include/openssl/opensslconf.h:31: Error: CPP #error ""This openssl-devel package does not work your architecture?"". Use the -cpperraswarn option to continue swig processing.
error: command 'swig' failed with exit status 1
根据这个报错提示结合搜索到的结果,在M2Crypto目录的setup.py中加上一句
self.swig_opts.append('-cpperraswarn')
重新安装没有报错
其余的包安装都很顺利,没有报错
本以为安装好了,执行salt-master,这次没有报什么什么库找不到了,又报了一个新的错误
[ERROR ] 'module' object has no attribute 'PKCS5_SALT_LEN'
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/salt/utils/parsers.py", line 155, in parse_args
process_option_func()
File "/usr/lib/python2.7/site-packages/salt/utils/parsers.py", line 435, in process_config_dir
self.config.update(self.setup_config())
File "/usr/lib/python2.7/site-packages/salt/utils/parsers.py", line 1411, in setup_config
return config.master_config(self.get_config_file_path())
File "/usr/lib/python2.7/site-packages/salt/config.py", line 2052, in master_config
opts = apply_master_config(overrides, defaults)
File "/usr/lib/python2.7/site-packages/salt/config.py", line 2069, in apply_master_config
import salt.crypt
File "/usr/lib/python2.7/site-packages/salt/crypt.py", line 21, in <module>
from M2Crypto import RSA, EVP
File "build/bdist.linux-x86_64/egg/M2Crypto/__init__.py", line 24, in <module>
File "build/bdist.linux-x86_64/egg/M2Crypto/ASN1.py", line 12, in <module>
File "build/bdist.linux-x86_64/egg/M2Crypto/BIO.py", line 221, in <module>
File "build/bdist.linux-x86_64/egg/M2Crypto/BIO.py", line 227, in CipherStream
AttributeError: 'module' object has no attribute 'PKCS5_SALT_LEN'
又只有继续搜索,找了很长时间才发现说是swig新版本的一个bug,回退到3.0.4即可解决该问题,又重新下载swig 3.0.4安装,再重新安装M2Crypto,saltstack终于安装完成,源码安装真是痛苦,好在现在都是虚拟机,安装好一个制作好模板,以后使用就不成问题了。
欢迎交流salt-stack的各种问题
源码安装saltstack的时候遇到的问题的更多相关文章
- saltstack源码安装
环境 centos6.3,python2.7.5. 1.install libzmq-master $ git clone git://github.com/zeromq/libzmq.git $ c ...
- mono-3.4.0 源码安装时出现的问题 [do-install] Error 2 [install-pcl-targets] Error 1 解决方法
Mono 3.4修复了很多bug,继续加强稳定性和性能(其实Mono 3.2.8 已经很稳定,性能也很好了),但是从http://download.mono-project.com/sources/m ...
- 搭建LNAMP环境(七)- PHP7源码安装Memcached和Memcache拓展
上一篇:搭建LNAMP环境(六)- PHP7源码安装MongoDB和MongoDB拓展 一.安装Memcached 1.yum安装libevent事件触发管理器 yum -y install libe ...
- 搭建LNAMP环境(二)- 源码安装Nginx1.10
上一篇:搭建LNAMP环境(一)- 源码安装MySQL5.6 1.yum安装编译nginx需要的包 yum -y install pcre pcre-devel zlib zlib-devel ope ...
- 搭建LNAMP环境(一)- 源码安装MySQL5.6
1.yum安装编译mysql需要的包 yum -y install gcc-c++ make cmake bison-devel ncurses-devel perl 2.为mysql创建一个新的用户 ...
- Greenplum 源码安装教程 —— 以 CentOS 平台为例
Greenplum 源码安装教程 作者:Arthur_Qin 禾众 Greenplum 主体以及orca ( 新一代优化器 ) 的代码以可以从 Github 上下载.如果不打算查看代码,想下载编译好的 ...
- salt源码安装软件和yum安装软件
上面简单列出了源码安装的sls文件书写思路. 涉及到一些固定的思路:如, 1,拷贝 解压安装时候需要依赖tar.gz存在 如果已安装则无需再次安装. 2,启动脚本 加入chk时候需要文件存在,如果已添 ...
- 搭建LNAMP环境(六)- PHP7源码安装MongoDB和MongoDB拓展
上一篇:搭建LNAMP环境(五)- PHP7源码安装Redis和Redis拓展 一.安装MongoDB 1.创建mongodb用户组和用户 groupadd mongodb useradd -r -g ...
- 搭建LNAMP环境(三)- 源码安装Apache2.4
上一篇:搭建LNAMP环境(二)- 源码安装Nginx1.10 1.yum安装编译apache需要的包(如果已经安装,可跳过此步骤) yum -y install pcre pcre-devel zl ...
随机推荐
- Directx11学习笔记【七】 游戏定时器的实现
无论是在动画还是在一些游戏中,定时器总是必不可少的,游戏的帧数动画的播放等都离不开定时器的控制.这里以dx11龙书中提供的定时器为例,具体看看是怎么实现一个简单但精度高使用方便的定时器的. 这个定时器 ...
- Java SE学习之数组——匿名数组和不规则数组
本文是学习网络上的文章时的总结以及自己的一点实践.感谢大家无私的分享. 近期偶然遇到了数组的问题,学习了匿名数组和不规则数组. 匿名数组适用于仅仅使用一次的情况:不规则数组适用是每行数据总数不确定的情 ...
- POJ9384 迷宫(基金会BFS)
本文来源于:http://blog.csdn.net/svitter 称号:让你从(0, 0)走到(4,4).而且输出路径. 输入数据:二位数组的迷宫:输出数据:路径: 题解:简单的BFS 注意: 1 ...
- C#启动进程之Process
在程序设计中,我们经常会遇到要从当前的程序跳到另一个程序的设计需求.也就是当前进程创建另一个进程.C#提供了Process使得我们很方便的实现. 1.Process基本属性和方法 Id //进程的Id ...
- SQLSERVER存储过程语法的具体解释
SQL SERVER存储过程语法: Create PROC [ EDURE ] procedure_name [ ; number ] [ { @parameter data_type } ...
- Java String 类的 equals 和 ==
public class Test_String { public static void main(String[] args) { String a = new String("aa&q ...
- 阿里2015在线研发project师笔试题(部分)
今天lz去阿里的在线笔试打了一把酱油,因为lz的水平有限,时间太他么紧张了.以下把记下来的题给大家分享一下.选择题总共20道,前十题截了图,后面感觉太费时就没有再截了,凭记忆记下了两道.附加题都记录下 ...
- 如何使用 iOS 7 的 AVSpeechSynthesizer 国家有声读物(4)
控制:我们一定要学会控制 尤达大师(电影<星球大战>)有话:的关键在于控制.这本故事书是一个字一个字读出来,我愿意为它添加两个button,音调和语速,以便我们能够调整语音合成实时的时候. ...
- 2015西雅图微软总部MVP峰会
2015 西雅图微软总部MVP峰会记录 2015 西雅图微软总部MVP峰会记录 今年决定参加微软MVP全球峰会,在出发之前本人就已经写这篇博客,希望将本次会议原汁原味奉献给大家 因为这次是本人第一 ...
- Android开发学习总结——Android开发的一些相关概念(转)
一.什么是3G.4G 1995年问世的第一代模拟制式手机(1G)只能进行语音通话. 1996到1997年出现的第二代GSM.CDMA等数字制式手机(2G)便增加了接收数据的功能 3G指的是第三代移 ...