Fix Ubuntu and other Linux slow/hanging file copying via USB. · GitHub

Copicollage:


If your running a x64 bit Ubuntu or other Linux and find USB transfers hang at the end apply this fix:

echo $((16*1024*1024)) > /proc/sys/vm/dirty_background_bytes
echo $((48*1024*1024)) > /proc/sys/vm/dirty_bytes

I suggest you edit your /etc/rc.local file to make this change persistant across reboots.

sudo nano /etc/rc.local

Go to the bottom of the file and leave a space then paste in those two lines.

Save the file with ctrl + x then press y.

To revert the changes enter this in console and remove the lines in /etc/rc.local

echo 0 > /proc/sys/vm/dirty_background_bytes
echo 0 > /proc/sys/vm/dirty_bytes

More info and references: https://unix.stackexchange.com/questions/107703/why-is-my-pc-freezing-while-im-copying-a-file-to-a-pendrive/107722#107722

❝ 2 commentaires ❞

1  Albirew le

au passage, si t'est pas en su quand tu fait les commandes, il faut alors faire comme ça:


echo $((16*1024*1024)) | sudo tee -a /proc/sys/vm/dirty_background_bytes
echo $((48*1024*1024)) | sudo tee -a /proc/sys/vm/dirty_bytes

pareil pour le revert, on remplace > par | sudo tee -a


bisous~

 
2  Bronco le

Merci pour ta solution et... Pour ta ténacité 😅👍

 

Fil RSS des commentaires de cet article

✍ Écrire un commentaire

les commentaires relevant du SPAM seront filtrés et dégagés direct...

Quelle est le premier caractère du mot 7g8lmh ?
Caching time 0.001813 s