Addrinfo not working on alpine linux #4408

Paxa opened this Issue Dec 23, 2016 · 1 comment


None yet

2 participants

Paxa commented Dec 23, 2016

Error caused by

private Protocol protocol = Protocol.getProtocolByNumber(0);

Because getprotobyname_r not exists in musl lib.

Stack trace:

Dec 23, 2016 5:56:19 AM jnr.netdb.NativeProtocolsDB load
WARNING: Failed to load native protocols db
java.lang.UnsatisfiedLinkError: unknown
	at jnr.ffi.provider.jffi.AsmRuntime.newUnsatisifiedLinkError(
	at jnr.netdb.NativeProtocolsDB$LinuxLibProto$jnr$ffi$2.getprotobyname_r(Unknown Source)
	at jnr.netdb.NativeProtocolsDB$LinuxNativeProtocolsDB.getProtocolByName(
	at jnr.netdb.NativeProtocolsDB.load(
	at jnr.netdb.NativeProtocolsDB.access$000(
	at jnr.netdb.NativeProtocolsDB$SingletonHolder.<clinit>(
	at jnr.netdb.NativeProtocolsDB.getInstance(
	at jnr.netdb.Protocol$ProtocolDBSingletonHolder.load(
	at jnr.netdb.Protocol$ProtocolDBSingletonHolder.<clinit>(
	at jnr.netdb.Protocol.getProtocolDB(
	at jnr.netdb.Protocol.getProtocolByNumber(
	at org.jruby.ext.socket.Addrinfo.<init>(
	at org.jruby.ext.socket.SocketUtils$2.addrinfo(
	at org.jruby.ext.socket.SocketUtils.buildAddrinfoList(
	at org.jruby.ext.socket.SocketUtils.getaddrinfoList(
	at org.jruby.ext.socket.Addrinfo.getaddrinfo(
	at org.jruby.ext.socket.Addrinfo$INVOKER$s$0$0$$INVOKER$s$0$0$getaddrinfo.gen)
	at org.jruby.internal.runtime.methods.JavaMethod$
@Paxa Paxa referenced this issue in jnr/jnr-netdb Dec 23, 2016

Fails on alpine linux #4

headius commented Jan 5, 2017

This is a jnr-netdb fix. We'll leave this open until we upgrade to a fixed version.

@headius headius added core ffi labels Jan 5, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment