Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I was getting the usual 4-8mbps in 12.04 when copying files via usb sticks. However after upgrading to 12.10, I only get 200-300kbps when I try to perform the same operation.

I have tried different usb sticks (which work flawlessly on Windows 7) and still experience the same issue. I experienced the same issue sometime ago on 11.10 but everything was normal when I upgraded to 12.04 so it might be a kernel issue.

Here's the output of dmseg |tail:

    mysterio@mysterio-HP-Pavilion-dv6700-Notebook-PC:~$ dmesg |tail 

[  871.023093] sdb: sdb1 
[  871.026909] sd 5:0:0:0: [sdb] No Caching mode page present 
[  871.026920] sd 5:0:0:0: [sdb] Assuming drive cache: write through 
[  871.026927] sd 5:0:0:0: [sdb] Attached SCSI removable disk 
[ 1036.226206] ISO 9660 Extensions: Microsoft Joliet Level 3 
[ 1036.233561] ISO 9660 Extensions: RRIP_1991A 
[ 1086.342973] ISO 9660 Extensions: Microsoft Joliet Level 3 
[ 1086.343010] ISO 9660 Extensions: RRIP_1991A 
[ 1173.971357] ISO 9660 Extensions: Microsoft Joliet Level 3 
[ 1173.971441] ISO 9660 Extensions: RRIP_1991A

I have updated my system with the latest updates. What could be wrong?

share|improve this question
1  
There can be many reasons. Please run "dmesg | tail" in a terminal after plugging the USB drive and post the output. That should give hints if there are driver issues. Also, please tell us what file system is on your pen drive (might for instance be that the memory reserved for the journal of a journaling file system is slowly dieing and therefore performance goes down). –  soulsource Apr 19 '13 at 11:17
    
How is the USB stick formatted? –  Mitch Apr 28 '13 at 10:19

4 Answers 4

up vote 18 down vote accepted
+100

I fear that your problem has no solution. USB slow transfer rates are a phantom in Ubuntu history, that comes and goes away from time to time. It happens because developers in the majority of cases are not able to reproduce this problem and then no solution will be released.

You can see a phenomenon of discussions about USB transfer rates being slow in Ubuntu (and its "cousins"). For example you can see this thread, this discussion and this other thread.

Some say that enabling or disabling Legacy USB Support into the BIOS solves the problem, although it seems as specific rare cases.

There is a bug reported at LaunchPad that presents a workaround for the issue, but as it is somewhat outdated I can't evaluate it's effectiveness nowadays. The workaround is presented by Jean Pierre at Bug #66115 he talks about the workaround in this comment and after in this more detailed comment.

A hot discussion is about the sync mode being enabled when Nautilus mounts a device, although beyond Konqueror (KDE equivalent to Nautilus) I haven't found anyone who got sync option disabled for Nautilus.

Some workarounds of doubtfully effectiveness are discussed in this Super User's Question.

If you got no luck until here I shall tell you that there exists no solution for the problem currently.

There is currently a bug reported in LaunchPad and you can mark it as a problem that affects you. If your hardware differs from the one that is reported from the bug you may add a comment reporting your affected hardware.

share|improve this answer
1  
I feared as much. Anyway since 13.04 is only a couple of days away, the new kernel version should solve it hopefully –  Mysterio Apr 22 '13 at 6:49
3  
Just to remember that there is already a bug report bugs.launchpad.net/ubuntu/+source/linux/+bug/500069 –  desgua Apr 22 '13 at 11:21
    
@desgua Thanks for the link, although I still emphasize the need of a bug report because the problem at Bug #500069 is different from Mysterio problem, his problem is slow transfer rate not system freeze when transferring data, and in the case of USB related problems in most cases fixes that apply to one hardware may not be functional in other, so it is better to create a new bug report. –  Rodrigo Martins Apr 22 '13 at 13:09
2  
@RodrigoMartins The "freezes" in the title is suppose to be funny and to attract attention. The hole title is: "USB file transfer causes system freezes; ops take hours instead of minutes" –  desgua Apr 22 '13 at 17:17
1  
@desgua Sorry for that, my native language is not English and sometimes I don't get the jokes haha –  Rodrigo Martins Apr 23 '13 at 0:22

Well, there are various reasons why USB transfer is slow:

  1. Size of the files being copied. ( the samller the files, the slower it gets)
  2. The speed of the USB stick.
  3. The way the USB stick is formatted.(NTFS, Fat32, or EXT4)

So if the stick is formatted as NTFS keep reading.

NTFS on Linux works a little different to most other filesystem drivers, and so data to be written to an NTFS filesystem actually goes through the CPU. For most filesystems, the CPU doesn't directly deal with the data to be written.

That's why writing to an NTFS formatted stick in Linux is slow, than writing to NTFS on Windows. So you could format your USB stick as Ext4 (Linux-only) or fat32 works both ways, but has a 4 GiB file size limitation.

share|improve this answer
    
I have similar slowness/freezes (even mouse stops working), now I have tried Ext4, and I still have that problem (ubuntu 14). –  bartosz.r Sep 5 at 19:16

Despite the pessimism of Rodrigo's very thorough answer, I suspect the majority of these cases are simply due to the default behaviour of usbmount or equivalent hotplug handlers to force writing to disk instead of caching. You should check whether sync is enabled for the device, e.g, by looking for the corresponding line from cat /proc/mounts. It may look something like:

/dev/sdb1 /media/usb0 fuseblk,sync,rw,nosuid,nodev,noexec,noatime,user_id=0,group_id=0,allow_other,blksize=4096 0 0

Note the sync flag. You need to prevent this from being set. If you mount manually you should change the fstab entry as in this answer. If it's automounted have a look in the output from tail /var/log/syslog just after plugging in and look for a line like:

Jul 21 19:28:51 my-machine usbmount[3823]: executing command: mount -tntfs -sync,onoexec,nodev,noatime,nodiratime /dev/sdb1 /media/usb0

If it is being mounted by usbmount you can follow my advice in another answer and change the MOUNTOPTIONS line in /etc/usbmount/usbmount.conf from:

MOUNTOPTIONS="sync,noexec,nodev,noatime,nodiratime"

to

MOUNTOPTIONS="noexec,nodev,noatime,nodiratime"
share|improve this answer

I don't know if this will help anyone else but it's what worked for me when I had problems with really slow transfer speeds using Ubuntu 13.04 (speeds of 1mb/s or less). Anyway I restarted my computer with my USB hdd plugged into the USB port right before Ubuntu started up it ran some script on the black screen just before it loads and after that my transfer speeds have been really good on the low end 24mb/s.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.