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

shutdown: do not try to unmount /target if install was not started #1813

Merged
merged 1 commit into from
Oct 2, 2023

Conversation

ogayot
Copy link
Member

@ogayot ogayot commented Oct 2, 2023

If we ask for reboot before the installation has started (i.e., if curtin install was not invoked at least once), the following call fails and prevents the system from rebooting.

$ umount --recursive /target

Make sure we check that /target exists and is mounted before calling umount.

Another approach would be to check the return value of umount but the values are not documented.

LP #2037539

If we ask for reboot before the installation has started (i.e., if
curtin install was not invoked at least once), the following call fails
and prevents the system from rebooting.

 $ umount --recursive /target

Make sure we check that /target exists and is mounted before calling
umount.

Another approach would be to check the return value of umount but the
values are not documented.

Signed-off-by: Olivier Gayot <[email protected]>
Copy link
Collaborator

@dbungert dbungert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@ogayot ogayot merged commit 143d8e3 into canonical:main Oct 2, 2023
12 checks passed
@ogayot ogayot deleted the target-not-mounted-error branch October 2, 2023 15:45
@ogayot ogayot mentioned this pull request Oct 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants