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

[securedrop-export] device mapper sometimes busy when exporting #1732

Closed
sssoleileraaa opened this issue Feb 24, 2020 · 6 comments
Closed

[securedrop-export] device mapper sometimes busy when exporting #1732

sssoleileraaa opened this issue Feb 24, 2020 · 6 comments
Labels
bug Something isn't working

Comments

@sssoleileraaa
Copy link
Contributor

Description

We've removed the "Export Successful" message from securedrop-export and are getting ready for the client to wait until either no status (meaning success) or a status containing an error message is returned. #666 surfaces a bug where sometimes the client receives an error message device-mapper: remove ioctl on luks-<unique id> failed: Device of resource busy, however the file transfer is successful.

More details

The bullets below indicate that the device is properly being mounted/unmounted locked/unlocked:

@sssoleileraaa sssoleileraaa added the bug Something isn't working label Feb 24, 2020
@sssoleileraaa
Copy link
Contributor Author

Since this is not reproducible we should remove the release blocker tag or just close this issue.

@redshiftzero
Copy link
Contributor

Since we still haven't seen this in QA, I'm going to close this for now, let's reopen if we see again

@rocodes
Copy link
Contributor

rocodes commented Jan 26, 2022

Great(?) news, I have just repro'd this when I was testing scenarios for #1734.

Error msg 1 (can repro almost 100% of the time):
sd_export_already_unlocked_error

STR: insert USB, unlock via Nautilus in sd-devices (I have repro'd with both the "Forget password immediately" option and the "remember for x time" options), navigate to a folder inside the export device (eg a previous export archive) to keep the device busy

sd_devices_unlock_options

Error msg 2 (can repro 100% of the time) if you keep the device busy by e.g. cd ing into the /media/user/device-id-xxxxx directory in an sd-devices terminal
sd_devices_unmount_target_busy

  • The export occurs successfully, but an error message is shown (see attached screenshot)
  • Logs
  • The reason the error shows up here is because the cleanup part of our 'copy submission` method also locks and unmounts the drive, so the user sees an error (with unmounting the drive) even though the export itself succeeded.

@rocodes rocodes reopened this Jan 26, 2022
@rocodes
Copy link
Contributor

rocodes commented Jan 26, 2022

I think a user would have to go out of their way to encounter this issue (i.e. by interacting directly with sd-devices to unlock the device instead of using the export workflow), and I think the fixes are pretty straightforward (such as clearer messaging in the export flow that indicates that the export itself was successful, but there's a problem unmounting the drive, and/or better error-handling as we unmount the drive if we detect that it's in use by another process on sd-devices).

@gonzalo-bulnes
Copy link
Contributor

gonzalo-bulnes commented Oct 13, 2022

I see you've commented on this issue before @rocodes. It seems to me that this scenario would be handled as Status.ERROR_EXPORT_CLEANUP, wouldn't it? (#105)

@zenmonkeykstop zenmonkeykstop changed the title device mapper sometimes busy when exporting [securedrop-export] device mapper sometimes busy when exporting Dec 13, 2023
@zenmonkeykstop zenmonkeykstop transferred this issue from freedomofpress/securedrop-export Dec 13, 2023
@rocodes rocodes mentioned this issue Feb 12, 2024
34 tasks
@rocodes
Copy link
Contributor

rocodes commented Jun 24, 2024

Fixed in #1779, closing

@rocodes rocodes closed this as completed Jun 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants