• Laurent Dufour's avatar
    pstree: bump kernel pid_max value if needed · 42cc04fc
    Laurent Dufour authored
    When restoring on a different node, it may happen that pid_max is
    below one of the pid we wanted to recreate.
    This leads to a restore error when cloning the restarted process:
    
    (00.011172) Forking task with 44794 pid (flags 0x0)
    (00.011205) Error (cr-restore.c:1008): 44794: Write 44793 to sys/kernel/ns_last_pid: Invalid argument
    
    This patch computes the largest pid value and sets the kernel pid_max if
    necessary.
    
    If the user don't have the permission to do so, the restart is
    failing mentioning that we can't push the pid_max limit.
    Signed-off-by: 's avatarLaurent Dufour <ldufour@linux.vnet.ibm.com>
    Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
    42cc04fc
Name
Last commit
Last update
Documentation Loading commit data...
contrib Loading commit data...
coredump Loading commit data...
crit Loading commit data...
criu Loading commit data...
images Loading commit data...
lib Loading commit data...
scripts Loading commit data...
test Loading commit data...
.gitignore Loading commit data...
.mailmap Loading commit data...
.travis.yml Loading commit data...
COPYING Loading commit data...
CREDITS Loading commit data...
INSTALL.md Loading commit data...
Makefile Loading commit data...
Makefile.install Loading commit data...
Makefile.versions Loading commit data...
README.md Loading commit data...