With 99% certainty you are experiencing the effects of THP, Transparent Huge Pages, or rather the defragementation process. The good news is that there is a simply solution (see below)
Background (short and simplified)The problem occurse in all recent kernels that has THP enabled (which most do).
Very simplistic the problem with unresponsive desktop when copying to a slow media (like your standard USB stick) is that the memory buffers will quickly fill up since the memory write to the stick can't keep up (cheap USB sticks only has an effective write rate of 1-3MB/s). This means that lot of buffers are allocated (common configuration is too allow up to 20% of the memory to be used in such write buffers).
When another process, say your browser of the desktop. tries to request more memory the kernel MM tries to find a a new memory page. When THP is eabled the kernel tries to allocate a "huge page" and if that is not possible it tries to compact the used pages to (hopefully) make enouhg consecutive room for a huge page.
The problem now is that in the process of compaction it must do an fsync on the dirty buffers to have them committed to the USB stick (which was there destination). The fsync operation will now take a long time due to the slowness of the USB stick. As a side effect fsync will block a lot of other work, such as desktop or browsers.
So until all buffers are written to the USB stick (which could easily take several minutes for large files) the desktop is in effect unusable. Once the file is written the desktop will become "unlocked" and things canproceed as usual.
SolutionThe way around this for desktop users is to disable the compaction for huge pages. This is done by giving the command (as root)
$> echo madvise > /sys/kernel/mm/transparent_hugepage/defragThis will still leave compaction enabled but it will very rarely be performed. To completely turn it off give the command
$> echo never > /sys/kernel/mm/transparent_hugepage/defragCommentThere are some discussions around this on the kernel mailing list. The problem here is that THP is good thing (and so is the compaction) in many circumstances but copying large files on to slow devices is not one of them.
Hopefully this will see some resolution in fothcoming kernels since at the end of the day this behaviour is not really acceptable since copying large files onto a USB stick on a desktop is not exactly uncommon.
There is also a bug report on the kernel for this behaviour (see
https://bugzilla.kernel.org/show_bug.cgi?id=34132)
There was also an article discussing a related issue in lwn.net not that long ago but I don't have a reference at hand now.