Re: Invalidating the pages read from a disk which md marks as faulty later

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

 



Hi,

one issue that I hit, although not with md, is that Linux page cache
is capable of caching error'ed pages too. So even after the underlying
device recovers, the page cache keeps returning EIO for some time,
until it re-reads the page. To resolve this, it is either required to
close all open fds (opened with filp_open) or to issue
ioctl(BLKFLSBUF) to the file.

Perhaps that is what is meant here. Although I don't think md uses
Linux page cache to work with its components.

Alex.


On Wed, Jan 18, 2012 at 10:19 PM, NeilBrown <neilb@xxxxxxx> wrote:
> On Wed, 18 Jan 2012 20:11:38 +0530 Krishnakumar R
> <krishnakumar.kernel@xxxxxxxxx> wrote:
>
>> Hi,
>>
>> Does md invalidate the pages in the page cache for data read (earlier) from
>> the disk, which md finds faulty, lets say due to an I/O error ?
>> The assumption here is that since md found a disk to be faulty, the data
>> which was earlier read and cached can be considered invalid. Thoughts ?
>> I would assume that the pages would be backed by md device, hence is it
>> possible to figure out which pages were given out with data from an
>> underlying disk inorder to invalidate them ?
>>
>>
>
> Sorry, but this doesn't make any sense.
>
> When you read from a disk, the disk drive itself does a CRC check to confirm
> the data is valid.  It if isn't you don't get to see the data.  If it is, why
> would you want to invalidate it?
>
> If a device is "Faulty", that doesn't mean it has corrupted data.  It means
> it has inaccessible on unchangeable data.
>
> Though I might have  misunderstood you.  If you think I have, please give a
> more detailed scenario of the situation that should be handled differently.
>
> In any case, once md has returned the data to the caller there is nothing it
> can do to "invalidate" it.
>
> NeilBrown
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux