Skip to contentSkip to conversation

USB mass storage unplug problem

DISCUSSION Lalso Benarik 2 participants 2 messages Aug 24, 2005

lore
Share & tools
lore
#0 lore raw

We are developing application for coping of the content of the USB mass storage for it we are using Fedora Core 3.
During the testing we have experienced the following problem:
- start coping data from the device (it is the same if you copy the data to the device) to hard disk: cp /media/CopyDisk/* /copydir/
- during copy process remove the USB flash.
- After it, the Linux doesn't see any more USB mass storage devices, and usually the process that was doing the coping is active, and can not be killed.
The same happens if I make a C code doing the coping.
Does any one know ho to deal with it? I need error reported to my application.
The same problem occurs with the Fedora Core 4.

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel

#1 lore raw
Quoted 5 lines · Lalso Benarik

We are developing application for coping of the content of the USB mass storage for it we are using Fedora Core 3.
During the testing we have experienced the following problem:
- start coping data from the device (it is the same if you copy the data to the device) to hard disk: cp /media/CopyDisk/* /copydir/

Quoted 8 lines

- during copy process remove the USB flash.
- After it, the Linux doesn't see any more USB mass storage devices, and usually the process that was doing the coping is active, and can not be killed.
The same happens if I make a C code doing the coping.
Does any one know ho to deal with it? I need error reported to my application.
The same problem occurs with the Fedora Core 4.

It's likely a kernel bug in the SCSI layer that does not cleanup the error handler. I think it was fixed with one of the later kernels:
http://marc.theaimsgroup.com/?l=linux-scsi&m1172700500878&w=2

But it may be another problem, if you still can reproduce it with the latest kernel.

Kay

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel