[Bug 222288] g_bio leak after zfs ABD commit

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Wed Sep 13 16:18:04 UTC 2017


Andriy Gapon <avg at FreeBSD.org> changed:

           What    |Removed                     |Added
             Status|New                         |Open
                 CC|                            |freebsd-fs at FreeBSD.org
           Assignee|freebsd-bugs at FreeBSD.org    |avg at FreeBSD.org

--- Comment #1 from Andriy Gapon <avg at FreeBSD.org> ---
(In reply to Dan Nelson from comment #0)
Thank you very much for the report!
As soon as I read it I noticed that I have the same kind of issue.  I dug
through the biozone to examine the leaked bio-s and they all seem to have
bio_cmd = 5 and bio_flags = 8.  So, they seem to be BIO_FLUSH bio-s.  Their
zio-s must have been ZIO_TYPE_IOCTL.

Now, those zio-s use ZIO_IOCTL_PIPELINE and it is defined as:
#define ZIO_IOCTL_PIPELINE                      \
        (ZIO_INTERLOCK_STAGES |                 \
        ZIO_STAGE_VDEV_IO_START |               \

So, ZIO_STAGE_VDEV_IO_START is in the pipeline, but ZIO_STAGE_VDEV_IO_DONE is
not as you have correctly theorised.
The normal I/O pipelines always include ZIO_VDEV_IO_STAGES
#define ZIO_VDEV_IO_STAGES                      \
        (ZIO_STAGE_VDEV_IO_START |              \
        ZIO_STAGE_VDEV_IO_DONE |                \
so the problem does not affect them.

I will double-check why the ioctl pipeline omitted ZIO_STAGE_VDEV_IO_DONE and
will test adding that stage.

You are receiving this mail because:
You are the assignee for the bug.

More information about the freebsd-bugs mailing list