4
1
I am running a fresh install on Debian 8, and I often have to wait a ridiculous time before my flashdrives get ejected (ranging from 1 to 10.. 15 minutes). During this time, I can't access anything concerning the drive because I get the error An operation is already pending.
It seems like it has nothing to see with the flashdrive format (I've tried FAT, ext4, NTFS), but it also seems to start when I start putting files on them. (nothing heavy though, ~500Mb).
What could be causing this problem? Is there something I can do to speed up ejection?
Short answer: It takes a long time because the USB device is still transferring data you have copied, deleted, moved or is working on and refuse to eject the device until it has finished doing the previous command. – Mogget – 2015-10-16T10:40:34.157
Thanks for this explanation! Do you mean that the files might be still transfering even though I am finished with my copying job when I want to eject? Is it a LIE when the progress bar is over after click+drag or I return to command prompt after
cp
?! ;) – iago-lito – 2015-10-16T10:41:40.6671Exactly! Just because the command you ran (cp, mv, rm or even a copy paste in Windows) and it finishes, doesn't mean that all the actual data has been transferred. It can still be transferring in the background. – Mogget – 2015-10-16T10:45:23.183
Crazy! So if I understand well,
sync
is the only reliable way of being sure that all data has been transfered, because it only returns when the work is done.. Side question: then when docp
returns and when do the gui progress bars reach "100%" ? What are they truly waiting for? – iago-lito – 2015-10-16T10:51:23.287There are probaby other ways to check if the transfer is done or not, but I don't know of one. To be honest I don't know for sure what the OS is using. Maybe someone else on here knows the answer to that. – Mogget – 2015-10-16T10:55:30.950
1
Look at the first answer in this question; It explains some of the things I did not explain well. http://askubuntu.com/questions/122113/copy-to-usb-memory-stick-really-slow
– Mogget – 2015-10-16T11:00:34.363I've actually found one now! Check my edit :) – iago-lito – 2018-04-16T08:18:14.293