Difference between revisions of "Mount-v2"

From CRIU
Jump to navigation Jump to search
(Mount-v2 CRIU algorithm which uses new MOVE_MOUNT_SET_GROUP kernel feature)
 
Line 12: Line 12:
 
* "Cross-namespace" sharing groups creation need to be ordered with mount namespace creation right.
 
* "Cross-namespace" sharing groups creation need to be ordered with mount namespace creation right.
 
* Sharing groups vs mount tree order inversion can be very complex to restore and require multiple auxiliary. (see example below)
 
* Sharing groups vs mount tree order inversion can be very complex to restore and require multiple auxiliary. (see example below)
[[File:Mounts-inverse-order-example.gif|none|Mounts-inverse-order-example.gif]]
+
 
 +
See my talks about it on Linux Plumbers Conference:
 +
* [https://www.linuxplumbersconf.org/event/7/contributions/640/ CRIU mounts migration: problems and solutions]
 +
* [https://linuxplumbersconf.org/event/11/contributions/923/ Mount-v2 CRIU migration engine: status update]
 +
 
 +
And here is the example of order inversion where multiple temporary mounts needed to achieve the result:
 +
[[File:Mounts-inverse-order-example.gif|none|link=|Mounts-inverse-order-example.gif]]
  
 
to be continued...
 
to be continued...

Revision as of 07:09, 26 January 2022

Mount-v2 CRIU algorithm

After we've merged MOVE_MOUNT_SET_GROUP feature to mainstream linux v5.15 torvalds/linux@9ffb14e now we can use it to restore sharing groups of mounts without the need to care about inheriting those groups when create mounts, we can just set sharing groups at later stage and before that construct mount trees with private mounts.

Restoring propagation right with conservative approach of both creating mounts and inheriting propagation groups looks like mission impossible task for us due to many problems:

  • Criu knows nothing about the initial history or order of mount tree creation;
  • Propagation can create tons of mounts;
  • Propagation may change parent mounts for existing mount tree;
  • "Mount trap" - propagation may cover initial mount;
  • "Non-uniform" propagation - there are different tricks with mount order and temporary children-"lock" mounts, which create mount trees which can't be restored without those tricks.
  • "Cross-namespace" sharing groups creation need to be ordered with mount namespace creation right.
  • Sharing groups vs mount tree order inversion can be very complex to restore and require multiple auxiliary. (see example below)

See my talks about it on Linux Plumbers Conference:

And here is the example of order inversion where multiple temporary mounts needed to achieve the result:

Mounts-inverse-order-example.gif

to be continued...