Forum: JRuby Puma fails to start in production on jRuby 1.7.11

4fdb09782e56e8aa7bd897c92fed450c?d=identicon&s=25 Mate Kaszas (Guest)
on 2014-03-10 07:15
(Received via mailing list)
Hi Guys,

I am trying to deploy a Rails app to my linux (Centos 6) VPS. I am
running jRuby 1.7.11 on it.
The problem is that when I try to start Puma I get this error:

The signal USR1 is in use by the JVM and will not work correctly on this
platform
[deprecated] I18n.enforce_available_locales will default to true in the
future. If you really want to skip validation of your locale you can set
I18n.enforce_available_locales = false to avoid this message.
* Listening on
unix:///home/user/apps/myapp/current/tmp/sockets/myapp.socket
NativeLibrary.java:87:in `loadNativeLibraries':
java.lang.UnsatisfiedLinkError: /lib/libc.so.6: wrong ELF class:
ELFCLASS32
    from NativeLibrary.java:70:in `getNativeLibraries'
    from NativeLibrary.java:49:in `getSymbolAddress'
    from NativeLibrary.java:59:in `findSymbolAddress'
    from AsmLibraryLoader.java:117:in `generateInterfaceImpl'
    from AsmLibraryLoader.java:59:in `loadLibrary'
    from NativeLibraryLoader.java:43:in `loadLibrary'
    from LibraryLoader.java:228:in `load'
    from Library.java:123:in `loadLibrary'
    from Library.java:80:in `loadLibrary'
    from Native.java:40:in `<clinit>'
    from Native.java:60:in `libsocket'
    from Native.java:68:in `socket'
    from UnixServerSocketChannel.java:38:in `<init>'
    from UnixServerSocket.java:29:in `<init>'
    from UnixServerSocketChannel.java:48:in `open'
    from RubyUNIXSocket.java:243:in `init_unixsock'
    from RubyUNIXServer.java:69:in `initialize'
    from RubyUNIXServer$INVOKER$i$1$0$initialize.gen:-1:in `call'
    from JavaMethod.java:971:in `call'
    from JavaMethod.java:677:in `call'
    from CachingCallSite.java:286:in `cacheAndCall'
    from CachingCallSite.java:81:in `callBlock'
    from CachingCallSite.java:85:in `call'
    from RubyClass.java:825:in `newInstance'
    from RubyIO.java:852:in `newInstance'
    from RubyIO$INVOKER$s$0$0$newInstance.gen:-1:in `call'
    from DynamicMethod.java:210:in `call'
    from DynamicMethod.java:206:in `call'
    from CachingCallSite.java:326:in `cacheAndCall'
    from CachingCallSite.java:170:in `call'
    from CallOneArgNode.java:57:in `interpret'
    from LocalAsgnNode.java:123:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from EnsureNode.java:96:in `interpret'
    from BeginNode.java:83:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from ASTInterpreter.java:74:in `INTERPRET_METHOD'
    from InterpretedMethod.java:225:in `call'
    from DefaultMethod.java:214:in `call'
    from CachingCallSite.java:346:in `cacheAndCall'
    from CachingCallSite.java:204:in `call'
    from FCallTwoArgNode.java:38:in `interpret'
    from DAsgnNode.java:110:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from IfNode.java:118:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from WhenOneArgNode.java:36:in `whenSlowTest'
    from WhenOneArgNode.java:46:in `when'
    from CaseNode.java:133:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from ASTInterpreter.java:112:in `INTERPRET_BLOCK'
    from Interpreted19Block.java:206:in `evalBlockBody'
    from Interpreted19Block.java:157:in `yield'
    from Block.java:142:in `yield'
    from RubyArray.java:1606:in `eachCommon'
    from RubyArray.java:1613:in `each'
    from RubyArray$INVOKER$i$0$0$each.gen:-1:in `call'
    from CachingCallSite.java:316:in `cacheAndCall'
    from CachingCallSite.java:145:in `callBlock'
    from CachingCallSite.java:154:in `callIter'
    from CallNoArgBlockNode.java:64:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from ASTInterpreter.java:74:in `INTERPRET_METHOD'
    from InterpretedMethod.java:225:in `call'
    from DefaultMethod.java:214:in `call'
    from CachingCallSite.java:346:in `cacheAndCall'
    from CachingCallSite.java:204:in `call'
    from CallTwoArgNode.java:59:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from ASTInterpreter.java:74:in `INTERPRET_METHOD'
    from InterpretedMethod.java:139:in `call'
    from DefaultMethod.java:182:in `call'
    from CachingCallSite.java:306:in `cacheAndCall'
    from CachingCallSite.java:136:in `call'
    from VCallNode.java:88:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from IfNode.java:116:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from IfNode.java:116:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from ASTInterpreter.java:74:in `INTERPRET_METHOD'
    from InterpretedMethod.java:139:in `call'
    from DefaultMethod.java:182:in `call'
    from CachingCallSite.java:306:in `cacheAndCall'
    from CachingCallSite.java:136:in `call'
    from CallNoArgNode.java:60:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from ASTInterpreter.java:74:in `INTERPRET_METHOD'
    from InterpretedMethod.java:139:in `call'
    from DefaultMethod.java:182:in `call'
    from CachingCallSite.java:306:in `cacheAndCall'
    from CachingCallSite.java:136:in `call'
    from CallNoArgNode.java:60:in `interpret'
    from NewlineNode.java:105:in `interpret'
    from BlockNode.java:71:in `interpret'
    from RootNode.java:129:in `interpret'
    from ASTInterpreter.java:121:in `INTERPRET_ROOT'
    from Ruby.java:838:in `runInterpreter'
    from Ruby.java:2766:in `loadFile'
    from ExternalScript.java:66:in `load'
    from LoadService.java:359:in `load'
    from RubyKernel.java:1109:in `loadCommon'
    from RubyKernel.java:1101:in `load19'
    from RubyKernel$INVOKER$s$0$1$load19.gen:-1:in `call'
    from DynamicMethod.java:210:in `call'
    from DynamicMethod.java:206:in `call'
    from CachingCallSite.java:326:in `cacheAndCall'
    from CachingCallSite.java:170:in `call'
    from bin/puma:16:in `__file__'
    from bin/puma:-1:in `load'
    from Ruby.java:811:in `runScript'
    from Ruby.java:804:in `runScript'
    from Ruby.java:673:in `runNormally'
    from Ruby.java:522:in `runFromMain'
    from Main.java:395:in `doRunFromMain'
    from Main.java:290:in `internalRun'
    from Main.java:217:in `run'
    from Main.java:197:in `main'
! Error starting new process as daemon, exitting

Any idea why this happens? I’ve also tried to use bundle instate
—binstubs and start puma using bin/puma instead of bundle exec, but the
same problem occurs.

Best Wishes,

Matt
F1d37642fdaa1662ff46e4c65731e9ab?d=identicon&s=25 Charles Nutter (headius)
on 2014-03-10 14:31
(Received via mailing list)
Looks like a 32/64-bit mismatch. Could be that our native layer is
loading the wrong libc or you have something odd on that environment
that makes the 32-bit libc get loaded on a 64-bit JVM.

Can you provide a jruby --version and uname -a output please?

- Charlie
4fdb09782e56e8aa7bd897c92fed450c?d=identicon&s=25 Mate Kaszas (Guest)
on 2014-03-11 08:22
(Received via mailing list)
Hi Charlie,

Thanks for the answer. Since then I reinstalled Centos. Now the 32 bit
version, and puma starts with this setup.

I still get the
“The signal USR1 is in use by the JVM and will not work correctly on
this platform “ notifications though. “

I will install the 64 bit version again and tell You the output for
 jruby --version and uname -a

Best Wishes,
Matt
Be 10 Mar 2014 -on 14:29:26, Charles Oliver Nutter (headius@headius.com)
Írt:

Looks like a 32/64-bit mismatch. Could be that our native layer is
loading the wrong libc or you have something odd on that environment
that makes the 32-bit libc get loaded on a 64-bit JVM.

Can you provide a jruby --version and uname -a output please?

- Charlie

On Mon, Mar 10, 2014 at 1:13 AM, Mate Kaszas <mate@bevisible.hu> wrote:
> I18n.enforce_available_locales = false to avoid this message.
> from Library.java:123:in `loadLibrary'
> from JavaMethod.java:971:in `call'
> from CachingCallSite.java:170:in `call'
> from DefaultMethod.java:214:in `call'
> from WhenOneArgNode.java:46:in `when'
> from CachingCallSite.java:316:in `cacheAndCall'
> from CallTwoArgNode.java:59:in `interpret'
> from NewlineNode.java:105:in `interpret'
> from NewlineNode.java:105:in `interpret'
> from ASTInterpreter.java:121:in `INTERPRET_ROOT'
> from CachingCallSite.java:170:in `call'
> ! Error starting new process as daemon, exitting
>
>
> Any idea why this happens? I’ve also tried to use bundle instate —binstubs
> and start puma using bin/puma instead of bundle exec, but the same problem
> occurs.
>
> Best Wishes,
>
> Matt
>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.