Register for the iXsystems Community to get an ad-free experience

OpenVPN fails in jail with libdl.so.1 not found error

Western Digital Drives - The Preferred Drives of FreeNAS and TrueNAS CORE
Status
Not open for further replies.

laskeyp

Dabbler
Joined
Apr 6, 2017
Messages
21
Newly created FreeNAS 11.1-U6 standard jail. Updated and upgraded everything. Installed OPENVPN from pkg. openvpn fails to execute with error:

Shared object "libdl.so.1" not found, required by "openvpn". All install guides just assume that this will not occur. Cannot determine how to install this object. I have see that this error also affects Python, BASH ans possible others. Can anyone tell me how to get past this deficiency?

Thank you!
 

krazos

Dabbler
Joined
Nov 11, 2017
Messages
15
Same issue here. Can't run Ruby or anything else since it requires libdl.so.1

Temporary solution:

Copied libdl.so and libdl.so.1 from /usr/lib/ in freenas root and pasted into my jails /usr/lib and now I can run Ruby and everything else.
 
Last edited:

endianx

Cadet
Joined
Oct 7, 2018
Messages
1
Experiencing the same issue in a vanilla jail.

pkg install python27-2.7.15

Gets me...
root@sabnzbd:/usr/lib # python2.7
Shared object "libdl.so.1" not found, required by "python2.7"

Looking at ldd...
root@sabnzbd:/usr/lib # ldd /usr/local/bin/python2.7
/usr/local/bin/python2.7:
libthr.so.3 => /lib/libthr.so.3 (0x800821000)
libpython2.7.so.1 => /usr/local/lib/libpython2.7.so.1 (0x800a48000)
libdl.so.1 => not found (0)
libintl.so.8 => /usr/local/lib/libintl.so.8 (0x800e31000)
libutil.so.9 => /lib/libutil.so.9 (0x80103c000)
libm.so.5 => /lib/libm.so.5 (0x80124f000)
libc.so.7 => /lib/libc.so.7 (0x80147a000)
libdl.so.1 => not found (0)


But if I install the sabnzbd plugin from wUI python runs fine in the jail and ldd says:
root@sabnzbd_1:/ # ldd /usr/local/bin/python2.7
/usr/local/bin/python2.7:
libthr.so.3 => /lib/libthr.so.3 (0x800821000)
libpython2.7.so.1 => /usr/local/lib/libpython2.7.so.1 (0x800a48000)
libintl.so.8 => /usr/local/lib/libintl.so.8 (0x800e21000)
libutil.so.9 => /lib/libutil.so.9 (0x80102b000)
libm.so.5 => /lib/libm.so.5 (0x80123e000)
libc.so.7 => /lib/libc.so.7 (0x801469000)


Anyone have any ideas?
 

Scharbag

Guru
Joined
Feb 1, 2012
Messages
571
It looks as though given FreeBSD 11.1 is no longer supported, that the package infrastructure is different and is calling for some scruff that does not yet exist in 11.1. <-- this was edited as the next post points out the difference properly.

Here is where I found some info.

Timing is terrible as I was just trying to revise some scripts to get ready for 11.2... Booo.
 
Last edited:

Kadaki

Cadet
Joined
Dec 23, 2016
Messages
1
According to that bug, libdl is a new library in 11.2 and the packages are failing because they are built linking to it. See also https://reviews.freebsd.org/D11504.

I was able to replicate krazos' fix of copying the libdl files from 11.2 to the jail's /usr/lib (although I used /usr/local/lib). It made python work, at least, but since libdl is essentially an alias for libc's dl* functions, I suspect it should work the same for the other packages.
 

Pancakes

Cadet
Joined
Mar 25, 2018
Messages
2
As a temporary fix, inside your jail

vi /etc/pkg/FreeBSD.conf

and change the url line to read

Code:
  url: "pkg+http://pkg.FreeBSD.org/${ABI}/release_2",


release_2 was frozen at 2018-Jun-05, which is before libdl.so.1 was added.

You will probably need to force reinstall your installed packages to get things back to stable.
 

Scharbag

Guru
Joined
Feb 1, 2012
Messages
571
As a temporary fix, inside your jail

vi /etc/pkg/FreeBSD.conf

and change the url line to read

Code:
  url: "pkg+http://pkg.FreeBSD.org/${ABI}/release_2",


release_2 was frozen at 2018-Jun-05, which is before libdl.so.1 was added.

You will probably need to force reinstall your installed packages to get things back to stable.
No luck with this. I make the change above, reboot the jail and run:
Code:
pkg update -f
pkg upgrade -f

This results in the following again:
Code:
root@Media:/ # python2.7
Shared object "libdl.so.1" not found, required by "python2.7"

Not sure if there is something that I am missing here. Thanks for the help though. Might just have to wait until 11.2 actually gets released.
 
Last edited:

Pancakes

Cadet
Joined
Mar 25, 2018
Messages
2
No luck with this. I make the change above, reboot the jail and run:
Code:
pkg update -f
pkg upgrade -f

This results in the following again:
Code:
root@Media:/ # python2.7
Shared object "libdl.so.1" not found, required by "python2.7"

Not sure if there is something that I am missing here. Thanks for the help though. Might just have to wait until 11.2 actually gets released.

Very odd. Works for me.

Code:
[root@plex /]# pkg update -f

Updating FreeBSD repository catalogue...
[plex] Fetching meta.txz: 100%	944 B   0.9kB/s	00:01	
[plex] Fetching packagesite.txz: 100%	6 MiB   6.4MB/s	00:01	
Processing entries: 100%
FreeBSD repository update completed. 31153 packages processed.
All repositories are up to date.

[root@plex /]# pkg upgrade

Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
Checking for upgrades (0 candidates): 100%
Processing candidates (0 candidates): 100%
Checking integrity... done (0 conflicting)
Your packages are up to date.

[root@plex /]# pkg info python

python-2.7_3,2
Name		   : python
Version		: 2.7_3,2
Installed on   : Sun Oct  7 15:47:44 2018 PDT
Origin		 : lang/python
Architecture   : FreeBSD:11:*
Prefix		 : /usr/local
Categories	 : python lang ipv6
Licenses	   : 
Maintainer	 : python@FreeBSD.org
WWW			: http://www.python.org/
Comment		: "meta-port" for the default version of Python interpreter
Annotations	:
repo_type	  : binary
repository	 : FreeBSD
Flat size	  : 38.0B
Description	:
Python is an interpreted object-oriented programming language, and is
often compared to Tcl, Perl or Scheme.
This is a meta port to the Python interpreter and provides symbolic links
to bin/python, bin/pydoc, bin/idle and so on to allow compatibility with
version agnostic python scripts.

WWW: http://www.python.org/

[root@plex /]# ldd /usr/local/bin/python2.7

/usr/local/bin/python2.7:
libthr.so.3 => /lib/libthr.so.3 (0x800822000)
libpython2.7.so.1 => /usr/local/lib/libpython2.7.so.1 (0x800a4a000)
libintl.so.8 => /usr/local/lib/libintl.so.8 (0x800e29000)
libutil.so.9 => /lib/libutil.so.9 (0x801034000)
libm.so.5 => /lib/libm.so.5 (0x801248000)
libc.so.7 => /lib/libc.so.7 (0x801473000)

[root@plex /]# sha256 /usr/local/bin/python2.7
SHA256 (/usr/local/bin/python2.7) = fe335a3465231075fe2a9bdb5c57dcebe34e8becb6f17b65402aed5694442dce

[root@plex /]# uname -KU
1101505 1101001


You might try

vi /usr/local/etc/pkg.conf

set OSVERSION

Code:
OSVERSION = 1101001


and then retry the forced reinstall... or just sit it out and wait for a fix from upstream :)
 

Locci

Cadet
Joined
Oct 6, 2018
Messages
2
No luck with this. I make the change above, reboot the jail and run:
Code:
pkg update -f
pkg upgrade -f

This results in the following again:
Code:
root@Media:/ # python2.7
Shared object "libdl.so.1" not found, required by "python2.7"

Not sure if there is something that I am missing here. Thanks for the help though. Might just have to wait until 11.2 actually gets released.

Editing /usr/local/etc/pkg/repos/FreeBSD.conf instead made it download the old release for me.
Got openvpn working atleast :)
 

Scharbag

Guru
Joined
Feb 1, 2012
Messages
571
Editing /usr/local/etc/pkg/repos/FreeBSD.conf instead made it download the old release for me.
Got openvpn working atleast :)
Spanks!!
 

XTREEMMAK

Dabbler
Joined
Feb 8, 2016
Messages
31
Ohh my thank you! I'm finally able to continue working on migrating my jails again :)

I did both just to be safe:
First do an install for pkg in the iocage, then

ee /usr/local/etc/pkg.conf

then on first line add
Code:
set OSVERSION = 1101001


then

ee /etc/pkg/FreeBSD.conf
then change quarterly to release aka from this:
Code:
url: "pkg+http://pkg.FreeBSD.org/${ABI}/quarterly",

to this:
Code:
url: "pkg+http://pkg.FreeBSD.org/${ABI}/release_2",


Once all is good hit that good ol,
Code:
pkg update -f
pkg upgrade -f


And you should be good :)
 
Last edited:

PatarNoster

Cadet
Joined
Nov 26, 2015
Messages
9
Same issue here. Can't run Ruby or anything else since it requires libdl.so.1

Temporary solution:

Copied libdl.so and libdl.so.1 from /usr/lib/ in freenas root and pasted into my jails /usr/lib and now I can run Ruby and everything else.

Hey mate, might be a dumb question but how do you get to the freenas root? to get those files?
 

PatarNoster

Cadet
Joined
Nov 26, 2015
Messages
9
Ohh my thank you! I'm finally able to continue working on migrating my jails again :)

I did both just to be safe:
First do an install for pkg in the iocage, then

ee /usr/local/etc/pkg.conf

then on first line add
Code:
set OSVERSION = 1101001


then

ee /etc/pkg/FreeBSD.conf
then change quarterly to release aka from this:
Code:
url: "pkg+http://pkg.FreeBSD.org/${ABI}/quarterly",

to this:
Code:
url: "pkg+http://pkg.FreeBSD.org/${ABI}/release_2",


Once all is good hit that good ol,
Code:
pkg update -f
pkg upgrade -f


And you should be good :)


I have tried this 3 times now, still no go.

could you screen cap how to add the first line?

just not sure what i am missing....gah
 
Status
Not open for further replies.
Top