[crac] RFR: Support extra criu flags from the environment

Volker Simonis simonis at openjdk.org
Wed Jun 29 13:06:39 UTC 2022


When testing with different `criu` versions or `criu` configurations it might be useful to be able to modify the default  `criu` command line parameters. This PR introduces the new environment variable `CRAC_CRIU_OPTS` which will be interpreted as a space separated list of `criu` flags to be appended to the hard-coded list of command line parameters. E.g.


$ CRAC_CRIU_OPTS="-v4 -o resume.log -W /tmp/crac" java -XX:CRaCRestoreFrom=/tmp/crac


This will set the logging level to 4 (thus overriding the hard-coded logging level of 1 for resuming), redirect the log to the file `resume.log` and change `criu`'s working directory (which will contain the log file) to `/tmp/crac`.

-------------

Commit messages:
 - Support extra criu flags from the environment

Changes: https://git.openjdk.org/crac/pull/26/files
 Webrev: https://webrevs.openjdk.org/?repo=crac&pr=26&range=00
  Stats: 39 lines in 1 file changed: 28 ins; 7 del; 4 mod
  Patch: https://git.openjdk.org/crac/pull/26.diff
  Fetch: git fetch https://git.openjdk.org/crac pull/26/head:pull/26

PR: https://git.openjdk.org/crac/pull/26


More information about the crac-dev mailing list