Apache Ambari 安装问题

Apache Ambari 安装问题

我正在尝试从 Apache BigTop repo 安装 Ambari,但是我收到有关 python 依赖项的错误:

vagrant@vagrant:~$ sudo apt install ambari\*
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Note, selecting 'ambari-server' for glob 'ambari*'
Note, selecting 'ambari-agent' for glob 'ambari*'
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 ambari-agent : Depends: python (>= 2.6) but it is not installable
 ambari-server : Depends: python (>= 2.6) but it is not installable
E: Unable to correct problems, you have held broken packages.

检查python:

vagrant@vagrant:~$ python --version
Python 2.7.18
vagrant@vagrant:~$ apt-cache policy python
python:
  Installed: (none)
  Candidate: (none)
  Version table:
vagrant@vagrant:~$ sudo update-alternatives --config python
There are 2 choices for the alternative python (providing /usr/bin/python).

  Selection    Path              Priority   Status
------------------------------------------------------------
  0            /usr/bin/python3   2         auto mode
* 1            /usr/bin/python2   1         manual mode
  2            /usr/bin/python3   2         manual mode
vagrant@vagrant:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 22.04.1 LTS
Release:        22.04
Codename:       jammy

我究竟做错了什么?

谢谢!

答案1

我在 Ubuntu 22.04 上部署由 Bigtop (3.2.0) 打包的 Ambari (2.7.5) 时遇到了同样的问题。问题是 Ubuntu 22.04 没有该python (>= 2.6.0)软件包。您必须使用python2 (>= 2.7)安装的软件包。要更改此软件包,请bigtop-packages/src/deb/ambari/control在 Bigtop Ambari 项目中打开文件并更改python (>= 2.6.0)python2 (>= 2.7)。这也必须在项目中完成。之后,在测试新部署之前,重建您的软件包并再次打包它们。请记住,您可能会遇到与bigtop-ambari-mpack版本之间的 Python 不兼容问题。我还没有测试过这个问题。2.62.7

新的control文件将会像这样:

Source: ambari
Section: misc
Priority: extra
Maintainer: Bigtop <[email protected]>
Build-Depends: debhelper (>= 6)
Standards-Version: 3.8.0
Homepage: http://ambari.apache.org/

Package: ambari-server
Architecture: all
Depends: openssl, postgresql (>= 8.1), python2 (>= 2.7), curl
Description: Ambari Server 

Package: ambari-agent
Architecture: all
Depends: openssl, python2 (>= 2.7), curl
Description: Ambari Agent 

也许答案已经晚了。但我希望这可以帮助其他人解决这个问题。

相关内容