Empty commit message header. Please remain the same name across versions, e.g. "Start time of a task inside a container"
On 1/13/20 11:25 AM, Valeriy Vdovin wrote: > This patch addresses the problem of varying views on start time > of a resumed process between container and host. From a container > point of view the resumed process is the same old process with > the same old start time, which hasn't changed after suspend/resume. > From a host point of view the resumed process is just a new one > with a new start_time. Both the host and the container want to > see start time that is only relevant to their context. > > To support that we should teach the output of of /proc/pid/stat > to show container-related value from container context and host- > related value from host context. > > The patch introduces new field to task_struct that stores container- > related start time value. It will be seen in /proc/pid/stat in case > if it was requested by a task, that's in ve cgroup. > Setting this field can be done with prctl only from host or a > container task with pseudosuper flag set. > > At suspend this value is dumped by criu and at restore it's set back > from a dump by criu. > > Valeriy Vdovin (1): > ve/proc: Added separate start time field to task_struct to show in > container > > fs/proc/array.c | 16 ++++------------ > include/linux/sched.h | 5 +++++ > include/uapi/linux/prctl.h | 7 +++++++ > kernel/fork.c | 15 +++++++++++++++ > kernel/sys.c | 23 +++++++++++++++++++++++ > kernel/ve/ve.c | 22 ++++++++++++++++++++++ > 6 files changed, 76 insertions(+), 12 deletions(-) > > (2): > dump/restore: Maintain proper start_time param from > criu/cr-dump.c | 49 ++++++++++++++++++++++++++++++++++++ > criu/cr-restore.c | 68 > ++++++++++++++++++++++++++++++-------------------- > criu/include/crtools.h | 31 +++++++++++++++++++++++ > images/core.proto | 2 ++ > 4 files changed, 123 insertions(+), 27 deletions(-) > -- Best regards, Tikhomirov Pavel Software Developer, Virtuozzo. _______________________________________________ Devel mailing list Devel@openvz.org https://lists.openvz.org/mailman/listinfo/devel