Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WSL2][systemd] Unable to upgrade systemd #8847

Closed
1 of 2 tasks
Re4son opened this issue Sep 22, 2022 · 8 comments
Closed
1 of 2 tasks

[WSL2][systemd] Unable to upgrade systemd #8847

Re4son opened this issue Sep 22, 2022 · 8 comments
Assignees
Labels

Comments

@Re4son
Copy link

Re4son commented Sep 22, 2022

Version

Microsoft Windows [Version 10.0.22000.1042]

WSL Version

  • WSL 2
  • WSL 1

Kernel Version

5.15.62.1

Distro Version

Ubuntu 20.04.5 LTS

Other Software

No response

Repro Steps

sudo apt update && sudo apt install --reinstall systemd

Expected Behavior

successful upgrade (or re-installation) of systemd

Actual Behavior

<snip>
Unpacking systemd (245.4-4ubuntu3.18) over (245.4-4ubuntu3.18) ...
dpkg: error processing archive /var/cache/apt/archives/systemd_245.4-4ubuntu3.18_amd64.deb (--unpack):
 unable to make backup link of './usr/lib/tmpfiles.d/tmp.conf' before installing new version: Invalid cross-device link
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
<snip>
re4son@wopr-xps:~$ debsums -x systemd
debsums: can't check systemd file /usr/lib/tmpfiles.d/tmp.conf (not a regular file)
debsums: can't check systemd file /usr/lib/tmpfiles.d/x11.conf (not a regular file)

Diagnostic Logs

No response

@mlankamp
Copy link

Temporary solution is to set systemd=false in /etc/wsl.conf and the run wsl --shutdown.

the run sudo apt update or whatever

then enable systemd again

@benhillis
Copy link
Member

Thanks for posting, this is a known issue and we're working on a resolution.

@benhillis benhillis self-assigned this Sep 22, 2022
@dingdang66686
Copy link

@benhillis You can use /etc/tmpfiles.d/x11.conf to override the default behavior of systemd.

@OtherHorizon
Copy link

@benhillis You can use /etc/tmpfiles.d/x11.conf to override the default behavior of systemd.

is removing zsh entirely part of the default behaviour of systemd? cause following this guide did.

@Biswa96 Biswa96 mentioned this issue Sep 23, 2022
2 tasks
@benhillis
Copy link
Member

Should be resolved with 0.68.2, could somebody please verify?

@zikhan
Copy link

zikhan commented Sep 29, 2022

I have verified that 0.68.2 fixed the issue. Tested on Ubuntu 22.04.1 LTS.

sudo apt update no longer lists systemd and it's dependencies as needing updates
sudo apt upgrade no longer errors out on trying to update systemd
sudo apt install --reinstall systemd reinstalls systemd

@cerebrate
Copy link

cerebrate commented Sep 29, 2022

I can also verify this as working on Debian bookworm/sid under 0.68.2.

@benhillis
Copy link
Member

Nice, thanks for confirming!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

7 participants