You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1820)
at java.lang.Runtime.load0(Runtime.java:810)
at java.lang.System.load(System.java:1086)
at com.uber.h3core.H3CoreLoader.loadNatives(H3CoreLoader.java:125)
at com.uber.h3core.H3CoreLoader.loadNatives(H3CoreLoader.java:89)
at com.uber.h3core.H3Core.newInstance(H3Core.java:73)
at com.sankuai.meituan.banma.rtdw.flink.business.function.BusinessWorkStatusH3ClearRiderRichSinkFunction.open(BusinessWorkStatusH3ClearRiderRichSinkFunction.java:60)
at org.apache.flink.api.common.functions.util.FunctionUtils.openFunction(FunctionUtils.java:34)
at org.apache.flink.streaming.api.operators.AbstractUdfStreamOperator.open(AbstractUdfStreamOperator.java:102)
at org.apache.flink.streaming.api.operators.StreamSink.open(StreamSink.java:46)
at org.apache.flink.streaming.runtime.tasks.OperatorChain.initializeStateAndOpenOperators(OperatorChain.java:466)
at org.apache.flink.streaming.runtime.tasks.StreamTask.lambda$beforeInvoke$2(StreamTask.java:547)
at org.apache.flink.streaming.runtime.tasks.StreamTaskActionExecutor$1.runThrowing(StreamTaskActionExecutor.java:50)
at org.apache.flink.streaming.runtime.tasks.StreamTask.beforeInvoke(StreamTask.java:537)
at org.apache.flink.streaming.runtime.tasks.StreamTask.invoke(StreamTask.java:577)
at org.apache.flink.runtime.taskmanager.Task.doRun(Task.java:767)
at org.apache.flink.runtime.taskmanager.Task.run(Task.java:578)
I had a similar problem using the H3 library in a docker container.
java.lang.UnsatisfiedLinkError: /tmp/libh3-java2646520615962866068.so: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by /tmp/libh3-java2646520615962866068.so)
at java.base/jdk.internal.loader.NativeLibraries.load(Native Method)
at java.base/jdk.internal.loader.NativeLibraries$NativeLibraryImpl.open(NativeLibraries.java:388)
at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:232)
at java.base/jdk.internal.loader.NativeLibraries.loadLibrary(NativeLibraries.java:174)
at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2389)
at java.base/java.lang.Runtime.load0(Runtime.java:755)
at java.base/java.lang.System.load(System.java:1953)
at com.uber.h3core.H3CoreLoader.loadNatives(H3CoreLoader.java:129)
at com.uber.h3core.H3CoreLoader.loadNatives(H3CoreLoader.java:96)
at com.uber.h3core.H3Core.newInstance(H3Core.java:79)
@TRReeve Which version are you using? If you're on 3.x, could you try with the latest 4.0.0-rc4 prerelease version as the GLIBC requirement should be lower? I believe this is a different issue than @ytdxwhy's.
@ytdxwhy Unfortunately it's a little tough to tell from that error what went wrong. My main suspect would be that the shared object file couldn't be written to the temp directory for some reason, or that the file was deleted between being written and being loaded by H3-Java. Is it possible that the application environment is different when resuming than the environment used when starting your application?
I looked into the UnsatisfiedLinkError you were both encountering in Flink and Docker environments. Because distributed workers and containers can aggressively clean up or isolate the default /tmp directory, H3CoreLoader loses track of the extracted native library when the state is restored.
To fix this, I've added an escape hatch: you can now specify a custom, stable extraction directory using the Java system property h3.native.dir (e.g., -Dh3.native.dir=/your/custom/path). If the property isn't provided, it will safely fall back to the default OS temp directory behavior.
I have opened PR #209 with these changes. Let me know if this setup works for your infrastructure!
Activity
TRReeve commentedon Jul 26, 2022
I had a similar problem using the H3 library in a docker container.
isaacbrodsky commentedon Aug 18, 2022
@TRReeve Which version are you using? If you're on 3.x, could you try with the latest 4.0.0-rc4 prerelease version as the GLIBC requirement should be lower? I believe this is a different issue than @ytdxwhy's.
@ytdxwhy Unfortunately it's a little tough to tell from that error what went wrong. My main suspect would be that the shared object file couldn't be written to the temp directory for some reason, or that the file was deleted between being written and being loaded by H3-Java. Is it possible that the application environment is different when resuming than the environment used when starting your application?
dyrpsf commentedon Jun 22, 2026
Hi @ytdxwhy and @TRReeve,
I looked into the
UnsatisfiedLinkErroryou were both encountering in Flink and Docker environments. Because distributed workers and containers can aggressively clean up or isolate the default/tmpdirectory,H3CoreLoaderloses track of the extracted native library when the state is restored.To fix this, I've added an escape hatch: you can now specify a custom, stable extraction directory using the Java system property
h3.native.dir(e.g.,-Dh3.native.dir=/your/custom/path). If the property isn't provided, it will safely fall back to the default OS temp directory behavior.I have opened PR #209 with these changes. Let me know if this setup works for your infrastructure!
Fix uber#97: Allow custom native library directory via h3.native.dir (u…