Fix missing Asterisk library error ( & not found)

Fix missing Asterisk library error ( & not found)

Installing Asterisk on Debian is described in detail in the post Install Asterisk 20 from source on Debian 12

Here we will discuss how to solve a problem with the libasteriskssl and libasteriskpj libraries that may appear during installation on Debian or other systems.

Spis treści

1) Symptoms of the problem

After compiling Asterisk using the ./configure command with the --libdir=/usr/lib64 parameter, we will encounter problems with starting the Asterisk system at the end of the installation. The system will not be able to find the necessary libraries. This may result in a message similar to the following: error while loading shared libraries: cannot open shared object file: No such file or directory
					ldd /usr/sbin/asterisk
You can see that the operating system cannot find two libraries; libasteriskssl and libasteriskpj. Errors appear: => not found => not found

2) Solution to the problem

Instead of performing the operations described in this post, you can simply compile Asterisk again without specifying the parameter --libdir=/usr/lib64 Just issue the command ./configure
As you can see, the system is trying to find the libraries in the /lib/x86_64-linux-gnu directory. We need to look for where they are actually located.
					find / -name ''
As we could guess, the compiler copied them from the source to the place we indicated, i.e. /usr/lib64 We now need to put them in the right place, i.e. in /lib/x86_64-linux-gnu We will use the ln command to create appropriate symbolic links to these necessary libraries.
					ln -s /usr/lib64/ /lib/x86_64-linux-gnu
ln -s /usr/lib64/ /lib/x86_64-linux-gnu
Now we can run Asterisk without any problems and check its status.
					systemctl start asterisk
systemctl status asterisk
After switching to the asterisk console, we can monitor the operation of the system.
					/usr/sbin/asterisk -rvvv
Problem solved!

If you would like to monitor everything that is happening on your PBX, try our proprietary VOIPERO software.

Setup only takes a few minutes and the system is currently completely FREE.

Read what our VOIPERO system can do in terms of live monitoring and reporting of VoIP systems based on Asterisk.

Share this post

Do you have questions or you need an offer?

Contact us!

Most popular

Related Posts

We Have Launched

Monitoring & Reporting of Your VoIP Server