Re: premature umount

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 26 Aug 2021 10:48:15 -0700
Gordon Messmer <gordon.messmer@xxxxxxxxx> wrote:

> On 8/25/21 9:26 PM, Samuel Sieb wrote:
> > You could add a "sync" after the copy and before the "umount".   
> 
> 
> https://utcc.utoronto.ca/~cks/space/blog/unix/TheLegendOfSync
> 
> We're getting into myths and legends territory.  Running sync before 
> umount isn't harmful, but umount will flush any dirty buffers, so it 
> isn't necessary.
> 
> I'm not able to reproduce the problem described, though I'm running 
> Fedora 34.  When I attach a USB drive, it is mounted with the "flush" 
> option.  I can copy arbitrarily large file sets to the drive, and the 
> "cp" command appears to be nearly synchronous.  The sequence "time cp 
> ... ; time umount ..." indicates nearly all of the time spent is in
> the cp command and umount requires between .2 and .3 seconds.
> 
> What are the indications that the copy operation originally reported
> was incomplete?  Does the "umount" command have any flags?  Are there
> any errors in "dmesg" after the script runs?

I was not aware of the mount flush option. Just what was needed. Thanks.

The MP3 files that were being transferred were empty.

The problem emerged only recently on a Fedora 32 system that is
untouched since end-of-life, so its not entirely surprising that its
not reproducible, let alone on 34.

dmesg says
FAT-fs (sdb1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.

That says it all. Pity I never looked.

Again, thanks.
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/users@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux