FS#10320 - [truecrypt] "Device busy" when unmounting

Attached to Project: Arch Linux
Opened by Nicolas Bigaouette (big_gie) - Wednesday, 30 April 2008, 12:43 GMT
Last edited by Allan McRae (Allan) - Monday, 25 January 2010, 07:35 GMT
Task Type Bug Report
Category Upstream Bugs
Status Closed
Assigned To Paul Mattal (paul)
Thomas Bächler (brain0)
Architecture All
Severity Low
Priority Normal
Reported Version 2007.08-2
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 3
Private No

Details

Description:
Unable to unmount encrypted files. Truecrypt cries with:
umount: /tmp/.truecrypt_aux_mnt1: device is busy
umount: /tmp/.truecrypt_aux_mnt1: device is busy

See http://bbs.archlinux.org/viewtopic.php?pid=361898#p361898


Additional info:
* package version(s)
5.1a-1
* config and/or log files etc.


Steps to reproduce:
1) Mount an encrypted file or device to a folder with the GUI.
2) Use any way to unmount it after usage ("Dismount" or "Dismount all" from the GUI, or "Dismount /path/to/encrypted/file" from the tray icon)
3) Truecrypt will seems to freeze, a couple of seconds latter a popup with the error shows up.

Note that the encrypted file was created with truecrypt 4.3a.
This task depends upon

Closed by  Allan McRae (Allan)
Monday, 25 January 2010, 07:35 GMT
Reason for closing:  No response
Additional comments about closing:  No responses in 7 months.
Comment by Alessio Bianchi (Venator85) - Wednesday, 30 April 2008, 15:33 GMT
From truecrypt forum:
==========
I suspect a bug in loop devices on some kernels. I've had similar problems
when mounting and unmounting other sorts of things. The sequence I've
found to "manually" unmount a file mounted via truecrypt is:

sync
umount /secure
losetup -d /dev/loop0
umount /tmp/.truecrypt_aux_mnt1
rmdir /tmp/.truecrypt_aux_mnt1

Sometimes, it seems that the losetup -d won't delete the loop to file
association and fails for no obvious reason. Might want to ask in
some appropriate place for your linux distro and find if there is
a known bug.
==========
I tried and it works.
Comment by Nicolas Bigaouette (big_gie) - Wednesday, 30 April 2008, 23:06 GMT
Thanx for the workaround, but it did not worked...

> sudo umount /tmp/.truecrypt_aux_mnt1
umount: /tmp/.truecrypt_aux_mnt1: device is busy
umount: /tmp/.truecrypt_aux_mnt1: device is busy
Comment by Alessio Bianchi (Venator85) - Thursday, 01 May 2008, 09:33 GMT
Nicolas, running _all_ commands with sudo or by root worked for me.
Comment by Nicolas Bigaouette (big_gie) - Thursday, 01 May 2008, 13:10 GMT
yeah of course, its just this one which failed :P All the previous one executed correctly.
Sorry for not having specified this... ;)
Comment by Nicolas Bigaouette (big_gie) - Friday, 09 May 2008, 00:39 GMT
I retried it today and it worked.

Thanx Alessio
Comment by Greg (dolby) - Saturday, 10 May 2008, 09:06 GMT
Do you think its OK to close this then?
Comment by Nicolas Bigaouette (big_gie) - Saturday, 10 May 2008, 18:08 GMT
I would keep it open: this is only a workaround and the problem is not at all resolved...
Comment by Roman (drakosha) - Wednesday, 23 July 2008, 18:01 GMT
Still problematic. I did not check the workaround
Comment by Aleksi Norman (4xolyte) - Monday, 18 August 2008, 11:21 GMT
Probably a bug in the kernel modules loop or fuse...

Still, looking at the script above, this could probably be fixed(worked around) by passing sync(2) before umount(2) in the truecrypt source, or if that doesn't kill it, in effect recreating that script in the unmount code.
Comment by Jeremy Sands (georgia_tech_swagger) - Monday, 01 September 2008, 00:34 GMT
I can confirm this bug. Simply doing, as root: umount /dev/loop/0

Then frees it up and truecrypt's Dismount button will then work.
Comment by Aaron Griffin (phrakture) - Monday, 08 September 2008, 15:45 GMT
I just received this link via email:
http://dpaste.com/hold/75021/

Dunno how relevant it is. Throwing Thomas on here, as I think he knows more about encryption like this than I, and TomK is inactive
Comment by Roman Kyrylych (Romashka) - Tuesday, 09 September 2008, 20:35 GMT
I've got the same link too :)
At first, I didn't get what bug it refers too, but luckily there's a link to this page in that script.
Comment by Stephan Schindel (danvari) - Thursday, 06 November 2008, 12:22 GMT
seems to work with latest truecrypt 6.0a :)
Comment by mutlu inek (mutlu_inek) - Monday, 04 May 2009, 14:06 GMT
This problem has returned for me with truecrypt-6.1a and kernel26-2.6.29.1

The following workaround work for me:

sudo umount /dev/loop/0
Comment by Jeremy Sands (georgia_tech_swagger) - Monday, 04 May 2009, 14:55 GMT
I had to do that the first time, but ONLY the first time. It's working properly now. Go figure.
Comment by Roman Kyrylych (Romashka) - Saturday, 13 June 2009, 09:44 GMT
Status with truecrypt-6.2-2? I also suggest trying rebuid it against kernel26-2.6.30-2 from testing, just to be sure it will still work with it.
Comment by kezar (kezar) - Thursday, 25 June 2009, 09:41 GMT
Same problem with 6.2-1 and 6.2a-1 (even after a rebuild).
Comment by Gerardo Exequiel Pozzi (djgera) - Sunday, 08 November 2009, 23:23 GMT
Any status on this? You can also try with umount -d that acts like losetup -d
Comment by Paul Mattal (paul) - Monday, 09 November 2009, 00:20 GMT
Does this happen for you when you use truecrypt -d to unmount? I don't think you can just umount the filesystem; it seems to do more than just that.
Comment by Laszlo Papp (djszapi) - Sunday, 06 December 2009, 18:53 GMT
Status of it ? Any reponse for the questions ?
Comment by Paul Mattal (paul) - Sunday, 06 December 2009, 18:54 GMT
Let's leave it one more month. Will close in January if no response. I know I use truecrypt daily with truecrypt -d and have no issues.

Loading...