1

I'm having problems unlocking an encrypted hard drive that has been working previously for well over a year. I'm sure the password is correct.

I found one post with a similar issue: LUKS encrypted drive will not accept password. Not sure if they ever got it resolved.

I'm running Ubuntu 18.04. The exact error is: Error unlocking /dev/sdc: Failed to activate device: File exists (udisks-error-quark, 0)

Edit: This error appeared regardless of whether the password was entered correctly or not.

Not sure what could have caused this to happen, never had anything like it happen before. Thank you for any help.

4
  • If you have an old disk image, can it be mounted and unencrypted? If so, either erstore it, or salvage what you can from it. Commented Dec 16, 2022 at 2:25
  • You should have backups in any circumstance and with encryption even more so. The slightest error on the drive can result in the whole thing being unreadable, unusable. Commented Dec 16, 2022 at 12:51
  • I don't have a disk image, unfortunately. I do have backups of about half of the data on (unecrypted) optical media. Another thing that's odd is that I have an encrypted DVDR disc with data not on the unencrypted discs that won't open either. I was able to open it when I burned it, and I'm sure the password is correct. Commented Dec 16, 2022 at 16:51
  • Sometimes this happens to me when the last unmount was somehow partial, and fixes itself after reboot. I've not figured out how to fix it without rebooting.
    – Nemo
    Commented Jun 8, 2023 at 13:46

2 Answers 2

1

So I tried to unlock the hard drive again, after reading that sometimes the problem resolves itself, and this time it unlocked without any problems.

I noticed that this time if I entered the wrong password, the error would read: Error unlocking /dev/sdb: Failed to activate device: Operation not permitted (udisks-error-quark, 0)

I'm not sure what could have caused this in the first place but it's resolved, at least for now.

0

In my case this was because I had some shell session (bash) that where still in folders of the previously mounted drive.

That is, say it was mounted on /media/alex/my-disk, I had a shell session still in /media/alex/my-disk/my-folder.

After killing this session, I was able to mount the disk.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .