Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm running Ubuntu 10.04 Lucid Lynx and when I write to a USB pen drive, there is no indication that the file(s) have been completely written, even though the copy bar reaches 100% and vanishes, it seems that Linux uses a write ahead buffer to store the file(s) then sends the buffer contents to the pen drive, is there a way to disable USB write ahead so that the data is written on-the-fly?
Put the "sync" option in /etc/fstab, at the line of your USB pen drive
I looked in fstab there is no entry for the usb pen drive, but in the file mtab it does show the drive (/dev/sdb1 /media/Data\040Backup\0402 ext2 rw,nosuid,nodev,uhelper=udisks 0 0), but, the device and mount point changes when different pen drives are inserted, thus adding 'sync' would not work, because the mount point line in mtab would vanish, and defaults return when another pen drive is inserted.
Windoze uses direct write to USB, and in theory Linux should also have that capability, for all USB mass storage devices.
Pen drives auto mount with no problem. Oh well, looks like I'll have to sit and wait and just keep right clicking the drive icon and selecting 'Safely remove device' until it doesn't show the warning, then I can pull out the pen drive, and on some drives I have (16GB) the wait can be as long at 30 minutes after the copy bar as finished and disappeared.
I thought the idea was to plug in a pen drive, write to it, and pull it out, simple?, right?, wrong, with Linux it's a case of, plug in the drive, write to it, wait up to 30 minutes (depending on file size), then pull it out,, but with windoze, plug it in, copy a file, pull it out, done.
A 4GB ISO copied to a 16GB USB 2.0 pen drive, in windoze takes up to 5 minutes or less, the same file in Linux takes 15 minutes or more.
Location: Fleury-les-Aubrais, 120 km south of Paris
Distribution: Devuan, Debian, Mandrake, Freeduc (the one I used to work on), Slackware, MacOS X
Posts: 251
Rep:
Removing pen drive
Whatever the sync option is on any OS, force remove a storage unit is dangerous! When you ask for ejection, the cache will be flushed and the drive unmounted
Suggestion: Open a terminal window and execute the sync command as root. When the shell prompt returns, your USB device should be fully written to. A bit of a pain, but I find it very useful when writing large files to slow USB flash drives
A 4GB ISO copied to a 16GB USB 2.0 pen drive, in windoze takes up to 5 minutes or less, the same file in Linux takes 15 minutes or more.
Windows and linux usb-2.0 run at ~12 MB/S or a little above, in most cases. USB-1.x runs at 1 or 2 MB/S. 15Mins for a 4G iso implies attempts at usb-2.0, and dropping back to 1.0 on errors. Check the drive, and physical connection on the port. USB plugs age like everything else.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.