Bug 838237 - ejecting usb drive can corrupt filesystem even when disk utility says "no media" after sync terminates and Gnome doesn't always notify about the sync process.
ejecting usb drive can corrupt filesystem even when disk utility says "no med...
Product: Fedora
Classification: Fedora
Component: gnome-shell (Show other bugs)
x86_64 Linux
unspecified Severity urgent
: ---
: ---
Assigned To: Owen Taylor
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2012-07-07 13:29 EDT by matmenu8
Modified: 2013-08-01 02:48 EDT (History)
5 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2013-08-01 02:48:31 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description matmenu8 2012-07-07 13:29:54 EDT
Description of problem: ejecting usb drive corrupt filesystem (ext3 and Fat32)

Version-Release number of selected component (if applicable):

How reproducible: random but happened twice since 3 weeks, once on Fat32 once on ext3.

Steps to Reproduce:
1.right click on a mounted partition of an usb drive. Click eject.
2. Wait for sync end (check in disk utility because messaging in gnome 3 doesn't work everytime)
3.remove drive from usb port, reconnect it, gnome says drive is read only. Reformating under windows make it work again.
Actual results: filesystem get corrupted and becomes readonly

Expected results: filesystem stays clean. Gnome should write a message "wait until writing to device is completed" and then "you can safely remove your drive xxx". It sometime does show such messages, but most of the time doesn't and you have to check in the disk utility and wait until sync is finished ! Anyway, when disk utility says "no media", it should be safe to remove drive ! Having to check in the disk utility is already annoying, but if it's not safe either... it makes me not trust my system anymore...

Additional info: Googling that problem shows that it is a chronical problem on linux since at least 2006. But it didn't happened to me on Ubuntu 12.04.
Those 2 drives are used at work on many computers using windows, never had a problem. One of them is new. On my personnal computer, no problem on windows either, so it is not coming from the usb ports or other hadware parts.
Comment 1 matmenu8 2012-07-07 13:48:54 EDT
usb drives have both a DDR Memory buffer. Maybe powering the drive off to quick doesn't let the drive sync internally (data's already in the "on drive DDR buffer" but not in flash memory). I'm not sure of that as a friend had the problem with several usb hard drives with different filesystem (ext3, ntfs). Anyway, that should be 100% reliable. I use Windows sever 2003 too since 2004 until today and i never had such a problem.
I'm using USB 2 ports.
Comment 2 matmenu8 2012-07-17 09:47:42 EDT
clicking "safely removal of usb drive xxx" in Windows, doesn't power the usbdrive off (LED always on). So maybe some hardware need to be synced but not completely shut down to ensure all datas are fully written and not only in hardware buffer.
Can't the drive return a signal to say that everything is safe ?
Comment 3 matmenu8 2012-07-26 15:02:56 EDT
happened today again, please fix it fast, data corruption/loss id all but not funny.
Comment 4 matmenu8 2012-07-27 07:45:54 EDT
again today, but without data loss or corruption noticeable. But whatever usb drive was inserted after that, it would be opened read-only. I had to restart the computer to get the other usb drives in write mode. The "corrupted" drive kept to be mounted read-only. Only after a checkdisk on windows was it again possible to get read-write mode on it under linux.
Comment 5 Fedora End Of Life 2013-07-03 21:51:26 EDT
This message is a reminder that Fedora 17 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 17. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '17'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 17's end of life.

Bug Reporter:  Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 17 is end of life. If you 
would still like  to see this bug fixed and are able to reproduce it 
against a later version  of Fedora, you are encouraged  change the 
'version' to a later Fedora version prior to Fedora 17's end of life.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.
Comment 6 Fedora End Of Life 2013-08-01 02:48:36 EDT
Fedora 17 changed to end-of-life (EOL) status on 2013-07-30. Fedora 17 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.

Note You need to log in before you can comment on or make changes to this bug.