On Friday 15 August 2008 02:25, FUJITA Tomonori wrote: > > On Fri, 15 Aug 2008 01:43:55 -0700 > Daniel Phillips <phillips@xxxxxxxxx> wrote: > > > > A daemon program requests delta from the > > > kernel, and sends it to another daemon program on the remote > > > server. The daemon on the remote server asks the kernel to apply > > > delta. > > > > The downstream server just writes the delta to the origin, there is no > > need to ask the kernel to do this. > > > > > The advantage of this approach, the above replication program can work > > > with any snapshot implementation, which could live in dm or file > > > systems like btrfs. File systems could implement the snapshot features > > > more efficiently than dm. > > > > When you replicate a volume you can just send a list of changed blocks > > as ddsnap does. This is not the case with a filesystem delta, which > > has to send the changed blocks of each filesystem object logically, > > along with relevant metadata such as changed permissions, ownership, > > file sizes etc. > > What I think about is... > > User-space replication programs don't know anything about delta. Delta > might be a list of changed blocks, or something more complicated. So > the downstream server can't simply write the delta to the origin. It > always asks the kernel. Just like a volume, there is no real need to ask the kernel to take care of the details of the filesystem layout. Say your delta says "truncate file x to y bytes, change these blocks and move it to directory z". You can do all of that with standard filesystem calls, no need to create a new kernel interface. In general, all the logical elements of a filesystem that are visible to a user should be modifiable by a user. The only special thing the filesystem has to provide is the ability to snapshot. > User-space replication programs don't care about the format of > delta. A file system can give user-space programs whatever as > delta. All a file system needs to do is applying the delta that it > gave to user space. We usually try to do it the opposite way: the kernel knows as little as possible about the format of data it transfers, while userspace knows the rest. In this case usespace already knows everything it needs to know, which is just the Posix filesystem interface. Regards, Daniel -- dm-devel mailing list dm-devel@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/dm-devel