|
|
Subscribe / Log in / New account

The pernicious USB-stick stall problem

The pernicious USB-stick stall problem

Posted Aug 21, 2021 1:25 UTC (Sat) by pizza (subscriber, #46)
In reply to: The pernicious USB-stick stall problem by xmready
Parent article: The pernicious USB-stick stall problem

> Do I have to become a Linux Dev so I can fix this?

Patches welcome!


to post comments

The pernicious USB-stick stall problem

Posted Jul 12, 2023 19:43 UTC (Wed) by juliano_vs (guest, #166031) [Link]

10 years later, this is still causing headaches for many users
I keep imagining a new user going to linux and facing this problem, having to wait 2 hours to unmount his usb stick 2.0 and having to go out looking for a manual solution on google
In my case i am not a new user but i had this problem and i ended up finding a solution and now i can unmount the pendrive as soon as the copy progress bar ends (just like it is in windows)
correction:
create the file:
/etc/udev/rules.d/60-usb-dirty-pages-udev.rules

with the following content:
ACTION=="add", KERNEL=="sd[a-z]", SUBSYSTEM=="block", ENV{ID_USB_TYPE}=="disk", RUN+="/usr/bin/bash -c 'echo 1 > /sys/block/%k/bdi/strict_limit; echo 16777216 > /sys/block/%k/bdi/max_bytes'"

then restart your machine !

After so many years this should already have a definitive solution in the kernel and not need manual intervention by the user.
It's this kind of thing that keeps new users away from the system


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds