虚拟机管理器无法启动创建对话框 - pci.ids 丢失

虚拟机管理器无法启动创建对话框 - pci.ids 丢失

我正在使用 Pop!_OS 20.10,并且我已经virt-manager使用apt.但是,每当我在应用程序中单击“创建新虚拟机”时,都会弹出以下错误:

Error launching create dialog: g-io-error-quark: Error opening file /usr/share/misc/pci.ids: No such file or directory (1)

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/createvm.py", line 111, in show_instance
    cls._instance = vmmCreateVM()
  File "/usr/share/virt-manager/virtManager/createvm.py", line 188, in __init__
    self._init_state()
  File "/usr/share/virt-manager/virtManager/createvm.py", line 324, in _init_state
    self._os_list = vmmOSList()
  File "/usr/share/virt-manager/virtManager/oslist.py", line 39, in __init__
    self._init_state()
  File "/usr/share/virt-manager/virtManager/oslist.py", line 55, in _init_state
    all_os = virtinst.OSDB.list_os()
  File "/usr/share/virt-manager/virtinst/osdict.py", line 274, in list_os
    for name, osobj in self._all_variants.items():
  File "/usr/share/virt-manager/virtinst/osdict.py", line 198, in _all_variants
    loader = self._os_loader
  File "/usr/share/virt-manager/virtinst/osdict.py", line 190, in _os_loader
    loader.process_default_path()
gi.repository.GLib.GError: g-io-error-quark: Error opening file /usr/share/misc/pci.ids: No such file or directory (1)

我查了“pci.ids”,好像是系统文件,为什么不存在呢?lspci工作正常。

版本virt-manager是 2.2.1,来自官方 Pop!_OS/Ubuntu(不确定)存储库。

由于已请求,因此输出apt list | grep libosinfo

gir1.2-libosinfo-1.0/groovy,now 1.7.1-1 amd64 [installed,automatic]
libosinfo-1.0-0/groovy,now 1.7.1-1 amd64 [installed,automatic]
libosinfo-1.0-dev/groovy 1.7.1-1 amd64
libosinfo-bin/groovy 1.7.1-1 amd64
libosinfo-l10n/groovy,groovy 1.7.1-1 all

附加说明:在错误中提到的文件夹中,有一个名称相似但经过 gzip 压缩的文件。的ls -lARF输出/usr/share/misc

.:
total 940
-rwxr-xr-x 1 root root  44283 Feb 24  2018 config.guess*
-rwxr-xr-x 1 root root  36136 Feb 24  2018 config.sub*
lrwxrwxrwx 1 root root     13 May 16  2020 magic -> ../file/magic/
lrwxrwxrwx 1 root root     24 May 16  2020 magic.mgc -> ../../lib/file/magic.mgc
-rw-r--r-- 1 root root 288895 Apr  1 16:46 pci.ids.gz
-rw-r--r-- 1 root root 292413 Apr  1 16:46 pci.ids.gz.new
-rw-r--r-- 1 root root 292413 Apr  1 16:46 pci.ids.gz.neww
-rw-r--r-- 1 root root      0 Jan 30 12:52 pci.ids.gz.old
lrwxrwxrwx 1 root root     25 Aug 26  2020 usb.ids -> /var/lib/usbutils/usb.ids

答案1

编辑

我有完全相同的版本libosinfovirt-manager,但我正在运行focal发行版(你的是groovy)。正如您所看到的,该文件pci.ids不存在于/usr/share/misc。尝试清除并重新安装virt-manager。如果这没有帮助,libosinfo/groovy则这是一个错误 ( ),应该报告。

为了进行比较,以下是我向您提出的要求的输出。

$ apt list | grep libosinfo

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

gir1.2-libosinfo-1.0/focal,now 1.7.1-1 amd64 [installed,automatic]
libosinfo-1.0-0/focal,now 1.7.1-1 amd64 [installed,automatic]
libosinfo-1.0-dev/focal 1.7.1-1 amd64
libosinfo-bin/focal 1.7.1-1 amd64
libosinfo-l10n/focal,focal 1.7.1-1 all

$ tree /usr/share/misc
/usr/share/misc
├── magic -> ../file/magic
├── magic.mgc -> ../../lib/file/magic.mgc
├── pci.ids
└── usb.ids -> /var/lib/usbutils/usb.ids

1 directory, 3 files

/编辑

virt-manager应该已经安装了libosinfo软件包。

apt list | grep libosinfo您能发布和的输出tree /usr/share/misc吗?

相关内容