0. 准备环境
安装 JDK
neo4j 5.x 要求运行的版本是 >=jdk17
1. 下载
wget https://dist.neo4j.org/neo4j-community-5.3.0-unix.tar.gz
2. 解压
tar -zxvf neo4j-community-5.3.0-unix.tar.gz -C /opt/module/
3. 配置
vim /opt/module/neo4j-community-5.3.0/conf/neo4j.conf
3.1 修改路径
server.directories.data=/opt/module/neo4j-community-5.3.0/data
server.directories.plugins=/opt/module/neo4j-community-5.3.0/plugins
server.directories.logs=/opt/module/neo4j-community-5.3.0/logs
3.2 修改内存大小
server.memory.heap.initial_size=1024m
server.memory.heap.max_size=1024m
3.3 修改地址
server.default_listen_address=0.0.0.0
server.bolt.listen_address=:7687
server.http.listen_address=:7474
4. 启动 Neo4j
4.1 启动
/opt/module/neo4j-community-5.3.0/bin/neo4j start
4.2 查看状态
/opt/module/neo4j-community-5.3.0/bin/neo4j status
4.3 停止
/opt/module/neo4j-community-5.3.0/bin/neo4j stop
5. UI
URL: http://localhost:7474
默认账号:neo4j
默认密码:neo4j
注意:需要打开对应端口
firewall-cmd --zone=public --permanent --add-port=7474/tcp
firewall-cmd --zone=public --permanent --add-port=7687/tcp
firewall-cmd --reload
firewall-cmd --list-ports