-
Notifications
You must be signed in to change notification settings - Fork 119
Description
Hi, thanks for setting up this build pack.
I'm not sure if there is a problem or not, though I would log it here.
We're running
Ruby 2.37
Rails 4.2.0
"stack": "heroku-16",
"buildpacks": [
{
"url": "heroku/nodejs"
},
{
"url": "heroku/ruby"
},
{
"url": "https://github.com/.../heroku-buildpack-libjpeg62"
},
{
"url": "https://github.com/.../buildpack-ruby-rake-deploy-tasks"
},
{
"url": "https://github.com/mojodna/heroku-buildpack-jemalloc.git"
}
],
As per docs I added Env Var LD_PRELOAD=/app/vendor/jemalloc/lib/libjemalloc.so.1
But this errored with
Jul 29 09:02:37 ...-app-preprod-pr-5439 app/web.1: ERROR: ld.so: object '=/app/vendor/jemalloc/lib/libjemalloc.so.1' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
If I run these in bash,
~ $ ldd /app/vendor/jemalloc/lib/libjemalloc.so.1
linux-vdso.so.1 => (0x00007ffcc78ba000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f1853734000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f185336a000)
/lib64/ld-linux-x86-64.so.2 (0x00007f1853b91000)
~ $
So then I checked this
~ $ ls /app/vendor/jemalloc/lib
libjemalloc.a libjemalloc_pic.a libjemalloc.so libjemalloc.so.1
~ $
And changed
LD_PRELOAD to /app/vendor/jemalloc/lib/libjemalloc.so
I then pushed a new change and got a build error.
JSON::ParserError: 784: unexpected token at 'ERROR: ld.so: object '/app/vendor/jemalloc/lib/libjemalloc.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
So I removed LD_PRELOAD and used
web: jemalloc.sh bundle exec puma -C config/puma.rb
I can push a change through, but querying ~ $ ruby -r rbconfig -e "puts RbConfig::CONFIG['LIBS']"
Gives me -lpthread -lgmp -ldl -lcrypt -lm
So I don't know if this is what is expected or if it is working properly?
If you could confirm if this is correct, or if there is an error here?
Many thanks!