Announcement

Collapse
No announcement yet.

Slow copying of files to USB stick

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Slow copying of files to USB stick

    Strictly speaking the copying is not slow, but there is an extra 2-3 minutes of waiting for the Device Notifier acknowledges that the file is indeed finished copying.

    For example, I copy a 350mb file to the stick. Device Notifier shows a reasonably fast progress up until the end. Then Device Notifier shows 350mb/350mb has been copied, but it is still not finished copying. The final notification that copying is finished after showing 350mb/350mb is only displayed a 2 or 3 minutes later.

    Is this a problem with Lucid, with hardware, with KDE, or what? Is there some setting somewhere that can fix this? It is not a major problem but it is annoying.

    tim

    #2
    Re: Slow copying of files to USB stick

    I did find out one thing: this is about copying files to a USB stick. Copying to an USB external drive does not have this problem.

    tim

    Comment


      #3
      Re: Slow copying of files to USB stick

      It is, I believe, a write cache issue. After the write operation has been reported as finished (350mb/350mb has been copied in your example), use the 'eject' button in the Device Notifier "To safely remove this device from the computer." This forces a flush of the write buffer to the device, allowing it to be safely removed, ensuring no lose of any changed data.
      Windows no longer obstructs my view.
      Using Kubuntu Linux since March 23, 2007.
      "It is a capital mistake to theorize before one has data." - Sherlock Holmes

      Comment


        #4
        Re: Slow copying of files to USB stick

        Originally posted by timek718
        I did find out one thing: this is about copying files to a USB stick. Copying to an USB external drive does not have this problem.
        In preparation for doing a fresh install of the 64b LL, I did a backup of my home account to a 320GB USB HD.
        I started at 1 PM and the process finished sometime between 7:30PM the last time I checked it, and 8:30PM, when I noticed it was done. The speed was 2.5 Mb/s, but obviously wasn't constant.
        "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
        – John F. Kennedy, February 26, 1962.

        Comment


          #5
          Re: Slow copying of files to USB stick

          Originally posted by Snowhog
          It is, I believe, a write cache issue. After the write operation has been reported as finished (350mb/350mb has been copied in your example), use the 'eject' button in the Device Notifier "To safely remove this device from the computer." This forces a flush of the write buffer to the device, allowing it to be safely removed, ensuring no lose of any changed data.

          I've tried clicking the eject button, but that didn't seem to make much difference. There was a message that the device was still busy and couldn't be unmounted (or similar) and I still have to wait for it finis writing 0 bytes.

          tim

          Comment


            #6
            Re: Slow copying of files to USB stick

            My USB connections do not have that delay while closing.

            One can open a Konsole and issue;
            sync

            two or three times, then

            sudo umount /dev/sdXn (what ever X and n are for your USB stick)

            A pain, I know, but until your hardware is better supported....

            One could put the sync and umount commands into a bash script that accepts "Xn" as a paramter and umounts it.
            "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
            – John F. Kennedy, February 26, 1962.

            Comment


              #7
              Re: Slow copying of files to USB stick

              From a post on linuxquestions.org:
              Another thing that can kill your usb 2 hard drive performance
              is if the mount is setup to be synchronous. I have
              a large usb 2 disk formatted as an XFS volume. I was
              noticing even rather small files were very slow to
              copy. The drive icon showed that checkbox "synchronous"
              was checked, after putting that off the speed got much
              better.
              Now, I haven't a clue as to how Lucid is processing the mounting of removable media, or where to look to see. But, this sounds 'promising' as a potential to the 'why' question.
              Windows no longer obstructs my view.
              Using Kubuntu Linux since March 23, 2007.
              "It is a capital mistake to theorize before one has data." - Sherlock Holmes

              Comment


                #8
                Re: Slow copying of files to USB stick

                Here is an interesting discussion about the problem, and with several possible solutions.

                Some seem to think it is an xserver and/or KDE/GNOME problem. The next time I backup my system to my USB HD I think I will try booting using the recovery option and from there boot into a console with a network connection. Then manually mount the USB device and use either the cp command or mc (midnight commander).
                "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
                – John F. Kennedy, February 26, 1962.

                Comment


                  #9
                  Re: Slow copying of files to USB stick

                  Originally posted by GreyGeek
                  My USB connections do not have that delay while closing.

                  One can open a Konsole and issue;
                  sync

                  two or three times, then

                  sudo umount /dev/sdXn (what ever X and n are for your USB stick)

                  A pain, I know, but until your hardware is better supported....

                  One could put the sync and umount commands into a bash script that accepts "Xn" as a paramter and umounts it.
                  I did as you suggested, but...

                  sync

                  doesn't finish until the copy operation is finished anyway. It doesn't make a difference. This also means that "sudo umount sdXn" only gives a "device busy" message.

                  Comment


                    #10
                    Re: Slow copying of files to USB stick

                    Originally posted by GreyGeek
                    Here is an interesting discussion about the problem, and with several possible solutions.

                    Some seem to think it is an xserver and/or KDE/GNOME problem. The next time I backup my system to my USB HD I think I will try booting using the recovery option and from there boot into a console with a network connection. Then manually mount the USB device and use either the cp command or mc (midnight commander).
                    The problem discussed on the thread that you referenced is completely different. It is about the write speed. The write speed for copying to USB sticks is fine. It's like the copying finishes but there is a long delay before a signal is given that the write operation has finished. The write speed to my external USB Seagate Expansion hard drive is just fine. The write operation for the Seagate External Drive finishes without any of this business of writing "0 Bytes/sec" for 2-3 minutes.

                    If writing to a USB stick did not have this 2-3 minutes of writing "0 Bytes/sec", I would be completely satisfied with the write speed. Before anyone suggests clicking on the Stop Button on the message for the operation in Device Notifier, it doesn't work. The window closes but the device cannot be unmounted for 2-3 minutes.

                    Comment

                    Working...
                    X