checkpoint-restore / criu

Checkpoint/Restore tool
criu.org
Other
2.79k stars 565 forks source link

criu: Add pidfd support #2259

Open h0lyalg0rithm opened 10 months ago

h0lyalg0rithm commented 10 months ago
codecov-commenter commented 10 months ago

Codecov Report

Patch coverage: 8.16% and project coverage change: -0.17% :warning:

Comparison is base (82bfb67) 70.67% compared to head (07b717f) 70.50%.

:exclamation: Current head 07b717f differs from pull request most recent head 9b0a7ce. Consider uploading reports for the commit 9b0a7ce to get more accurate results

Additional details and impacted files ```diff @@ Coverage Diff @@ ## criu-dev #2259 +/- ## ============================================ - Coverage 70.67% 70.50% -0.17% ============================================ Files 133 135 +2 Lines 33330 33379 +49 ============================================ - Hits 23556 23534 -22 - Misses 9774 9845 +71 ``` | [Files Changed](https://app.codecov.io/gh/checkpoint-restore/criu/pull/2259?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=checkpoint-restore) | Coverage Δ | | |---|---|---| | [criu/cr-restore.c](https://app.codecov.io/gh/checkpoint-restore/criu/pull/2259?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=checkpoint-restore#diff-Y3JpdS9jci1yZXN0b3JlLmM=) | `67.38% <ø> (-0.19%)` | :arrow_down: | | [criu/files.c](https://app.codecov.io/gh/checkpoint-restore/criu/pull/2259?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=checkpoint-restore#diff-Y3JpdS9maWxlcy5j) | `80.45% <0.00%> (-0.39%)` | :arrow_down: | | [criu/include/pidfd.h](https://app.codecov.io/gh/checkpoint-restore/criu/pull/2259?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=checkpoint-restore#diff-Y3JpdS9pbmNsdWRlL3BpZGZkLmg=) | `0.00% <0.00%> (ø)` | | | [criu/pidfd.c](https://app.codecov.io/gh/checkpoint-restore/criu/pull/2259?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=checkpoint-restore#diff-Y3JpdS9waWRmZC5j) | `0.00% <0.00%> (ø)` | | | [criu/proc\_parse.c](https://app.codecov.io/gh/checkpoint-restore/criu/pull/2259?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=checkpoint-restore#diff-Y3JpdS9wcm9jX3BhcnNlLmM=) | `67.96% <7.14%> (-0.58%)` | :arrow_down: | | [criu/image.c](https://app.codecov.io/gh/checkpoint-restore/criu/pull/2259?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=checkpoint-restore#diff-Y3JpdS9pbWFnZS5j) | `71.58% <100.00%> (+0.15%)` | :arrow_up: | ... and [6 files with indirect coverage changes](https://app.codecov.io/gh/checkpoint-restore/criu/pull/2259/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=checkpoint-restore)

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

warusadura commented 10 months ago

@h0lyalg0rithm Is it ok, if I write the zdtm test for this?

h0lyalg0rithm commented 10 months ago

@warusadura There is one bug that is to be fixed.Currently the patch lets you dump pidfd for processes which are not part of the current process tree.

I have the test prepared where I fork the test and have pidfd on the child process. But once you try to restore the process it fails as the child process is not created yet. One way to get around this is to wait until all the whole process tree is restored and then restore the pidfd.

I cannot think about any thing which doesnt sound hacky. What do you think?

warusadura commented 10 months ago

I cannot think about any thing which doesnt sound hacky. What do you think?

sorry @h0lyalg0rithm I'm not sure :)

github-actions[bot] commented 8 months ago

A friendly reminder that this PR had no activity for 30 days.