7

Every time I send files (almost 1-2GB movies) to my parents' pendrives I'm about to fall asleep. It's not pendrives fault because the other Windows laptop transfers at a fair USB 2.0 speed...

I always send them through Nautilus: from 0 to 100 in seconds, then it gets stuck and remains for about 5-10 minutes, when it finally completes. It never occurs when I'm using 3.0 devices, speed is ok.

I really think that's Nautilus fault, maybe connected to my architecture, I don't know, but that's really frustrating. Is there something I can do?

EDIT: I just tried sending the same file through Nautilus and then with cp /source-path/source-file /dest-part/dest-file as suggested by @Bob91 and I found that it seems to take the same time to transfer 1.5GB (~4-5 minutes), so we can exclude Nautilus.

EDIT 2: @sudodus You turned on my light bulb, so I did a benchmark in both laptops (Windows vs Ubuntu): I tested my parents' Sony & Sandisk 2.0, my old Sony 3.0 and my WD external HDD and result in write speed surprised me: we have about 4-5MB/s for the 2.0 drives, a sad 7MB/s for my old Sony 3.0 and a good 68-70MB/s for my external HDD.

According to @vidarlo:

The reason it show a quick progress is memory caching. The file is only written at the end of the copy process, which tricks the UI into believing that copying is further along than it actually is.

Thanks everyone. I'm going to buy decent pendrives for my parents' birthday

Zanna
  • 70,465
np_3ka
  • 544
  • 3
  • 6
  • 22

3 Answers3

4

It's probably crappy USB drive. Cheap USB drives have a write speed of <15MB/s, some as low as 1-2MB/s. Want faster? Buy an more expensive one.

10 minutes for 2GB works out to approx. 3.3MB/s, which is reasonable for a cheap drive.

The reason it show a quick progress is memory caching. The file is only written at the end of the copy process, which tricks the UI into believing that copying is further along than it actually is.

(As a sidenote: I've even seen drives advertised as USB 3.0... and 5MB/s write speed!)

vidarlo
  • 22,691
  • 1
    Well, I wrote that on Windows speed is completely different with the same pendrives, like 1 minute vs 10 minutes. So I don't think it's pendrive (every damn 2.0 pendrive) fault... – np_3ka Jan 09 '19 at 17:23
  • Is your Windows on the same laptop? If not how can it be compared. May be some hardware or driver problem. – Vijay Jan 09 '19 at 17:31
  • 1
    @Vijay Nope, it's my parents' laptop, with low specs compared to mine. I struggle to believe that their old and cheap laptop can trasfer at a higher speed than mine... Also, I had Windows here, I didn't have transfer speed problems. – np_3ka Jan 09 '19 at 17:35
  • @nplezka, Are you sure that Windows reports when it has flushed the buffers? My experience is that many USB pendrives are very slow, but you can get much faster USB 3 pendrives, when you know which ones to select. See this link and links from it, help.ubuntu.com/.../FromUSBStick#Notes_about_speed. After using a pendrive for some time, it becomes slower, and you can make it fast again by writing zeros to the whole drive. – sudodus Jan 09 '19 at 19:47
  • 1
    @sudodus you turned on my light bulb, so I did a benchmark in both laptops: – np_3ka Jan 09 '19 at 20:40
  • And what's the result of your benchmark, @nplezka? – sudodus Jan 09 '19 at 20:42
  • vidarlo and @Vijay, I never had that problem using any Windows in any machine. I used Windows in exactly the same PC that I use Ubuntu and never had that problem. This should be a basic and straightforward feature and users should not have to worry about that at all. – Thiago Jul 06 '19 at 18:02
  • @Thiago have you verified that windows does not cache writes? And what feature are you asking about? Caching makes sense in some scenarios, on others not. It's not entirely clear what problem you've never had with windows either. – vidarlo Jul 06 '19 at 21:52
  • @vidarlo the feature is: OS allows users to transfer a large file to a pen drive. Sincerely I do not know if windows cache writes, I just don't have to worry about that. As I said before, it should be a straightforward feature. – Thiago Aug 19 '19 at 22:26
  • There are algorithms for that kind of problem, the OS should transfer using the highest possible speed, considering possible bottlenecks. – Thiago Aug 19 '19 at 22:29
  • @Thiago Which algorithms? Usually you don't have multipath to a USB drive, so there's really nothing the OS can do about bottlenecks. And with cheap USB drives, the bottleneck is always the drive itself. – vidarlo Aug 20 '19 at 05:09
  • Does anyone have any idea why the UI has this issue where the displayed progress is further along than has actually been written to the drive? I remember this issue from years ago, and frankly I'm surprised that it hasn't been fixed yet. – Liam Baker Dec 30 '19 at 16:58
3

try to copy files from the command line to know if nautilus faults

cp /source-path/source-file /dest-part/dest-file
Bob91
  • 1,172
0

I had this problem for years with all kind of usb sticks (no matter 2.0 or 3.0), formatted as fat32 (mostly), but sometimes also ntfs.

After trying to improve Mac access to my Linux sticks I have started using exFAT format, and now I see what I consider normal speed (like in Windows, without a lag at 99% etc).

cipricus
  • 3,444
  • 2
  • 34
  • 85