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

Re: [Nbd] NBD, DISCARD/TRIM



On Thu, Mar 21, 2013 at 2:12 PM, Paul Clements
<paul.clements@...856...> wrote:
> On Tue, Mar 19, 2013 at 2:06 PM, folkert <folkert@...421...> wrote:
>>> > > Am I right that discard/trim is in kernel 3.9? Or is it already in 3.8?
>>> > Patch was merged into Linus's tree on 5Oct12, so it should have made 3.7.
>>>
>>> There are problems with it, it seems.
>
> Doesn't seem to be anything related to trim/discard. Does your kernel
> have the kill_bdev calls in nbd? Look for:

I had suspected the kill_bdev patch, as it's the only thing of any
significance that has changed recently related to nbd shutdown, but it
seems that this is something that has just broken in ext3/ext4. Even
with kill_bdev calls removed, I still see BUGs (I think the same one
you reported [mine is fs/buffer.c:2958]) and NULL ptr derefs in jbd
when I abort the nbd connection with a mounted filesystem.

Do you know or can you (or anyone else) check when this started?

I see it here with 3.9.0-rc1, but not with 3.0.13ish. Basically the
test is to mount nbd, then kill the server or client process, then do
some I/O, then unmount. It's normal to see I/O errors and the
filesystem will complain that it couldn't commit the journal, but NULL
ptrs and BUGs should not be occurring.


As for what is causing your client to stop in the first place, I'm not
sure. How do you have the FS mounted? Are you testing discard, i.e.,
you have the option enabled in the nbd-server?



Reply to: