[Bug 1958668] Re: Do not propose to reboot on WSL
Łukasz Zemczak
1958668 at bugs.launchpad.net
Tue Jul 19 15:17:42 UTC 2022
Hello Jean-Baptiste, or anyone else affected,
Accepted ubuntu-release-upgrader into jammy-proposed. The package will
build now and be available at
https://launchpad.net/ubuntu/+source/ubuntu-release-upgrader/1:22.04.12
in a few hours, and then in the -proposed repository.
Please help us by testing this new package. See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how
to enable and use -proposed. Your feedback will aid us getting this
update out to other Ubuntu users.
If this package fixes the bug for you, please add a comment to this bug,
mentioning the version of the package you tested, what testing has been
performed on the package and change the tag from verification-needed-
jammy to verification-done-jammy. If it does not fix the bug for you,
please add a comment stating that, and change the tag to verification-
failed-jammy. In either case, without details of your testing we will
not be able to proceed.
Further information regarding the verification process can be found at
https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in
advance for helping!
N.B. The updated package will be released to -updates after the bug(s)
fixed by this package have been verified and the package has been in
-proposed for a minimum of 7 days.
** Changed in: ubuntu-release-upgrader (Ubuntu Jammy)
Status: In Progress => Fix Committed
** Tags added: verification-needed verification-needed-jammy
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to ubuntu-release-upgrader in
Ubuntu.
https://bugs.launchpad.net/bugs/1958668
Title:
Do not propose to reboot on WSL
Status in ubuntu-release-upgrader package in Ubuntu:
Fix Released
Status in ubuntu-release-upgrader source package in Jammy:
Fix Committed
Bug description:
[Impact]
- On WSL, at the end of a do-release-upgrade, the upgrader proposes to
reboot the machine. On WSL it is not possible to reboot due to the
lack of systemd, thus this causes an error message to appear, and the
reboot to not happen.
- The fix solves this by:
1. Not atemptiong to reboot
2. Asking the user to close the WSL instance
- Furthermore, if the Ubuntu WSL launcher is recent enough:
3. ubuntu-release-upgrade will signal the Ubuntu WSL launcher to shutdown WSL right after closing
[Test Plan]
- Open ubuntu WSL
- Run do-release-upgrade -p
- Old behaviour: Error message:
"System has not been booted with systemd as init system (PID 1). Can't operate."
- New behaviour:
1. You'll be asked to close all other instances of Ubuntu WSL.
2. File /proc/sys/fs/binfmt_misc/WSLInterop will be created with contents
"action: reboot"
3. You'll be asked to close the current instance of Ubuntu WSL.
4. If you have the store verion of Ubuntu WSL nothing else will happen.
If you have the latest version from the repository, Ubuntu WSL will
shutdown right after. You can validate it via:
A. Not complying in step 1, and seeing the other instances shut down.
B. Place some file in /tmp/ and see how it has been removed.
[Where problems could occur]
- Any change whatsoever in program behaviour on Ubuntu Desktop is undesired,
especially if it prevents Ubuntu Desktop from rebooting.
- If the Ubuntu WSL instance that we upgarde from was started without the launcher (e.g via VS code, or with "wsl -d Ubuntu2204LTS"), the shutdown will not happen immediately, but rather be posponed until whichever comes first:
- All instances are closed for around 10 seconds
- A Ubuntu WSL instance started with the launcher is closed.
This could be a bit annoying for the user but it's not fatal.
[Other Info]
- The launcher involvement is needed because WSL doesn't shut down
when all instances of a distro are closed. Rather, it waits for around
ten seconds. The launcher is in charge of forcing this shutdown. The
reboot is automatic when opening a new instance.
- Step 1 in the "Test Plan > New behaviour" part is purely for user-experience, it is unnecessary otherwise. When Ubuntu WSL shuts down, all open instances will show an error message and stop working. We ask users to close other instances:
- To hide the expected error message from them, so as not to worry them.
- To ensure no unsaved work is open in one of the open instances, hence avoiding
data loss.
- A sufficiently new version of the launcher is needed for the forced shutdown to
occur. It is currently only with the Github version, but it'll be part of store
versions from the next release onwards.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-release-upgrader/+bug/1958668/+subscriptions
More information about the foundations-bugs
mailing list