文章目录
- 一、现象
 - 二、解决方案
 
一、现象
当安装好JDK跟neo4j,用neo4j.bat console来启动neo4却报错:
部分报错信息:
 Starting Neo4j.
 WARNING! You are using an unsupported Java runtime.
- Please use Oracle® Java™ 11, OpenJDK™ 11 to run Neo4j.
 - Please see https://neo4j.com/docs/ for Neo4j installation instructions.
 
整体报错信息:
 Directories in use:
 home: C:\Users\Administrator\Downloads\neo4j-community-4.4.30
 config: C:\Users\Administrator\Downloads\neo4j-community-4.4.30\conf
 logs: C:\Users\Administrator\Downloads\neo4j-community-4.4.30\logs
 plugins: C:\Users\Administrator\Downloads\neo4j-community-4.4.30\plugins
 import: C:\Users\Administrator\Downloads\neo4j-community-4.4.30\import
 data: C:\Users\Administrator\Downloads\neo4j-community-4.4.30\data
 certificates: C:\Users\Administrator\Downloads\neo4j-community-4.4.30\certificates
 licenses: C:\Users\Administrator\Downloads\neo4j-community-4.4.30\licenses
 run: C:\Users\Administrator\Downloads\neo4j-community-4.4.30\run
 Starting Neo4j.
 WARNING! You are using an unsupported Java runtime.
- Please use Oracle® Java™ 11, OpenJDK™ 11 to run Neo4j.
 - Please see https://neo4j.com/docs/ for Neo4j installation instructions.
Java HotSpot™ 64-Bit Server VM warning: Option UseBiasedLocking was deprecated in version 15.0 and will likely be removed in a future release.
2024-03-20 15:07:35.077+0000 INFO Starting…
Exception in thread “main” java.lang.LinkageError: Cannot to link java.nio.DirectByteBuffer
at org.neo4j.internal.unsafe.UnsafeUtil.(UnsafeUtil.java:128)
at org.neo4j.memory.RuntimeInternals.guessHeaderSize(RuntimeInternals.java:158)
at org.neo4j.memory.RuntimeInternals.(RuntimeInternals.java:53)
at org.neo4j.memory.HeapEstimator.(HeapEstimator.java:103)
at org.neo4j.internal.collector.RecentQueryBuffer.(RecentQueryBuffer.java:37)
at org.neo4j.graphdb.factory.module.GlobalModule.(GlobalModule.java:212)
at org.neo4j.graphdb.facade.DatabaseManagementServiceFactory.createGlobalModule(DatabaseManagementServiceFactory.java:272)
at org.neo4j.graphdb.facade.DatabaseManagementServiceFactory.build(DatabaseManagementServiceFactory.java:133)
at org.neo4j.server.CommunityBootstrapper.createNeo(CommunityBootstrapper.java:36) 
二、解决方案
1.报错说是JDK得安装11的,查看目前JDK版本是17
 
2.安装JDK11
 我这里提供了网盘链接:https://pan.baidu.com/s/1q1AIULhLTGDnsw8RNBYKbQ
 提取码:1234
 



win+R,输入cmd,再输入java -version,若看到版本号是11,说明JDK11安装成功
 
3.neo4j启动成功
 


解决方案:网上各种资料尝试一番


















