The 'from' and 'len' field of struct 
nbd_request tell us the block number
and data length of what data is being transferred, right?

Here are my questions:

1. Does the block number given by 'from' refer to the 
block number in the
    disk image file on remote server, not in 
local main memory?

2. If the answer of question 1 is positive, 
where do those data (data blocks
    from 
$from to $from + $len in remote disk image file) go when the 
request
    type is 'read'? Where are they saved? In local main 
memory? Or on local disk?
    How can I get them and save them in 
some other place specified by myself?

3. In kernel source file 
nbd.c, the function sock_xmit() is used to send or receive
    
packet. There is a variable named 'iov' which contains 'void *iov_base' 
and
    'size_t iov_len'. Whatever read or write, 'iov' is always 
used. Is it used to
    represent a segment (or a data block) in 
local main memory? What does it mean
    when the request type is 
read or write respectively?

Thanks a lot!
------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Nbd-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nbd-general

Reply via email to