close

[Solved] ImportError: libSM.so.6: cannot open shared object file: No such file or directory

Hello Guys, How are you all? Hope You all Are Fine. Today I get the following error ImportError: libSM.so.6: cannot open shared object file: No such file or directory in python. So Here I am Explain to you all the possible solutions here.

Without wasting your time, Let’s start This Article to Solve This Error.

How ImportError: libSM.so.6: cannot open shared object file: No such file or directory Error Occurs?

Today I get the following error ImportError: libSM.so.6: cannot open shared object file: No such file or directory in python.

How To Solve ImportError: libSM.so.6: cannot open shared object file: No such file or directory Error ?

  1. How To Solve ImportError: libSM.so.6: cannot open shared object file: No such file or directory Error ?

    To Solve ImportError: libSM.so.6: cannot open shared object file: No such file or directory Error For CentOS, run this: sudo yum install libXext libSM libXrender

  2. ImportError: libSM.so.6: cannot open shared object file: No such file or directory

    To Solve ImportError: libSM.so.6: cannot open shared object file: No such file or directory Error For CentOS, run this: sudo yum install libXext libSM libXrender

Solution 1

This fixed the problem by having it as the first two lines of the script:

!pip install opencv-python
!apt update && apt install -y libsm6 libxext6
!apt-get install -y libxrender-dev

Solution 2

For CentOS, run this: sudo yum install libXext libSM libXrender

Summery

It’s all About this issue. Hope all solution helped you a lot. Comment below Your thoughts and your queries. Also, Comment below which solution worked for you? Thank You.

Also, Read