Wednesday, December 14, 2011

Cassandra OpsCenter,Failed to load application: libpython2.6.so.1.0

Unzip the OpsCenter file, Instal the 2.7 Python, then run the opscenter, failed get the following error.

[root@e3 opscenter]# bin/opscenter
/usr/local/bin/python2.7
Traceback (most recent call last):
File "/usr/lib/cassandra/opscenter-1.3.1/lib/py-redhat/2.6/shared/amd64/twisted/application/app.py", line 631, in run
runApp(config)
File "/usr/lib/cassandra/opscenter-1.3.1/lib/py-redhat/2.6/shared/amd64/twisted/scripts/twistd.py", line 23, in runApp
_SomeApplicationRunner(config).run()
File "/usr/lib/cassandra/opscenter-1.3.1/lib/py-redhat/2.6/shared/amd64/twisted/application/app.py", line 374, in run
self.application = self.createOrGetApplication()
File "/usr/lib/cassandra/opscenter-1.3.1/lib/py-redhat/2.6/shared/amd64/twisted/application/app.py", line 439, in createOrGetApplication
application = getApplication(self.config, passphrase)
--- <exception caught here> ---
File "/usr/lib/cassandra/opscenter-1.3.1/lib/py-redhat/2.6/shared/amd64/twisted/application/app.py", line 450, in getApplication
application = service.loadApplication(filename, style, passphrase)
File "/usr/lib/cassandra/opscenter-1.3.1/lib/py-redhat/2.6/shared/amd64/twisted/application/service.py", line 400, in loadApplication
application = sob.loadValueFromFile(filename, 'application', passphrase)
File "/usr/lib/cassandra/opscenter-1.3.1/lib/py-redhat/2.6/shared/amd64/twisted/persisted/sob.py", line 210, in loadValueFromFile
exec fileObj in d, d
File "bin/start_opscenter.py", line 1, in <module>
from opscenterd import opscenterd_tap
File "build/lib/python2.7/site-packages/opscenterd/opscenterd_tap.py", line 16, in <module>

File "build/lib/python2.7/site-packages/opscenterd/Config.py", line 392, in init_config

File "build/lib/python2.7/site-packages/opscenterd/events/plugins/CassandraStore.py", line 12, in <module>

File "build/lib/python2.7/site-packages/opscenterd/CassandraService.py", line 17, in <module>

File "build/lib/python2.7/site-packages/opscenterd/Cluster.py", line 14, in <module>

File "build/lib/python2.7/site-packages/opscenterd/AgentServer.py", line 23, in <module>

File "build/lib/python2.7/site-packages/opscenterd/HttpUtils.py", line 10, in <module>

File "/usr/lib/cassandra/opscenter-1.3.1/lib/py-redhat/2.6/5/amd64/OpenSSL/__init__.py", line 11, in <module>
import rand, crypto, SSL, tsafe
exceptions.ImportError: libpython2.6.so.1.0: cannot open shared object file: No such file or directory

Failed to load application: libpython2.6.so.1.0: cannot open shared object file: No such file or directory


When I list the LibPython module under /usr/lib64/libpython* , It only has the 2.4 modue. So we need to install the 2.6 Module required by the opscenter.

1, first, Check my OS, it ‘s Centos 5

image

go to http://download.fedora.redhat.com/pub/epel/5/x86_64/, download the epel-release-5-4.noarch.rpm 

2. Update the rpm, “rpm -Uvh epel-release*rpm”

3. yum install python26-libs

image

Once done, you can see the 2.6 modules under the lib folder,
image

Now we can run the opscenter now.

No comments:

 
Locations of visitors to this page