1 |
On Thu, Jun 15, 2017 at 3:37 PM, Mick <michaelkintzios@×××××.com> wrote: |
2 |
> On Thursday 15 Jun 2017 21:40:30 daniel@×××××.nl wrote: |
3 |
>> On Jun 15, 2017 9:28 PM, Mick <michaelkintzios@×××××.com> wrote: |
4 |
> |
5 |
>> This is the first time I heard about discharge damage while unplugging. I |
6 |
>> highly doubt that but for curiosity sake I like some document |
7 |
>> proving/explaining this. |
8 |
> |
9 |
> I'd like one too, but until one appears have a look at what's happening in |
10 |
> this video around 0:46min. |
11 |
> |
12 |
> https://www.youtube.com/watch?v=PdiJWQmSi0k |
13 |
> |
14 |
> The principle is similar. There is current flow and unplugging the conductors |
15 |
> apart causes an arc. Of course the voltages involved are much smaller and so |
16 |
> is the damage. |
17 |
> |
18 |
|
19 |
You're comparing a 500kV breaker at a substation to a USB device? |
20 |
|
21 |
I'm very skeptical of the claim that any electrical effects associated |
22 |
with unplugging a device is going to cause issues with any USB device. |
23 |
They're basically designed to be hot swapped. |
24 |
|
25 |
Now, the filesystem is an entirely different matter - disconnecting a |
26 |
mounted filesystem can cause all kinds of issues. I think this is the |
27 |
most likely issue people are going to run into, and of course you |
28 |
should not have a mounted filesystem when removing a device. Some |
29 |
filesystems are more resilient to this sort of thing than others. |
30 |
|
31 |
I would think that something like a log-based filesystem like f2fs |
32 |
would be pretty impervious to loss of anything but uncommitted data. |
33 |
COW filesystems should also be pretty resilient. Filesystems set to |
34 |
journal data should be fine, but ones that overwrite data in-place |
35 |
might be left in a somewhat inconsistent state. I suspect this |
36 |
applies even when using ordered data mode on something like ext4 (your |
37 |
metadata is going to be fine, but if you were overwriting 15 blocks |
38 |
in-place I'd think that you could end up in a situation where half are |
39 |
updated and half are not). I'd be interested in somebody who knows |
40 |
better on this last point. Ideally you want the failure mode to be |
41 |
that the state of of the disk corresponds to what you would expect at |
42 |
the conclusion of a write system call (maybe not all the calls in the |
43 |
cache, but it should end on a boundary). |
44 |
|
45 |
I'd also buy the argument that some poorly designed USB drives could |
46 |
end up with data loss to something other than the block being |
47 |
immediately written, but honestly I'm skeptical that this is a |
48 |
widespread problem. |
49 |
|
50 |
-- |
51 |
Rich |