jdk1.8对应的neo4j的版本是3.5
自行下载3.5版本的zip文件
解压添加环境变量
变量名:NEO4J_HOME
变量值:D:\neo4j-community-3.5.0 (你自己的地址)
PATH添加:
%NEO4J_HOME%\bin (如果是挨着的注意前后英文分号)
此时进入bin目录下运行报错:
neo4j.bat start
Invoke-Neo4j : Could not find the Windows Service Name for Neo4j (dbms.windows_service_name in neo4j.conf)所在位置 行:1 字符: 195
... community-3.5.0\bin\Neo4j-Management.psd1'; Exit (Invoke-Neo4j start)
~~~~~~~~~~~~~~~~~~
CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Invoke-Neo4j
解决办法:
进入该目录:
D:\neo4j-community-3.5.0\bin\Neo4j-Management
打开 Invoke-Neo4jUtility.ps1文件:加入红色部分
process
{
$javaPath = 'D:\jdk1.8'
Determine the Neo4j Home Directory. Uses the NEO4J_HOME environment variable or a parent directory of this script
$Neo4jHome = Get-Neo4jEnv 'NEO4J_HOME'
if (($Neo4jHome -eq $null) -or (-not (Test-Path -Path $Neo4jHome))) {
$Neo4jHome = Split-Path -Path (Split-Path -Path $PSScriptRoot -Parent) -Parent
保存
命令行窗口进入bin运行:
neo4j.bat install-service
neo4j.bat start
即可
打开浏览器地址栏输入:
账号密码都是neo4j,后需更改密码