[crac] RFR: PID adjustment on checkpoint [v6]
Roman Marchenko
rmarchenko at openjdk.org
Mon Jun 26 16:08:48 UTC 2023
> On restore, there might be PID value conflicts because of small PID values, if it was checkpoint'ed in a container. Therefore, when checkpointing in a container, we need to move PID value for new processes to a particular value to avoid conflicts on restore.
>
> See https://github.com/CRaC/example-lambda/blob/master/checkpoint.cmd.sh#L8 for example.
>
> This PR contains implemented functionality similar to the example above, making this work out of the box. By default, if checkpointing, PID value for new processes starts from 128.
>
> To set a custom value, `CRAC_MIN_PID` environment variable should be used.
> Min `CRAC_MIN_PID` value is 1, max `CRAC_MIN_PID` is not implemented currently.
Roman Marchenko has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains 13 additional commits since the last revision:
- Adapting tests
- Fixing JVM parameter definition
- Set MaxSpinCount to PID value
- Merge branch 'crac' into pid-adjustment
- Removing unnecessary test code
- Implemented vm option instead of env var
- Added test for the last pid overflow while spinning
- Re-worked spin_last_pid procedure
- Re-worked set_last_pid procedure
- Replacing fork() with clone() for Linux platform
- ... and 3 more: https://git.openjdk.org/crac/compare/4ff40b58...67dbf0ed
-------------
Changes:
- all: https://git.openjdk.org/crac/pull/86/files
- new: https://git.openjdk.org/crac/pull/86/files/05afa134..67dbf0ed
Webrevs:
- full: https://webrevs.openjdk.org/?repo=crac&pr=86&range=05
- incr: https://webrevs.openjdk.org/?repo=crac&pr=86&range=04-05
Stats: 1116 lines in 20 files changed: 1074 ins; 8 del; 34 mod
Patch: https://git.openjdk.org/crac/pull/86.diff
Fetch: git fetch https://git.openjdk.org/crac.git pull/86/head:pull/86
PR: https://git.openjdk.org/crac/pull/86
More information about the crac-dev
mailing list