UBIFS power cut issues

Artem Bityutskiy dedekind1 at gmail.com
Wed Sep 9 06:06:34 EDT 2009


On 09/09/2009 12:45 PM, JiSheng Zhang wrote:
>> On Wed, 2009-09-02 at 17:35 +0800, JiSheng Zhang wrote:
>>> If we cut power when copy file into ubifs, then remount ubifs and try
>>> to read the file, we found that the data at some offset of the file
>>> began different from the data of the original file at the same offset.
>>> Is this a bug of ubifs?
>>
>> This is expected behavior on any asynchronous FS. You may switch to
>> synchronous behavior with '-o sync' mount option. I wrote a lot of
>
> I have tested with "mount -o sync", the result is the same. It's not
> empty file. For example:
> cp fileA /mnt/ubifs/fileB
> random cut power before "cp" completed.
> then remount
>  From head of /mnt/ubifs/fileB to some offset offsetC is the same as
> fileA. But from offsetC to the end is different from fileA at the same
> offset offsetC, it's not empty either.
> Hope I expressed myself clearly.

Hmm, ok. What is your kernel version?

Could you please take a closer look and see if these differences
are zeroes or not?

Do you have an automated test for this? Can you share your script?

-- 
Best Regards,
Artem Bityutskiy (Артём Битюцкий)



More information about the linux-mtd mailing list