0

After any update or upgrade operation I get the following:

Need to get 0 B/389 MB of archives.
After this operation, 416 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Extracting templates from packages: 100%
Preconfiguring packages ...
Setting up systemd (237-3ubuntu7) ...
Synchronizing state of ondemand.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable ondemand
[/usr/lib/tmpfiles.d/tmp.conf:15] Failed to replace specifiers: /tmp/systemd-private-%b-*
[/usr/lib/tmpfiles.d/tmp.conf:16] Failed to replace specifiers: /tmp/systemd-private-%b-*/tmp
[/usr/lib/tmpfiles.d/tmp.conf:17] Failed to replace specifiers: /var/tmp/systemd-private-%b-*
[/usr/lib/tmpfiles.d/tmp.conf:18] Failed to replace specifiers: /var/tmp/systemd-private-%b-*/tmp
dpkg: error processing package systemd (--configure):
 installed systemd package post-installation script subprocess returned error exit status 1
Errors were encountered while processing:
 systemd
E: Sub-process /usr/bin/dpkg returned an error code (1)

This happens after trying to update to ubuntu 18 from 16 on WSL

rawsh
  • 101
  • 3
  • You would run the command, in the answer to the duplicate question, within a elevated command prompt obviously. I am going under the assumption that you are using 1709+ due to the fact your using Ubuntu 18 instead of Ubuntu 16 which would have been the distribution for 1607 and 1703. I suspect you are not running the correct command to update the instance though, but you didn't indicate, what command you ran. SO I can't answer your actual question. – Ramhound Apr 12 '18 at 04:35
  • You should only be running `lxrun /update` in order to update the WSL Ubuntu package by the way. – Ramhound Apr 12 '18 at 04:36
  • @Ramhound `lxrun` is deprecated since Windows 1709 and cannot be used to update Linux installed from the Windows Store. – Benjamin T Apr 27 '18 at 05:46

2 Answers2

0

What worked for me is Ramhound's comment:

lxrun /update

The correct way was to reset then update.

rawsh
  • 101
  • 3
-1

You've to completely remove Linux sub system and reinstall it.

Completely uninstall Ubuntu\bash from Windows with lxrun.exe /uninstall full.

Disable windows subsystem for Linux (beta) feature

Do a system clean on C drive, so that it'll remove remaining temporary files.

Re-enable Windows subsystem for Linux (beta) feature.

surjit
  • 241
  • 2
  • 4