In a new 20.04 LXD container, do-release-upgrade crashes as lspci cannot be found
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
ubuntu-release-upgrader (Ubuntu) |
Invalid
|
High
|
Unassigned | ||
Jammy |
Fix Released
|
High
|
Brian Murray |
Bug Description
Impact
------
It is not possible to use do-release-upgrade on some installs (lxc containers, chroots) of Ubuntu as pci-utils may not be installed. It is called by nvidiadetector (bundled in the dist-upgrader tarball) which in turn is called by a newly added upgrade quirk.
Test Case
---------
1) lxc launch images:ubuntu/20.04
2) get a shell on the container
3) Install ubuntu-
4) Run do-release-upgrade
do-release-upgrade crashes with the trace below
With the version of ubuntu-
Regression Potential
-------
There could be syntax errors or typos in the added check but running the test case will reveal those.
Installing pciutils for the lspci binary fixes the issue
***** shell input and trace *****
# do-release-upgrade
Checking for a new Ubuntu release
Get:1 Upgrade tool signature [819 B]
Get:2 Upgrade tool [1267 kB]
Fetched 1268 kB in 0s (0 B/s)
authenticate 'jammy.tar.gz' against 'jammy.tar.gz.gpg'
extracting 'jammy.tar.gz'
Reading cache
Checking package manager
Reading package lists... Done
Building dependency tree
Reading state information... Done
Hit http://
Hit http://
Hit http://
Fetched 0 B in 0s (0 B/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
A fatal error occurred
Please report this as a bug and include the files
/var/log/
your report. The upgrade has aborted.
Your original sources.list was saved in
/etc/apt/
Traceback (most recent call last):
File "/tmp/ubuntu-
<module>
sys.exit(main())
File
"/tmp/ubuntu-
line 241, in main
if app.run():
File
"/tmp/ubuntu-
line 2042, in run
return self.fullUpgrade()
File
"/tmp/ubuntu-
line 1873, in fullUpgrade
if not self.doPostInit
File
"/tmp/ubuntu-
line 906, in doPostInitialUpdate
self.quirks.
File
"/tmp/ubuntu-
line 99, in run
func()
File
"/tmp/ubuntu-
line 126, in jammyPostInitia
self._fix_
File
"/tmp/ubuntu-
line 1492, in _fix_missing_
nv = NvidiaDetection()
File
"/tmp/ubuntu-
line 72, in __init__
self.detection()
File
"/tmp/ubuntu-
line 113, in detection
p1 = Popen(['lspci', '-n'], stdout=PIPE, universal_
File "/usr/lib/
self._execute_
File "/usr/lib/
raise child_exception
FileNotFoundError: [Errno 2] No such file or directory: 'lspci
---
ProblemType: Bug
ApportVersion: 2.20.11-
Architecture: amd64
CasperMD5CheckR
CrashDB: ubuntu
DistroRelease: Ubuntu 20.04
Package: ubuntu-
PackageArchitec
ProcEnviron:
TERM=xterm-
PATH=(custom, no user)
LANG=C.UTF-8
ProcVersionSign
Tags: focal dist-upgrade
Uname: Linux 4.15.0-188-generic x86_64
UpgradeStatus: Upgraded to focal on 2022-08-11 (0 days ago)
UserGroups: N/A
VarLogDistupgra
Log time: 2022-08-11 17:10:43.752341
Log time: 2022-08-11 17:10:46.113962
_MarkForUpload: True
summary: |
- In a new 22.04 LXD container, do-release-upgrade crashes as lspci cannot + In a new 20.04 LXD container, do-release-upgrade crashes as lspci cannot be found |
tags: | added: rls-jj-incoming |
Changed in ubuntu-release-upgrader (Ubuntu): | |
importance: | Undecided → High |
tags: | added: fr-2609 |
tags: | removed: rls-jj-incoming |
Changed in ubuntu-release-upgrader (Ubuntu Jammy): | |
status: | Triaged → In Progress |
description: | updated |
description: | updated |
description: | updated |
tags: | added: foundations-todo |
tags: | removed: foundations-todo |
apport information