Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined symbol: lxc_strerror #39

Open
Jafaral opened this issue Sep 26, 2016 · 4 comments
Open

undefined symbol: lxc_strerror #39

Jafaral opened this issue Sep 26, 2016 · 4 comments

Comments

@Jafaral
Copy link
Contributor

Jafaral commented Sep 26, 2016

Hi,

I'm experimenting with this package but I keep getting this error:

$ruby test.rb
/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in require': /var/lib/gems/2.3.0/gems/ruby-lxc-1.2.1/lib/lxc/lxc.so: undefined symbol: lxc_strerror - /var/lib/gems/2.3.0/gems/ruby-lxc-1.2.1/lib/lxc/lxc.so (LoadError) from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:inrequire'
from /var/lib/gems/2.3.0/gems/ruby-lxc-1.2.1/lib/lxc.rb:2:in <top (required)>' from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:127:inrequire'
from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:127:in rescue in require' from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:40:inrequire'
from test.rb:1:in `

'

OUTPUT of nm:
$nm /var/lib/gems/2.3.0/gems/ruby-lxc-1.2.1/lib/lxc/lxc.so | grep lxc_str
U lxc_strerror

obviously it is undefined in lxc.so and it is expected to be defined at runtime. Who is supposed to define it? what am I missing ?

$lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04 LTS
Release: 16.04
Codename: xenial

$ruby --version
ruby 2.3.1p112 (2016-04-26) [arm-linux-gnueabihf]

I also tried on another Ubuntu machine but got the same error above. Same ruby version but it is x86 instead ot arm.

$ruby --version
ruby 2.3.1p112 (2016-04-26) [x86_64-linux-gnu]

Thanks in advanced for any help.

@Jafaral
Copy link
Contributor Author

Jafaral commented Oct 13, 2016

@andrenth Do you have any idea what is causing this?

@Jafaral
Copy link
Contributor Author

Jafaral commented Oct 13, 2016

I see this error message on two ubuntu 16.04 AMD64 desktop machines, but it works on Ubuntu 16.04 armhf after I switched to an ubuntu server from desktop version. The three machines have the same lxc version (2.0.4), same ruby-lxc 1.2.1. The only difference is ruby version. The machine that I don't have problem with is running ruby 2.3.0 while all others are running 2.3.1p112 as I mentioned above.

@Jafaral
Copy link
Contributor Author

Jafaral commented Oct 13, 2016

My work around for now was to just declare a dummy lxc_strerror() function in lxc.so to avoid the undefined symbol issue.

@andrenth
Copy link
Contributor

I've merged your pull request and released version 1.1.2. Sorry for the delay.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants