[Drbd-dev] drbd threads and workqueues: For what is each responsible?
Lars Ellenberg
lars.ellenberg at linbit.com
Mon Sep 26 13:58:38 CEST 2016
On Sun, Sep 25, 2016 at 04:47:49PM -0700, Eric Wheeler wrote:
> Hello all,
>
> Would someone kindly point me at documentation or help me summarize the
> kernel thread and workqueues used by each DRBD resource?
>
> These are the ones I've found, please correct or add to my annotations as
> necessary to get a better understanding of the internal data flow:
>
> drbd_submit (workqueue, device->submit.wq):
> The workqueue that handles new read/write requests from the block layer,
> updates the AL as necessary, sends IO to the peer (or remote-reads if
> diskless). Does this thread write blocklayer-submitted IO to the
> backing device, too, or just metadata writes?
>
>
> drbd_receiver (thread, connection->receiver):
> The connection handling thread. Does this thread do anything besides
> make sure the connection is up and handle cleanup on disconnect?
>
> It looks like drbd_submit_peer_request is called several times from
> drbd_receiver.c, but is any disk IO performed by this thread?
>
>
> drbd_worker (thread, connection->worker):
> The thread that does drbd work which is not directly related to IO
> passed in by the block layer; action based on the work bits from
> device->flags such as:
> do_md_sync, update_on_disk_bitmap, go_diskless, drbd_ldev_destroy, do_start_resync
> Do metadata updates happen through this thread via
> do_md_sync/update_on_disk_bitmap, or are they passed off to another
> thread for writes? Is any blocklayer-submitted IO submitted by this
> thread?
>
>
> drbd_ack_receiver (thread, connection->ack_receiver):
> Thread that receives all ACK types from the peer node.
> Does this thread perform any disk IO? What kind?
>
>
> drbd_ack_sender (workqueue, connection->ack_sender):
> Thread that sends ACKs to the peer node.
> Does this thread perform any disk IO? What kind?
May I ask what you are doing?
It may help if I'm aware of your goals.
--
: Lars Ellenberg
: LINBIT | Keeping the Digital World Running
: DRBD -- Heartbeat -- Corosync -- Pacemaker
: R&D, Integration, Ops, Consulting, Support
DRBD® and LINBIT® are registered trademarks of LINBIT
More information about the drbd-dev
mailing list