[Drbd-dev] Re: DRBD-filesystem interaction
Lars Ellenberg
Lars.Ellenberg at linbit.com
Fri Aug 25 07:57:22 CEST 2006
/ 2006-08-24 14:25:13 -0400
\ gniv at cs.umass.edu:
> Hi,
>
> I am a student who is looking to understand how DRBD interacts with
> the file system for a project.
it does not. the file system interacts with us...
we are a block device, we don't know nothing about file systems.
"something" submits a block request (generic_make_request, submit_bio
and the like in the generic kernel code), which ends up in
drbd_make_request_*, where we do the housekeeping and send the data to
our peer, and submit it locally to the layers below us and so on.
but we don't care at all about what is being written,
and whether it is a file system or anything else that is writing to us.
> I have looked through the code, but could use some help (maybe a basic
> overview) figuring out the flow of operations from the time the
> operating system opens a file and writes to it, to DRBD performing
> replication; i.e. how DRBD listens to/intercepts system calls.
it does not.
we are a block device driver, we register as such (register_blkdev).
any block device has a request queue, and we register our custom
make_request_fn on it: blk_queue_make_request(q, drbd_make_request_26);
that is all there is to it to get requests delivered to us.
--
: Lars Ellenberg Tel +43-1-8178292-55 :
: LINBIT Information Technologies GmbH Fax +43-1-8178292-82 :
: Schoenbrunner Str. 244, A-1120 Vienna/Europe http://www.linbit.com :
More information about the drbd-dev
mailing list