How can I watch the progress of the Write Cache when copying to a USB drive on Linux?
Often times, when copying large files to a USB drive, you'll see that the copy has "completed" in the UI, but you can't eject the USB drive yet because it's still "busy". That's because the files aren't actually on the USB drive yet.
Writing to some USB devices, especially drives older than USB 3.0, can be a slow process. In these cases, the files can't be copied in "real time", so they're copied into a temporary buffer area first. Then, once the whole file is in the buffer, it is then "synched" onto the USB drive. In these cases, this is often an invisible, behind-the-scenes process. You can use this command to see what's actually going on in the background:watch "grep -e Dirty: -e Writeback: /proc/meminfo"