system-image-cli tool fails on dangling symlink
| Affects | Status | Importance | Assigned to | Milestone | |
|---|---|---|---|---|---|
| | Snappy |
Critical
|
Oliver Grawert | ||
| | Ubuntu system image |
High
|
Barry Warsaw | ||
| | livecd-rootfs (Ubuntu) |
High
|
Oliver Grawert | ||
| | system-image (Ubuntu) |
High
|
Unassigned | ||
Bug Description
(amd64)
Traceback (most recent call last):
File "/usr/lib/
timestamp = datetime.
FileNotFoundError: [Errno 2] No such file or directory: '/userdata/
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/bin/
load_
File "/usr/lib/
last_
File "/usr/lib/
for path in config.ini_files)
File "/usr/lib/
for path in config.ini_files)
File "/usr/lib/
return self._accessor.
File "/usr/lib/
return strfunc(
FileNotFoundError: [Errno 2] No such file or directory: '/etc/system-
Related branches
- Barry Warsaw: Pending requested 2015-09-25
-
Diff: 395 lines (+147/-18)14 files modifiedNEWS.rst (+5/-0)
PKG-INFO (+1/-1)
debian/changelog (+11/-0)
debian/rules (+3/-0)
setup.cfg (+1/-1)
system_image.egg-info/PKG-INFO (+1/-1)
system_image.egg-info/SOURCES.txt (+1/-0)
system_image.egg-info/pbr.json (+1/-0)
systemimage/helpers.py (+12/-6)
systemimage/logging.py (+10/-6)
systemimage/testing/dbus.py (+28/-0)
systemimage/tests/test_dbus.py (+26/-2)
systemimage/tests/test_helpers.py (+46/-0)
systemimage/version.txt (+1/-1)
- Barry Warsaw: Pending requested 2015-09-25
| Barry Warsaw (barry) wrote : Re: [Bug 1495688] [NEW] system-image-cli tool fails on rolling/edge; missing file '/etc/system-image/config.d/00_default.ini | #1 |
| Ben Howard (utlemming) wrote : | #2 |
I was running "system-image-cli" via a chroot on a vanilla image; the
instance was never booted.
| Barry Warsaw (barry) wrote : | #3 |
On Sep 14, 2015, at 10:11 PM, Ben Howard wrote:
>I was running "system-image-cli" via a chroot on a vanilla image; the
>instance was never booted.
What does /etc/system-
| Oliver Grawert (ogra) wrote : Re: system-image-cli tool fails on rolling/edge; missing file '/etc/system-image/config.d/00_default.ini | #4 |
seems like system-image-common 3.x stopped shipping anything in /etc in the binary deb (i see it in the 2.x series in that package but not in 3.x anymore)
| Oliver Grawert (ogra) wrote : | #5 |
note that we use 3.x also in the 15.04 snappy builds, so 15.04 edge is broken the same way
| Oliver Grawert (ogra) wrote : | #6 |
i just found that simply removing /etc/system-
as a quick fix (since we are preparing a 15.04 snappy release) i'll rm that file during image build ... i'll leave the bug open since someone should examine where that dangling symlink comes from at all though.
| Changed in snappy: | |
| milestone: | none → 15.04.3 |
| Changed in snappy: | |
| assignee: | nobody → Oliver Grawert (ogra) |
| Changed in livecd-rootfs (Ubuntu): | |
| assignee: | nobody → Oliver Grawert (ogra) |
| Changed in snappy: | |
| importance: | Undecided → Critical |
| Changed in livecd-rootfs (Ubuntu): | |
| importance: | Undecided → High |
| status: | New → Fix Committed |
| Changed in snappy: | |
| status: | New → Fix Committed |
| Barry Warsaw (barry) wrote : | #7 |
If config.
| summary: |
- system-image-cli tool fails on rolling/edge; missing file '/etc/system- - image/config.d/00_default.ini + system-image-cli tool fails on dangling symlink |
| tags: | added: client |
| Changed in system-image (Ubuntu): | |
| importance: | Undecided → High |
| assignee: | nobody → Barry Warsaw (barry) |
| assignee: | Barry Warsaw (barry) → nobody |
| Changed in ubuntu-system-image: | |
| status: | New → Triaged |
| importance: | Undecided → High |
| assignee: | nobody → Barry Warsaw (barry) |
| milestone: | none → 3.1 |
| Changed in snappy: | |
| status: | Fix Committed → Fix Released |
| Changed in ubuntu-system-image: | |
| milestone: | 3.1 → 3.0.2 |
| status: | Triaged → In Progress |
| Barry Warsaw (barry) wrote : | #8 |
So I have a merge proposal ready to fix this problem, but as I've mentioned in LP: #1495207 two things are still mysterious:
How did you hit this bug when it's only possible in si 3.0, and that version is only available in Wily?
How is the server producing dangling symlinks?
| Changed in ubuntu-system-image: | |
| status: | In Progress → Fix Committed |
| Changed in system-image (Ubuntu): | |
| status: | New → Triaged |
| Changed in ubuntu-system-image: | |
| status: | Fix Committed → Fix Released |
| Changed in system-image (Ubuntu): | |
| milestone: | none → ubuntu-15.10 |
| Launchpad Janitor (janitor) wrote : | #9 |
This bug was fixed in the package system-image - 3.0.2-0ubuntu1
---------------
system-image (3.0.2-0ubuntu1) wily; urgency=medium
[ CI Train Bot ]
* New rebuild forced.
system-image (3.0.2-0ubuntu1) wily; urgency=medium
* New upstream release.
- LP: #1495688 - Don't crash when one of the .ini files is a dangling
symlink.
- d/rules: override_
remove the .egg-info files and that causes the Jenkins job in the CI
train to fail.
-- Barry Warsaw <email address hidden> Mon, 28 Sep 2015 21:37:45 +0000
| Changed in system-image (Ubuntu): | |
| status: | Triaged → Fix Released |


On Sep 14, 2015, at 08:40 PM, Ben Howard wrote:
>Public bug reported: ubuntu@ localhost: ~$ system-image-cli -i python3/ dist-packages/ systemimage/ helpers. py", line 253, in last_update_date fromtimestamp( os.stat( LAST_UPDATE_ FILE).st_ mtime) .last_update'
>
>
>(amd64)
>Traceback (most recent call last):
> File "/usr/lib/
> timestamp = datetime.
>FileNotFoundError: [Errno 2] No such file or directory:
>'/userdata/
This can be an expected exception, because it's possible for .last_update to be missing. That case is handled, and the real
/userdata/
problem is here:
>During handling of the above exception, another exception occurred: system- image-cli" , line 9, in <module> point(' system- image== 3.0.1', 'console_scripts', 'system- image-cli' )() python3/ dist-packages/ systemimage/ main.py" , line 289, in main last_update_ date(), python3/ dist-packages/ systemimage/ helpers. py", line 258, in last_update_date python3/ dist-packages/ systemimage/ helpers. py", line 258, in <genexpr> python3. 4/pathlib. py", line 1048, in stat stat(self) python3. 4/pathlib. py", line 326, in wrapped str(pathobj) , *args) image/config. d/00_default. ini'
>
>Traceback (most recent call last):
> File "/usr/bin/
> load_entry_
> File "/usr/lib/
> last_update=
> File "/usr/lib/
> for path in config.ini_files)
> File "/usr/lib/
> for path in config.ini_files)
> File "/usr/lib/
> return self._accessor.
> File "/usr/lib/
> return strfunc(
>FileNotFoundError: [Errno 2] No such file or directory: '/etc/system-
What happened to /etc/system- image/config. d/00_default. ini? What this is
saying is that after system-image-cli started up, this config file (or its
directory) got lost or removed. That shouldn't ever happen.
Are you able to do some live debugging?