Daniel Schwager wrote:

> we are using nbd in a high storage intensive area - a lot of changes
> are written to nbd-devices AND ndb-client- and nbd-server (@solaris)
> will be created and destroyed on the fly.
> 
> At the moment we have some problems while shutting down a nbd connection
> (client, server) without losing data written to the client-nbd
> but not available on the storage connected to the nbd-server.
> 
> Process:
>       - startup nbd server (@solaris) & client (@linux)
>       - write a lot of data and IMMEDIATELY after

Right here, you have to issue a 'sync' (of fsync the fd in code) to 
guarantee that the data has been sent to the server.

>       - shutdown client (nbd-client -d) and IMMEDIATELY after
>       - shutdown server (yust kill -TERM <pid>
> 
> - Problem
>       - the storage behind the nbd-server is not consistent to the data 
> written
>         from the client site to the nbd-connection    
> 
> I think it could be a caching topic - maybe kblockd has not flushed the
> data ? Or may I'm not allowed to send a TERM to the server ?

Yes, data will remain in the kernel's page cache until it is flushed 
down to the block device. The kernel also periodically flushes data down 
to the devices, if no explicit flush is issued.

--
Paul

------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Nbd-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nbd-general

Reply via email to