知识库

在 Debian 或 Ubuntu 上安装 Neo4j 数据库失败,并出现“以下软件包存在未满足的依赖关系”错误

在 Debian 或 Ubuntu 上安装 Neo4j 数据库时出现错误

The following packages have unmet dependencies:
 neo4j-enterprise : Depends: cypher-shell (< 1.2.0) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

为什么会这样?

apt 包管理器无法处理同一软件包的多个版本,在本例中是 Cypher Shell 1.1.12 和 4.0。

如何解决此问题?

在我们找到此问题的解决方案之前,我们建议使用以下解决方法

cypher-shell=1.1.12 添加到 apt 安装命令的末尾,例如

sudo apt install neo4j cypher-shell=1.1.12

这样可以确保为 Neo4j 数据库版本 3.x 安装最新支持的 Cypher Shell 版本。