If I have to list a single thing that most irritates me on Linux then it is easily copying files to a USB connected drive.
The progress bar passes 100% and I get notification the files were copied but they were in fact not copied yet, it still takes several more minutes until I can actually unplug the connected drive or I’ll lose the files.
Hokei, so. Usb “packets” are 12 bytes or something, and it’s not good for performance to stop the flow. The solution is, as always, to have a buffer. Problem is that some kernel geniuses decided that GIGABYTES is a good buffer size. This was all when spinning hdds were the standard and new fast usbs were comming, but still.
Oh, and for some reason the transfer bar sometimes works fine for me.
If I have to list a single thing that most irritates me on Linux then it is easily copying files to a USB connected drive.
The progress bar passes 100% and I get notification the files were copied but they were in fact not copied yet, it still takes several more minutes until I can actually unplug the connected drive or I’ll lose the files.
Hokei, so. Usb “packets” are 12 bytes or something, and it’s not good for performance to stop the flow. The solution is, as always, to have a buffer. Problem is that some kernel geniuses decided that GIGABYTES is a good buffer size. This was all when spinning hdds were the standard and new fast usbs were comming, but still.
Oh, and for some reason the transfer bar sometimes works fine for me.
I run
udisksctl unmount -b /dev/sdX#
in the terminal. When it completes, it means the files have finished copying and the partition was unmounted.I’ll give that a try next time I’ll need to copy something, thanks
Our just run
sync
, which isn’t as completely foolproof, but is easy.