Re: [PATCH 14/39] union-mount: Union mounts documentation

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: J. R. Okajima
Date: Tuesday, August 10, 2010 - 6:51 pm

Neil Brown:
	:::
	:::

DM snapshot provides the COW block feature and it will match your idea
since the size of COW device is much smaller genearally. But it doesn't
support off-line upgrade either. If you do, it is equivalent to corrupt
filesystem for DM snapshot device.

Here is pros/cons of DM snapshot comparing a union.
- the number of bytes to be copied between devices is much smaller.

- the type of filesystem must be one and only.
- the fs must be writable, no readonly fs, even for the lower original
  device. so the compression fs will not be usable. but if we use
  loopback mount, we may address this issue.
  for instance,
	mount /cdrom/squashfs.img /sq
	losetup /sq/ext2.img
	losetup /somewhere/cow
	dmsetup "snapshot /dev/loop0 /dev/loop1 ..."

- it will be difficult (or needs more operations) to extract the
  difference between the original device and COW.

- DM snapshot-merge may help a lot when users try merging. in the
  fs-layer union, users will use rsync(1).

- in fs-based union, users can add/remove members(layer) dynamicall
  without unmounting. of course, all files on the removing layer should
  not be busy.


Also here is my concern about UnionMount. All these issues have been
reported before.
- for users, the inode number may change silently. eg. copy-up.
- link(2) may break by copy-up.
- read(2) may get an obsoleted filedata (fstat(2) too).
- fcntl(F_SETLK) may be broken by copy-up.
- unnecessary copy-up may happen, for example mmap(MAP_PRIVATE) after
  open(O_RDWR).


J. R. Okajima
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH 14/39] union-mount: Union mounts documentation, Valerie Aurora, (Sun Aug 8, 8:52 am)
Re: [PATCH 14/39] union-mount: Union mounts documentation, J. R. Okajima, (Tue Aug 10, 6:51 pm)
Re: [PATCH 14/39] union-mount: Union mounts documentation, Luca Barbieri, (Tue Aug 17, 5:15 pm)
Re: [PATCH 14/39] union-mount: Union mounts documentation, J. R. Okajima, (Tue Aug 17, 6:23 pm)
Re: [PATCH 14/39] union-mount: Union mounts documentation, Valerie Aurora, (Wed Aug 18, 11:55 am)
Re: [PATCH 14/39] union-mount: Union mounts documentation, Valerie Aurora, (Wed Aug 18, 12:04 pm)
Re: [PATCH 14/39] union-mount: Union mounts documentation, J. R. Okajima, (Wed Aug 18, 6:34 pm)
Re: [PATCH 14/39] union-mount: Union mounts documentation, J. R. Okajima, (Mon Aug 23, 7:28 pm)
Re: [PATCH 14/39] union-mount: Union mounts documentation, Valerie Aurora, (Tue Aug 24, 1:48 pm)
Re: [PATCH 14/39] union-mount: Union mounts documentation, Christian Stroetmann, (Tue Aug 24, 7:59 pm)
Re: [PATCH 14/39] union-mount: Union mounts documentation, J. R. Okajima, (Tue Aug 24, 10:03 pm)