David Chinner wrote: > What I don't understand is that on unmount dirty xfs inodes get > written out. Clearly this is not happening - either there's a hole > in the writeback logic (unlikely - it was unchanged) or we've missed > some case where we need to update the filesize and mark the inode > dirty. > > Hmmmm - if the write was just a short append to the file, then the > block that was written to should already be mapped. Then we'll just > look up the extent by doing a BMAPI_READ lookup, set the type to > IOMAP_READ and add the block to ioend we are building. > Well, that result I mailed you showed that the difference was just over 16k, and that there was a 32 block difference in the final extent length. Does that fit with this theory? > The type IOMAP_READ determines the I/O completion behaviour - in this case > it is xfs_end_bio_read(), which fails to update the file size.... > > Bingo. > > A patch for you to try, Jeremy. I've just started a test run on it... > Thanks, I'll give it a spin. Have you reproduced the bug yourself? J - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
- Follow-Ups:
- References:
- 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: Jeremy Fitzhardinge <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: David Chinner <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: Jeremy Fitzhardinge <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: David Chinner <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: Jeremy Fitzhardinge <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: Chuck Ebbert <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: Jeremy Fitzhardinge <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: Chuck Ebbert <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: Jeremy Fitzhardinge <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: Jan Engelhardt <[email protected]>
- Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- From: David Chinner <[email protected]>
- 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- Prev by Date: clockevent questions
- Next by Date: migrate_dead_tasks() vs sleep-after-exit_notify() problems?
- Previous by thread: Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- Next by thread: Re: 2.6.21-git10/11: files getting truncated on xfs? or maybe an nlink problem?
- Index(es):