1 |
On 12/03/14 03:15 AM, Yuxuan Shui wrote: |
2 |
> Hi, |
3 |
> |
4 |
> I would like to implement cp --reflink support for ZFSOnLinux as my GSoC |
5 |
> project. |
6 |
> |
7 |
> cp --reflink is used to create a COW copy of a file, so the file will not |
8 |
> take any disk space if it's not modified. This feature is very useful for |
9 |
> cases like storing a lot of almost identical virtual machine images. Also |
10 |
> this is a frequently requested feature for ZoL. [1][2][3] |
11 |
> |
12 |
> Currently only btrfs support this feature, so my goal it to bring it to ZoL |
13 |
> as well. |
14 |
> |
15 |
> I think the only way to do it (without changing too many parts of ZoL) is |
16 |
> to use the deduplication feature of zfs. A COW copy could be done by create |
17 |
> a new entry in ddt for the old file, and create a new file which points to |
18 |
> the ddt entry. |
19 |
> |
20 |
> Please let me know if this proposal makes sense, and if that's the right |
21 |
> way to do it. |
22 |
> |
23 |
> Thanks. |
24 |
> |
25 |
> [1]: |
26 |
> https://groups.google.com/a/zfsonlinux.org/forum/#!topic/zfs-discuss/mvGB7QEpt3w |
27 |
> [2]: https://github.com/zfsonlinux/zfs/issues/405 |
28 |
> [3]: https://github.com/zfsonlinux/zfs/issues/1063 |
29 |
> |
30 |
|
31 |
While I can't comment too much on the technical aspects, they seem to be |
32 |
relatively sound. |
33 |
|
34 |
However, there are some issues with the, er... other aspects, for lack |
35 |
of better terminology. |
36 |
|
37 |
1. This is possibly out of scope as a Gentoo project, since ZOL is not |
38 |
really part of Gentoo. If it's not, then you're out of luck, because ZOL |
39 |
is not an accepted organization. |
40 |
|
41 |
2. This is likely too small to be a GSoC project. Perhaps see [0] for a |
42 |
list of example ideas, if only so you can get a grasp on the size of a |
43 |
good project. |
44 |
|
45 |
It does sound like a good idea though, and even if you can't do it as |
46 |
part of GSoC, you should pursue it anyways. |