質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
Ansible

Ansibleは、Python で書かれたサーバーの設定を管理するための 構成管理ツールです。

Python

Pythonは、コードの読みやすさが特徴的なプログラミング言語の1つです。 強い型付け、動的型付けに対応しており、後方互換性がないバージョン2系とバージョン3系が使用されています。 商用製品の開発にも無料で使用でき、OSだけでなく仮想環境にも対応。Unicodeによる文字列操作をサポートしているため、日本語処理も標準で可能です。

Q&A

解決済

1回答

4310閲覧

Ansibleインストール時にエラーが発生し、インストールできない

micci

総合スコア10

Ansible

Ansibleは、Python で書かれたサーバーの設定を管理するための 構成管理ツールです。

Python

Pythonは、コードの読みやすさが特徴的なプログラミング言語の1つです。 強い型付け、動的型付けに対応しており、後方互換性がないバージョン2系とバージョン3系が使用されています。 商用製品の開発にも無料で使用でき、OSだけでなく仮想環境にも対応。Unicodeによる文字列操作をサポートしているため、日本語処理も標準で可能です。

0グッド

1クリップ

投稿2017/02/22 04:06

###前提・実現したいこと
現在、AWSのVyOS上にAnsibleをインストールしようとしております。
Ansibleインストール時にエラーが発生し、インストールできない状況です。
何が原因または、何が足りないなどお教え頂けると助かります。

以下に情報を記載します。

OS:VyOS
Version:VyOS 1.1.7
t2.micro

インストールしたパケージ

bash

1### build-essential 2$ sudo aptitude install build-essential 3Setting up binutils (2.20.1-16) ... 4Setting up libc-dev-bin (2.11.3-4) ... 5Setting up linux-libc-dev (2.6.32-48squeeze6) ... 6Setting up libc6-dev (2.11.3-4) ... 7Setting up libmpfr4 (3.0.0-2) ... 8Setting up cpp-4.4 (4.4.5-8) ... 9Setting up cpp (4:4.4.5-1) ... 10Setting up libgomp1 (4.4.5-8) ... 11Setting up gcc-4.4 (4.4.5-8) ... 12Setting up gcc (4:4.4.5-1) ... 13Setting up make (3.81-8) ... 14Setting up libdpkg-perl (1.15.11) ... 15Setting up bzip2 (1.0.5-6+squeeze1) ... 16Setting up dpkg-dev (1.15.11) ... 17Setting up libstdc++6-4.4-dev (4.4.5-8) ... 18Setting up g++-4.4 (4.4.5-8) ... 19Setting up g++ (4:4.4.5-1) ... 20update-alternatives: using /usr/bin/g++ 21Setting up build-essential (11.5) ... 22 23### libreadline6-dev 24$ sudo aptitude install libreadline6-dev 25Setting up libncurses5-dev (5.7+20100313-5) ... 26Setting up libreadline6-dev (6.1-3) ... 27 28### zlib1g-dev 29sudo aptitude install zlib1g-dev 30Setting up zlib1g-dev (1:1.2.3.4.dfsg-3) ... 31 32### libbz2-dev 33$ sudo aptitude install libbz2-dev 34Setting up libbz2-dev (1.0.5-6+squeeze1) ... 35 36### tk-dev 37$ sudo aptitude install tk-dev 38Setting up libice6 (2:1.0.6-2) ... 39Setting up x11proto-core-dev (7.0.16-1) ... 40Setting up libice-dev (2:1.0.6-2) ... 41Setting up libxau6 (1:1.0.6-1) ... 42Setting up libxdmcp6 (1:1.0.3-2) ... 43Setting up libxcb1 (1.6-1+squeeze1) ... 44Setting up libx11-data (2:1.3.3-4+squeeze1) ... 45Setting up libx11-6 (2:1.3.3-4+squeeze1) ... 46Setting up libxau-dev (1:1.0.6-1) ... 47Setting up libxdmcp-dev (1:1.0.3-2) ... 48Setting up x11proto-input-dev (2.0-2) ... 49Setting up x11proto-kb-dev (1.0.4-1) ... 50Setting up xtrans-dev (1.2.5-1) ... 51Setting up libpthread-stubs0 (0.3-2) ... 52Setting up libpthread-stubs0-dev (0.3-2) ... 53Setting up libxcb1-dev (1.6-1+squeeze1) ... 54Setting up libx11-dev (2:1.3.3-4+squeeze1) ... 55Setting up libsm6 (2:1.1.1-1) ... 56Setting up libsm-dev (2:1.1.1-1) ... 57Setting up libxt6 (1:1.0.7-1+squeeze1) ... 58Setting up libxt-dev (1:1.0.7-1+squeeze1) ... 59Setting up tcl8.4 (8.4.19-4) ... 60update-alternatives: using /usr/bin/tclsh8.4 to provide /usr/bin/tclsh (tclsh) in auto mode. 61Setting up tcl (8.4.16-2) ... 62update-alternatives: using /usr/bin/tclsh-default to provide /usr/bin/tclsh (tclsh) in auto mode. 63Setting up tcl8.4-dev (8.4.19-4) ... 64Setting up tcl-dev (8.4.16-2) ... 65Setting up tk8.4 (8.4.19-4) ... 66update-alternatives: using /usr/bin/wish8.4 to provide /usr/bin/wish (wish) in auto mode. 67Setting up tk (8.4.16-2) ... 68update-alternatives: using /usr/bin/wish-default to provide /usr/bin/wish (wish) in auto mode. 69Setting up tk8.4-dev (8.4.19-4) ... 70Setting up tk-dev (8.4.16-2) ... 71 72### zip 73$ sudo aptitude install zip 74Setting up zip (3.0-3) ... 75 76### libxml2-dev 77$ sudo aptitude install libxml2-dev 78Setting up libxml2 (2.7.8.dfsg-2+squeeze8) ... 79Setting up libxml2-dev (2.7.8.dfsg-2+squeeze8) ... 80 81### libxslt1-dev 82$ sudo aptitude install libxslt1-dev 83Setting up libxslt1-dev (1.1.26-6+squeeze3) ... 84 85### $ sudo aptitude install zlib1g-dev 86 87### python-dev 88$ sudo aptitude install python-dev 89Setting up libssl0.9.8 (0.9.8o-4squeeze14) ... 90Setting up python2.6-minimal (2.6.6-8+b1) ... 91Setting up python2.6 (2.6.6-8+b1) ... 92Setting up libpython2.6 (2.6.6-8+b1) ... 93Setting up libssl-dev (0.9.8o-4squeeze14) ... 94Setting up python2.6-dev (2.6.6-8+b1) ... 95Setting up python-dev (2.6.6-3+squeeze7) ... 96 97### Python 98$ pyenv install 2.7.13 99$ pyenv global 2.7.13 100$ python --version 101Python 2.7.13 102 103### pip 104$ pip --version 105pip 9.0.1 from /home/vyos/.pyenv/versions/2.7.13/lib/python2.7/site-packages (python 2.7)

エラーメッセージ

Ansibleをインストールしようとすると以下エラーが発生し、インストールできない状況です。

bash

1$ pip install ansible 2Collecting ansible 3 Downloading ansible-2.2.1.0.tar.gz (2.5MB) 4 100% ø################################ø 2.5MB 548kB/s 5 6<省略> 7 8 running egg_info 9 writing requirements to src/cryptography.egg-info/requires.txt 10 writing src/cryptography.egg-info/PKG-INFO 11 writing top-level names to src/cryptography.egg-info/top_level.txt 12 writing dependency_links to src/cryptography.egg-info/dependency_links.txt 13 writing entry points to src/cryptography.egg-info/entry_points.txt 14 warning: manifest_maker: standard file '-c' not found 15 16 reading manifest file 'src/cryptography.egg-info/SOURCES.txt' 17 reading manifest template 'MANIFEST.in' 18 no previously-included directories found matching 'docs/_build' 19 warning: no previously-included files matching '*' found under directory 'vectors' 20 writing manifest file 'src/cryptography.egg-info/SOURCES.txt' 21 running build_ext 22 generating cffi module 'build/temp.linux-x86_64-2.7/_padding.c' 23 creating build/temp.linux-x86_64-2.7 24 generating cffi module 'build/temp.linux-x86_64-2.7/_constant_time.c' 25 generating cffi module 'build/temp.linux-x86_64-2.7/_openssl.c' 26 building '_openssl' extension 27 creating build/temp.linux-x86_64-2.7/build 28 creating build/temp.linux-x86_64-2.7/build/temp.linux-x86_64-2.7 29 gcc -pthread -fno-strict-aliasing -g -O2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -I/home/vyos/.pyenv/versions/2.7.13/include/python2.7 -c build/temp.linux-x86_64-2.7/_openssl.c -o build/temp.linux-x86_64-2.7/build/temp.linux-x86_64-2.7/_openssl.o 30 build/temp.linux-x86_64-2.7/_openssl.c:680: error: function definition declared 'typedef' 31 build/temp.linux-x86_64-2.7/_openssl.c:680: warning: return type defaults to 'int' 32 build/temp.linux-x86_64-2.7/_openssl.c: In function 'LHASH_OF': 33 build/temp.linux-x86_64-2.7/_openssl.c:680: error: expected declaration specifiers before 'Cryptography_LHASH_OF_CONF_VALUE' 34 build/temp.linux-x86_64-2.7/_openssl.c:682: error: storage class specified for parameter 'Cryptography_STACK_OF_ACCESS_DESCRIPTION' 35 build/temp.linux-x86_64-2.7/_openssl.c:683: error: storage class specified for parameter 'Cryptography_STACK_OF_DIST_POINT' 36 build/temp.linux-x86_64-2.7/_openssl.c:684: error: storage class specified for parameter 'Cryptography_STACK_OF_POLICYQUALINFO' 37 build/temp.linux-x86_64-2.7/_openssl.c:685: error: storage class specified for parameter 'Cryptography_STACK_OF_POLICYINFO' 38 build/temp.linux-x86_64-2.7/_openssl.c:686: error: storage class specified for parameter 'Cryptography_STACK_OF_ASN1_INTEGER' 39 build/temp.linux-x86_64-2.7/_openssl.c:687: error: storage class specified for parameter 'Cryptography_STACK_OF_GENERAL_SUBTREE' 40 build/temp.linux-x86_64-2.7/_openssl.c:699: error: storage class specified for parameter 'Cryptography_STACK_OF_ASN1_OBJECT' 41 build/temp.linux-x86_64-2.7/_openssl.c:700: error: storage class specified for parameter 'Cryptography_STACK_OF_X509_OBJECT' 42 In file included from build/temp.linux-x86_64-2.7/_openssl.c:711: 43 44<省略> 45 46 build/temp.linux-x86_64-2.7/_openssl.c:72962: error: storage class specified for parameter '_cffi_type_context' 47 build/temp.linux-x86_64-2.7/_openssl.c:72962: error: parameter '_cffi_type_context' is initialized 48 build/temp.linux-x86_64-2.7/_openssl.c:73005: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'æ' token 49 build/temp.linux-x86_64-2.7/_openssl.c:680: error: old-style parameter declarations in prototyped function definition 50 build/temp.linux-x86_64-2.7/_openssl.c:680: error: parameter name omitted 51 build/temp.linux-x86_64-2.7/_openssl.c:73007: error: expected 'æ' at end of input 52 error: command 'gcc' failed with exit status 1 53 54 ---------------------------------------- 55Command "/home/vyos/.pyenv/versions/2.7.13/bin/python2.7 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-FhQ7MS/cryptography/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('ØrØn', 'Øn');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-pPpk9q-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-FhQ7MS/cryptography/

大変お手数お掛けしますが、
よろしくお願いします。

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答1

0

自己解決

すみません。
自己解決できましたので記載します。

不足していたパッケージをインストール

bash

1$ sudo aptitude install libcurl-devel 2$ sudo aptitude install python-pip 3$ sudo -H pip install pyyaml 4$ sudo pip install Jinja2 5 6### upgrade 7$ sudo pip install --upgrade ansible

Ansibleバージョン確認

bash

1$ ansible --version 2ansible 2.2.1.0

お騒がせしました。
ありがとうございました。

投稿2017/02/22 05:03

micci

総合スコア10

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問