cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1738
Views
0
Helpful
2
Replies

Something wrong with Python process. dlopen, Symbol not found: _PyIOBase_Type

bfinnema
Cisco Employee
Cisco Employee

When installing NSO 5.3.1.1 on my Mac, and running a service, i get this:

admin@ncs(config-my_test-TEST1)# commit dry-run outformat xml                                      
Aborted: no registration found for callpoint my_test-servicepoint/service_create of type=external

Packages oper-status. Python is not initialized for the my_test package.

admin@ncs# show packages package oper-status
                                                                                                        PACKAGE                
                          PROGRAM                                                                       META     FILE          
                          CODE     JAVA           PYTHON         BAD NCS  PACKAGE  PACKAGE  CIRCULAR    DATA     LOAD   ERROR  
NAME                  UP  ERROR    UNINITIALIZED  UNINITIALIZED  VERSION  NAME     VERSION  DEPENDENCY  ERROR    ERROR  INFO   
-------------------------------------------------------------------------------------------------------------------------------
cisco-ios-cli-6.51    X   -        -              -              -        -        -        -           -        -      -      
cisco-iosxr-cli-7.24  X   -        -              -              -        -        -        -           -        -      -      
my_test               -   -        -              X              -        -        -        -           -        -      -      

Checking the python log:

user@{my-mac} logs % cat ncs-python-vm.log 
<INFO> 15-Apr-2020::09:41:30.833 {my-mac} ncs[8715]: Started PyVM: <<"my_test">> , Port=#Port<0.11339> , OSpid="8807"
<INFO> 15-Apr-2020::09:41:31.089 {my-mac} ncs[8715]: my_test :: Starting python3 -u /Users/user/tail-f/./nso-5.3.1.1/src/ncs/pyapi/ncs_pyvm/startup.py -l info -f ./logs/ncs-python-vm -i my_test
<INFO> 15-Apr-2020::09:41:31.464 {my-mac} ncs[8715]: my_test :: Traceback (most recent call last):
  File "/Users/user/tail-f/./nso-5.3.1.1/src/ncs/pyapi/ncs_pyvm/startup.py", line 6, in <module>
<INFO> 15-Apr-2020::09:41:31.464 {my-mac} ncs[8715]: my_test ::     import ncsctlsock
  File "/Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/ncs_pyvm/ncsctlsock.py", line 5, in <module>
<INFO> 15-Apr-2020::09:41:31.464 {my-mac} ncs[8715]: my_test ::     import _ncs
  File "/Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/_ncs/__init__.py", line 19, in <module>
<INFO> 15-Apr-2020::09:41:31.464 {my-mac} ncs[8715]: my_test ::     from ._ncs_py3 import cdb
ImportError: dlopen(/Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/_ncs/_ncs_py3.abi3.so, 2): Symbol not found: _PyIOBase_Type
  Referenced from: /Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/_ncs/_ncs_py3.abi3.so
  Expected in: flat namespace
 in /Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/_ncs/_ncs_py3.abi3.so
<INFO> 15-Apr-2020::09:41:31.468 {my-mac} ncs[8715]: Got EXIT on Port= #Port<0.11339>
<INFO> 15-Apr-2020::09:41:31.475 {my-mac} ncs[8715]: Restarted PyVM: <<"my_test">> , Port=#Port<0.12897> , OSpid="8816"
<INFO> 15-Apr-2020::09:41:31.482 {my-mac} ncs[8715]: my_test :: Starting python3 -u /Users/user/tail-f/./nso-5.3.1.1/src/ncs/pyapi/ncs_pyvm/startup.py -l info -f ./logs/ncs-python-vm -i my_test
<INFO> 15-Apr-2020::09:41:31.534 {my-mac} ncs[8715]: my_test :: Traceback (most recent call last):
  File "/Users/user/tail-f/./nso-5.3.1.1/src/ncs/pyapi/ncs_pyvm/startup.py", line 6, in <module>
<INFO> 15-Apr-2020::09:41:31.534 {my-mac} ncs[8715]: my_test ::     import ncsctlsock
  File "/Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/ncs_pyvm/ncsctlsock.py", line 5, in <module>
<INFO> 15-Apr-2020::09:41:31.534 {my-mac} ncs[8715]: my_test ::     import _ncs
  File "/Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/_ncs/__init__.py", line 19, in <module>
<INFO> 15-Apr-2020::09:41:31.534 {my-mac} ncs[8715]: my_test ::     from ._ncs_py3 import cdb
ImportError: dlopen(/Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/_ncs/_ncs_py3.abi3.so, 2): Symbol not found: _PyIOBase_Type
  Referenced from: /Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/_ncs/_ncs_py3.abi3.so
  Expected in: flat namespace
 in /Users/user/tail-f/nso-5.3.1.1/src/ncs/pyapi/_ncs/_ncs_py3.abi3.so
<INFO> 15-Apr-2020::09:41:31.538 {my-mac} ncs[8715]: Got EXIT on Port= #Port<0.12897>

What does "Symbol not found: _PyIOBase_Type" mean? How can I fix it?

I have had several versions of NSO running on my Mac(s), but never seen this before.

I recently got a new Mac, and to begin with NSO 5.2.1 was running fine on that new Mac. But now I have this issue with 5.2.1 and 5.3.1.1. Have I messed up the Python installation on my Mac or the $PATH or....?

Python seems good:

# ncs-run % python --version
Python 3.7.3
# ncs-run % python2 --version
Python 2.7.16
# ncs-run % python3 --version
Python 3.7.3

I have Java installed, I have paramiko..What is missing?

2 Replies 2

bfinnema
Cisco Employee
Cisco Employee
Sorry, moved this issue to the NSO Developer Hub. Ignore this. Should be deleted.

shelvadi
Level 1
Level 1

How was this issue resolved ?