Can't upgrade console-setup-linux (1.194ubuntu3) over (1.108ubuntu15.5), trying to overwrite '/lib/systemd/system/console-setup.service', which is also in package keyboard-configuration 1.108ubuntu15.5

Bug #1872824 reported by Hayden Barnes
34
This bug affects 7 people
Affects Status Importance Assigned to Milestone
console-setup (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Upgrade path from 16.04 to 20.04 fails.

console-setup-linux_1.194ubuntu3_all.deb tries to overwrite '/lib/systemd/system/console-setup.service', which is also in package keyboard-configuration 1.108ubuntu15.5.

I have reproduced this bug on bare metal and WSL.

Log:

Unpacking console-setup-linux (1.194ubuntu3) over (1.108ubuntu15.5) ...
dpkg: error processing archive /var/cache/apt/archives/console-setup-linux_1.194ubuntu3_all.deb (--unpack):
 trying to overwrite '/lib/systemd/system/console-setup.service', which is also in package keyboard-configuration 1.108ubuntu15.5
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Preparing to unpack .../keyboard-configuration_1.194ubuntu3_all.deb ...
Unpacking keyboard-configuration (1.194ubuntu3) over (1.108ubuntu15.5) ...
Preparing to unpack .../busybox-initramfs_1%3a1.30.1-4ubuntu6_amd64.deb ...
Unpacking busybox-initramfs (1:1.30.1-4ubuntu6) over (1:1.22.0-15ubuntu1.4) ...
Preparing to unpack .../initramfs-tools-bin_0.136ubuntu6_amd64.deb ...
Unpacking initramfs-tools-bin (0.136ubuntu6) over (0.122ubuntu8.16) ...
Preparing to unpack .../cpio_2.13+dfsg-2_amd64.deb ...
Unpacking cpio (2.13+dfsg-2) over (2.11+dfsg-5ubuntu1.1) ...
Preparing to unpack .../liblz4-1_1.9.2-2_amd64.deb ...
Unpacking liblz4-1:amd64 (1.9.2-2) over (0.0~r131-2ubuntu2) ...
Processing triggers for libc-bin (2.31-0ubuntu7) ...
Processing triggers for ureadahead (0.100.0-19.1) ...
Processing triggers for systemd (229-4ubuntu21.27) ...
Processing triggers for man-db (2.7.5-1) ...
Errors were encountered while processing:
 /var/cache/apt/archives/console-setup-linux_1.194ubuntu3_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in console-setup (Ubuntu):
status: New → Confirmed
Revision history for this message
David Martinka (mainmachine) wrote :

I got stuck in this situation as well, and I was able to manually "unstick" things like this:

```sudo apt install -f -y console-setup-linux keyboard-configuration console-setup systemd libpam-systemd```

Revision history for this message
David Martinka (mainmachine) wrote :

Revisiting this as the fix I posted was inaccurate. I did manage to resolve it successfully as I will explain.

I had to manually upgrade the three packages in the dependency chain that was causing the issue like so (order is important):

# keyboard-configuration console-setup-linux console-setup

dpkg -i /path/to/keyboard-configuration_*.deb
dpkg -i /path/to/console-setup-linux_*.deb
dpkg -i /path/to/console-setup_*.deb

I think I ran into other conflicts, but this was the trickiest, as apt always wanted to install them in what appears to be out of the logical dependency order, and would always result in the above error.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.