简体   繁体   中英

Python netmiko failing to install - problem with pynacl

Hope you can help. I am a novice in respect of Ubuntu so apologies in advance.

I am running Ubuntu 16.04 and am trying to install netmiko in python3.5.2

I am hitting a problem with pynacl which is causing the install to fail. The type of error messages I am getting are as follows:

/tmp/pip-install-d4reycz5/pynacl/src/libsodium/src/libsodium/crypto_hash/sha256/cp/hash_sha256_cp.c: In function 'crypto_hash_sha256.constprop': /tmp/pip-install-d4reycz5/pynacl/src/libsodium/src/libsodium/crypto_hash/sha256/cp/hash_sha256_cp.c:205:31: warning: iteration 64 invokes undefined behavior [-Waggressive-loop-optimizations] state->buf[r + i] = in[i]; ^ /tmp/pip-install-d4reycz5/pynacl/src/libsodium/src/libsodium/crypto_hash/sha256/cp/hash_sha256_cp.c:204:9: note: containing loop for (i = 0; i < inlen; i++) { ^

CC       stream2.o
CCLD     stream2

/tmp/pip-install-d4reycz5/pynacl/src/libsodium/src/libsodium/crypto_hash/sha256/cp/hash_sha256_cp.c: In function 'crypto_hash_sha256.constprop': /tmp/pip-install-d4reycz5/pynacl/src/libsodium/src/libsodium/crypto_hash/sha256/cp/hash_sha256_cp.c:205:31: warning: iteration 64 invokes undefined behavior [-Waggressive-loop-optimizations] state->buf[r + i] = in[i]; ^

/tmp/pip-install-d4reycz5/pynacl/src/libsodium/src/libsodium/crypto_hash/sha256/cp/hash_sha256_cp.c:204:9: note: containing loop for (i = 0; i < inlen; i++) { ^

/tmp/pip-install-d4reycz5/pynacl/src/libsodium/build-aux/test-driver: line 107: 19878 Illegal instruction (core dumped) "$@" > $log_file 2>&1

FAIL: box /tmp/pip-install-d4reycz5/pynacl/src/libsodium/build-aux/test-driver: line 107: 19885 Illegal instruction (core dumped) "$@" > $log_file 2>&1

FAIL: box2 /tmp/pip-install-d4reycz5/pynacl/src/libsodium/build-aux/test-driver: line 107: 19892 Illegal instruction (core dumped) "$@" > $log_file 2>&1

FAIL: box7 /tmp/pip-install-d4reycz5/pynacl/src/libsodium/build-aux/test-driver: line 107: 19899 Illegal instruction (core dumped) "$@" > $log_file 2>&1

FAIL: box8 /tmp/pip-install-d4reycz5/pynacl/src/libsodium/build-aux/test-driver: line 107: 19906 Illegal instruction (core dumped) "$@" > $log_file 2>&1

FAIL: box_easy /tmp/pip-install-d4reycz5/pynacl/src/libsodium/build-aux/test-driver: line 107: 19913 Illegal instruction (core dumped) "$@" > $log_file 2>&1

FAIL: box_easy2 /tmp/pip-install-d4reycz5/pynacl/src/libsodium/build-aux/test-driver: line 107: 19920 Illegal instruction (core dumped) "$@" > $log_file 2>&1 FAIL: box_seal

I believe I have all the necessary modules eg libsodium etc. Look forward to hearing from you.

Phil

I think I have found the solution. It appears that Netmiko is only support on Python3.6 and above.

Have installed Python3.8.5 and it appears to be working.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM