ebtables cannot be upgraded from 2.0.10.4-3.5ubuntu2 to 2.0.10.4-3.5ubuntu2.18.04.1 on WSL
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
ebtables (Ubuntu) |
Fix Released
|
Low
|
Dan Streetman | ||
Trusty |
Won't Fix
|
Low
|
Unassigned | ||
Xenial |
Fix Released
|
Low
|
Balint Reczey | ||
Artful |
Fix Released
|
Low
|
Balint Reczey | ||
Bionic |
Fix Released
|
Low
|
Balint Reczey | ||
Cosmic |
Fix Released
|
Low
|
Dan Streetman |
Bug Description
[impact]
ebtables cannot be upgraded on Ubuntu 18.04 for WSL.
[test case]
on a WSL installation that already has ebtables installed (most installations do), try to upgrade the package with apt or dpkg; its prerm script will fail, and prevent the upgrade.
The easiest way of triggering the problem is reinstalling the package:
$ sudo apt install --reinstall ebtables
[regression potential]
the ebtables init script is changed to never return an error code when called as 'stop', so anything that depends on the script returning an error code when 'stop' fails will no longer work correctly. However, nothing appears to use the 'stop' return value, besides the package's prerm script, which is what is causing the upgrade failure. Additionally, the prerm script is updated to ignore 'failed-upgrade' failures, to allow upgrading over the previous version(s).
Finally note that the rpm-specific ebtables.spec file that is included in the package specifically ignores the 'stop' return value, i.e.:
[other info]
note that ebtables is effectively dead upstream, so it's extremely unlikely there will be many more package updates/srus, except to fix minor bugs such as this.
[original description]
ebtables cannot be upgraded on Ubuntu 18.04 for WSL.
apt-get upgrade fails with the following error:
Reading package lists...
Building dependency tree...
Reading state information...
Calculating upgrade...
The following packages will be upgraded:
ebtables
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/79.9 kB of archives.
After this operation, 0 B of additional disk space will be used.
(Reading database ...
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 47381 files and directories currently installed.)
Preparing to unpack .../ebtables_
invoke-rc.d: could not determine current runlevel
[31m*[39;49m Error: insufficient privileges to access the ebtables rulesets.
invoke-rc.d: initscript ebtables, action "stop" failed.
dpkg: warning: old ebtables package pre-removal script subprocess returned error exit status 1
dpkg: trying script from the new package instead ...
invoke-rc.d: could not determine current runlevel
[31m*[39;49m Error: insufficient privileges to access the ebtables rulesets.
invoke-rc.d: initscript ebtables, action "stop" failed.
dpkg: error processing archive /var/cache/
new ebtables package pre-removal script subprocess returned error exit status 1
update-rc.d: warning: start and stop actions are no longer supported; falling back to defaults
invoke-rc.d: could not determine current runlevel
Errors were encountered while processing:
/var/cache/
tags: | added: patch |
description: | updated |
tags: | added: id-5b0ff20a61c73d97a81ca9e0 |
Changed in ebtables (Ubuntu Xenial): | |
assignee: | Dan Streetman (ddstreet) → Balint Reczey (rbalint) |
Changed in ebtables (Ubuntu Artful): | |
assignee: | Dan Streetman (ddstreet) → Balint Reczey (rbalint) |
Changed in ebtables (Ubuntu Bionic): | |
assignee: | Dan Streetman (ddstreet) → Balint Reczey (rbalint) |
description: | updated |
tags: |
added: verification-done-bionic removed: verification-needed-bionic |
tags: |
added: verification-done verification-done-artful verification-done-xenial removed: verification-needed verification-needed-artful verification-needed-xenial |
$ apt-get -V -s upgrade 4-3.5ubuntu2 => 2.0.10. 4-3.5ubuntu2. 18.04.1) 4-3.5ubuntu2] (2.0.10. 4-3.5ubuntu2. 18.04.1 Ubuntu: 18.04/bionic- updates [amd64]) 4-3.5ubuntu2. 18.04.1 Ubuntu: 18.04/bionic- updates [amd64])
NOTE: This is only a simulation!
apt-get needs root privileges for real execution.
Keep also in mind that locking is deactivated,
so don't depend on the relevance to the real current situation!
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages will be upgraded:
ebtables (2.0.10.
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Inst ebtables [2.0.10.
Conf ebtables (2.0.10.