在 ubuntu 上,glance 无法安装依赖项

在 ubuntu 上,glance 无法安装依赖项
apt install -y glance

正在读取软件包列表... 完成 正在构建依赖关系树 正在读取状态信息... 完成 Glance 已经是最新版本 (2:19.0.2-0ubuntu1~cloud0)。您可能需要运行“apt --fix-broken install”来更正这些问题。以下软件包具有未满足的依赖关系:python3-glance-store:依赖:python3-cinderclient(>= 1:3.3.0)但不会安装 E:未满足的依赖关系。尝试在不使用软件包的情况下运行“apt --fix-broken install”(或指定解决方案)。

当我尝试安装 python3-cinderclient 时。

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
  dkms efibootmgr gir1.2-geocodeglib-1.0 libfwup1 libllvm8 libwayland-egl1-mesa ubuntu-web-launchers
Use 'apt autoremove' to remove them.
The following NEW packages will be installed:
  python3-cinderclient
0 upgraded, 1 newly installed, 0 to remove and 4 not upgraded.
40 not fully installed or removed.
Need to get 0 B/136 kB of archives.
After this operation, 1,129 kB of additional disk space will be used.
(Reading database ... 196495 files and directories currently installed.)
Preparing to unpack .../python3-cinderclient_1%3a5.0.0-0ubuntu2~cloud0_all.deb ...
Unpacking python3-cinderclient (1:5.0.0-0ubuntu2~cloud0) ...
dpkg: error processing archive /var/cache/apt/archives/python3-cinderclient_1%3a5.0.0-0ubuntu2~cloud0_all.deb

(--unpack): 尝试覆盖‘/usr/share/bash-completion/completions/cinder.bash_completion’,它也位于包 python-cinderclient 1:3.5.0-0ubuntu1 中。处理时遇到错误:/var/cache/apt/archives/python3-cinderclient_1%3a5.0.0-0ubuntu2~cloud0_all.deb E: 子进程 /usr/bin/dpkg 返回错误代码 (1)

如果我忽略这一点并运行任何 Glance 图像上传,我就会收到此错误。

OpenStack:

openstack image create cirros3.5 --file cirros-0.3.5-x86_64-disk.img --disk-format qcow2 --container-format bare --public

查找地址时出错http://控制器:9292/v2/schemas/image:HTTPConnectionPool(host ='controller',port = 9292):url 超出最大重试次数:/v2/schemas/image(由 NewConnectionError(':无法建立新连接:[Errno 111] 连接被拒绝',)引起)root @ controller:/home/osboxes# openstack image create cirros3.5 --file cirros-0.3.5-x86_64-disk.img --disk-format qcow2 --container-format bare --public

答案1

我遇到了同样的问题。

我使用以下命令强制覆盖该包:

sudo dpkg -i --force-overwrite \
  /var/cache/apt/archives/python3-cinderclient_1%3a5.0.0-0ubuntu2~cloud0_all.deb

如果这解决了你的问题,请告诉我

相关内容