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

[Bug] Mac m1: JNA UnsatisfiedLinkError #2012

Closed
1 task done
javeme opened this issue Nov 8, 2022 · 1 comment · Fixed by #2013
Closed
1 task done

[Bug] Mac m1: JNA UnsatisfiedLinkError #2012

javeme opened this issue Nov 8, 2022 · 1 comment · Fixed by #2013
Labels
bug Something isn't working

Comments

@javeme
Copy link
Contributor

javeme commented Nov 8, 2022

Bug Type (问题类型)

server status (启动/运行异常)

Before submit

  • 我已经确认现有的 IssuesFAQ 中没有相同 / 重复问题

Environment (环境信息)

  • Server Version: v0.11.x
  • Backend: RocksDB x nodes, HDD or SSD
  • OS: xx CPUs, xx G RAM, Centos 7.x
  • Data Size: xx vertices, xx edges

Expected & Actual behavior (期望与实际表现)

Error when start hg with l2 cache enabled on mac m1:

2022-11-09 00:49:47 [task-db-worker-1] [INFO] o.c.o.l.Uns - OHC using JNA OS native malloc/free
Exception in thread "main" com.baidu.hugegraph.HugeException: Failed to update/query TaskStore: java.util.concurrent.ExecutionException: java.lang.UnsatisfiedLinkError: /Users/user/Library/Caches/JNA/temp/jna3881036102895889031.tmp: dlopen(/Users/user/Library/Caches/JNA/temp/jna3881036102895889031.tmp, 0x0001): tried: '/Users/user/Library/Caches/JNA/temp/jna3881036102895889031.tmp' (fat file, but missing compatible architecture (have (i386,x86_64), need (arm64e)))
	at com.baidu.hugegraph.task.StandardTaskScheduler.call(StandardTaskScheduler.java:713)
	at com.baidu.hugegraph.task.StandardTaskScheduler.call(StandardTaskScheduler.java:701)
	at com.baidu.hugegraph.task.StandardTaskScheduler.init(StandardTaskScheduler.java:461)
	at com.baidu.hugegraph.StandardHugeGraph.initSystemInfo(StandardHugeGraph.java:391)
	at com.baidu.hugegraph.StandardHugeGraph.initBackend(StandardHugeGraph.java:339)
	at com.baidu.hugegraph.example.ExampleUtil.loadGraph(ExampleUtil.java:85)
	at com.baidu.hugegraph.example.ExampleUtil.loadGraph(ExampleUtil.java:58)
	at com.baidu.hugegraph.example.Example1.main(Example1.java:58)
Caused by: java.util.concurrent.ExecutionException: java.lang.UnsatisfiedLinkError: /Users/user/Library/Caches/JNA/temp/jna3881036102895889031.tmp: dlopen(/Users/user/Library/Caches/JNA/temp/jna3881036102895889031.tmp, 0x0001): tried: '/Users/user/Library/Caches/JNA/temp/jna3881036102895889031.tmp' (fat file, but missing compatible architecture (have (i386,x86_64), need (arm64e)))
	at java.util.concurrent.FutureTask.report(FutureTask.java:122)
	at java.util.concurrent.FutureTask.get(FutureTask.java:192)
	at com.baidu.hugegraph.task.StandardTaskScheduler.call(StandardTaskScheduler.java:711)
	... 7 more
Caused by: java.lang.UnsatisfiedLinkError: /Users/user/Library/Caches/JNA/temp/jna3881036102895889031.tmp: dlopen(/Users/user/Library/Caches/JNA/temp/jna3881036102895889031.tmp, 0x0001): tried: '/Users/user/Library/Caches/JNA/temp/jna3881036102895889031.tmp' (fat file, but missing compatible architecture (have (i386,x86_64), need (arm64e)))
	at java.lang.ClassLoader$NativeLibrary.load(Native Method)
	at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1950)
	at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1832)
	at java.lang.Runtime.load0(Runtime.java:783)
	at java.lang.System.load(System.java:1100)
	at com.sun.jna.Native.loadNativeDispatchLibraryFromClasspath(Native.java:1018)
	at com.sun.jna.Native.loadNativeDispatchLibrary(Native.java:988)
	at com.sun.jna.Native.<clinit>(Native.java:195)
	at org.caffinitas.ohc.alloc.JNANativeAllocator.allocate(JNANativeAllocator.java:26)
	at org.caffinitas.ohc.linked.Uns.allocate(Uns.java:331)
	at org.caffinitas.ohc.linked.OffHeapLinkedMap$Table.create(OffHeapLinkedMap.java:527)
	at org.caffinitas.ohc.linked.OffHeapLinkedMap.<init>(OffHeapLinkedMap.java:80)
	at org.caffinitas.ohc.linked.OffHeapLinkedLRUMap.<init>(OffHeapLinkedLRUMap.java:30)
	at org.caffinitas.ohc.linked.OHCacheLinkedImpl.makeMap(OHCacheLinkedImpl.java:150)
	at org.caffinitas.ohc.linked.OHCacheLinkedImpl.<init>(OHCacheLinkedImpl.java:108)
	at org.caffinitas.ohc.OHCacheBuilder.build(OHCacheBuilder.java:297)
	at com.baidu.hugegraph.backend.cache.OffheapCache.<init>(OffheapCache.java:68)
	at com.baidu.hugegraph.backend.cache.CacheManager.levelCache(CacheManager.java:144)
	at com.baidu.hugegraph.backend.cache.CachedGraphTransaction.cache(CachedGraphTransaction.java:109)
	at com.baidu.hugegraph.backend.cache.CachedGraphTransaction.<init>(CachedGraphTransaction.java:78)
	at com.baidu.hugegraph.StandardHugeGraph.openGraphTransaction(StandardHugeGraph.java:459)
	at com.baidu.hugegraph.StandardHugeGraph.access$5(StandardHugeGraph.java:455)
	at com.baidu.hugegraph.StandardHugeGraph$TinkerPopTransaction.getOrNewTransaction(StandardHugeGraph.java:1439)
	at com.baidu.hugegraph.StandardHugeGraph$TinkerPopTransaction.schemaTransaction(StandardHugeGraph.java:1413)
	at com.baidu.hugegraph.StandardHugeGraph$TinkerPopTransaction.access$0(StandardHugeGraph.java:1412)
	at com.baidu.hugegraph.StandardHugeGraph.schemaTransaction(StandardHugeGraph.java:490)
	at com.baidu.hugegraph.StandardHugeGraph.access$2(StandardHugeGraph.java:484)
	at com.baidu.hugegraph.StandardHugeGraph$StandardHugeGraphParams.schemaTransaction(StandardHugeGraph.java:1167)
	at com.baidu.hugegraph.task.StandardTaskScheduler$TaskTransaction.existVertexLabel(StandardTaskScheduler.java:798)
	at com.baidu.hugegraph.task.StandardTaskScheduler$TaskTransaction.initSchema(StandardTaskScheduler.java:775)
	at com.baidu.hugegraph.task.StandardTaskScheduler.lambda$1(StandardTaskScheduler.java:461)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at com.baidu.hugegraph.task.TaskManager$ContextCallable.call(TaskManager.java:354)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:750)

Vertex/Edge example (问题点 / 边数据举例)

No response

Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)

No response

@javeme javeme added the bug Something isn't working label Nov 8, 2022
@javeme javeme changed the title [Bug] JNA Mac m1 [Bug] Mac m1: JNA UnsatisfiedLinkError Nov 8, 2022
@javeme
Copy link
Contributor Author

javeme commented Nov 8, 2022

The reasons:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant