Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
criu
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhul
criu
Commits
f466f811
Commit
f466f811
authored
Mar 17, 2023
by
zhul
🌵
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
去除代码中 criu 相关内容
parent
1859290d
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
24 additions
and
16 deletions
+24
-16
criu.txt
Documentation/criu.txt
+0
-0
Makefile
Makefile
+1
-1
Makefile.install
Makefile.install
+1
-1
crtools.c
criu/arch/x86/crtools.c
+4
-0
crtools.c
criu/crtools.c
+17
-13
cr_options.h
criu/include/cr_options.h
+1
-1
No files found.
Documentation/criu.txt
View file @
f466f811
This diff is collapsed.
Click to expand it.
Makefile
View file @
f466f811
...
@@ -122,7 +122,7 @@ ifeq ($(GMON),1)
...
@@ -122,7 +122,7 @@ ifeq ($(GMON),1)
export
GMON
GMONLDOPT
export
GMON
GMONLDOPT
endif
endif
CFLAGS
+=
$(USERCFLAGS)
$(WARNINGS)
$(DEFINES)
-iquote
include/
CFLAGS
+=
$(USERCFLAGS)
$(WARNINGS)
$(DEFINES)
-iquote
include/
-w
HOSTCFLAGS
+=
$(WARNINGS)
$(DEFINES)
-iquote
include/
HOSTCFLAGS
+=
$(WARNINGS)
$(DEFINES)
-iquote
include/
export
CFLAGS
USERCLFAGS
HOSTCFLAGS
export
CFLAGS
USERCLFAGS
HOSTCFLAGS
...
...
Makefile.install
View file @
f466f811
...
@@ -29,7 +29,7 @@ export PREFIX BINDIR SBINDIR MANDIR RUNDIR
...
@@ -29,7 +29,7 @@ export PREFIX BINDIR SBINDIR MANDIR RUNDIR
export
LIBDIR
INCLUDEDIR
LIBEXECDIR
export
LIBDIR
INCLUDEDIR
LIBEXECDIR
install-man
:
install-man
:
$(Q)
$(MAKE)
-C
Documentation
install
#
$(Q)
$(MAKE)
-C
Documentation
install
.PHONY
:
install-man
.PHONY
:
install-man
install-lib
:
lib
install-lib
:
lib
...
...
criu/arch/x86/crtools.c
View file @
f466f811
...
@@ -9,6 +9,7 @@
...
@@ -9,6 +9,7 @@
#include "types.h"
#include "types.h"
#include "asm/compat.h"
#include "asm/compat.h"
#include <stdlib.h>
#undef LOG_PREFIX
#undef LOG_PREFIX
#define LOG_PREFIX "x86: "
#define LOG_PREFIX "x86: "
...
@@ -16,6 +17,9 @@
...
@@ -16,6 +17,9 @@
#define XSAVE_PB_NELEMS(__s, __obj, __member) \
#define XSAVE_PB_NELEMS(__s, __obj, __member) \
(sizeof(__s) / sizeof(*(__obj)->__member))
(sizeof(__s) / sizeof(*(__obj)->__member))
char
*
rpc_cfg_file
=
NULL
;
int
save_task_regs
(
void
*
x
,
user_regs_struct_t
*
regs
,
user_fpregs_struct_t
*
fpregs
)
int
save_task_regs
(
void
*
x
,
user_regs_struct_t
*
regs
,
user_fpregs_struct_t
*
fpregs
)
{
{
CoreEntry
*
core
=
x
;
CoreEntry
*
core
=
x
;
...
...
criu/crtools.c
View file @
f466f811
...
@@ -204,7 +204,7 @@ int main(int argc, char *argv[], char *envp[])
...
@@ -204,7 +204,7 @@ int main(int argc, char *argv[], char *envp[])
if
(
!
strcmp
(
argv
[
optind
],
"restore"
))
{
if
(
!
strcmp
(
argv
[
optind
],
"restore"
))
{
if
(
opts
.
tree_id
)
if
(
opts
.
tree_id
)
pr_warn
(
"Using -t with cr
iu
restore is obsoleted
\n
"
);
pr_warn
(
"Using -t with cr
bk
restore is obsoleted
\n
"
);
ret
=
cr_restore_tasks
();
ret
=
cr_restore_tasks
();
if
(
ret
==
0
&&
opts
.
exec_cmd
)
{
if
(
ret
==
0
&&
opts
.
exec_cmd
)
{
...
@@ -256,15 +256,19 @@ int main(int argc, char *argv[], char *envp[])
...
@@ -256,15 +256,19 @@ int main(int argc, char *argv[], char *envp[])
pr_msg
(
"Error: unknown command: %s
\n
"
,
argv
[
optind
]);
pr_msg
(
"Error: unknown command: %s
\n
"
,
argv
[
optind
]);
usage:
usage:
if
(
usage_error
)
{
return
1
;
}
return
0
;
pr_msg
(
"
\n
"
pr_msg
(
"
\n
"
"Usage:
\n
"
"Usage:
\n
"
" cr
iu
dump|pre-dump -t PID [<options>]
\n
"
" cr
bk
dump|pre-dump -t PID [<options>]
\n
"
" cr
iu
restore [<options>]
\n
"
" cr
bk
restore [<options>]
\n
"
" cr
iu
check [--feature FEAT]
\n
"
" cr
bk
check [--feature FEAT]
\n
"
" cr
iu
page-server
\n
"
" cr
bk
page-server
\n
"
" cr
iu
service [<options>]
\n
"
" cr
bk
service [<options>]
\n
"
" cr
iu
dedup
\n
"
" cr
bk
dedup
\n
"
" cr
iu
lazy-pages -D DIR [<options>]
\n
"
" cr
bk
lazy-pages -D DIR [<options>]
\n
"
"
\n
"
"
\n
"
"Commands:
\n
"
"Commands:
\n
"
" dump checkpoint a process/tree identified by pid
\n
"
" dump checkpoint a process/tree identified by pid
\n
"
...
@@ -309,8 +313,8 @@ usage:
...
@@ -309,8 +313,8 @@ usage:
" --freeze-cgroup use cgroup freezer to collect processes
\n
"
" --freeze-cgroup use cgroup freezer to collect processes
\n
"
" --weak-sysctls skip restoring sysctls that are not available
\n
"
" --weak-sysctls skip restoring sysctls that are not available
\n
"
" --lazy-pages restore pages on demand
\n
"
" --lazy-pages restore pages on demand
\n
"
" this requires running a second instance of cr
iu
\n
"
" this requires running a second instance of cr
bk
\n
"
" in lazy-pages mode: 'cr
iu
lazy-pages -D DIR'
\n
"
" in lazy-pages mode: 'cr
bk
lazy-pages -D DIR'
\n
"
" --lazy-pages and lazy-pages mode require userfaultfd
\n
"
" --lazy-pages and lazy-pages mode require userfaultfd
\n
"
"
\n
"
"
\n
"
"* External resources support:
\n
"
"* External resources support:
\n
"
...
@@ -340,7 +344,7 @@ usage:
...
@@ -340,7 +344,7 @@ usage:
" --action-script FILE add an external action script
\n
"
" --action-script FILE add an external action script
\n
"
" -j|--"
OPT_SHELL_JOB
" allow one to dump and restore shell jobs
\n
"
" -j|--"
OPT_SHELL_JOB
" allow one to dump and restore shell jobs
\n
"
" -l|--"
OPT_FILE_LOCKS
" handle file locks, for safety, only used for container
\n
"
" -l|--"
OPT_FILE_LOCKS
" handle file locks, for safety, only used for container
\n
"
" -L|--libdir path to a plugin directory
(by default "
CR_PLUGIN_DEFAULT
")
\n
"
" -L|--libdir path to a plugin directory
\n
"
" --force-irmap force resolving names for inotify/fsnotify watches
\n
"
" --force-irmap force resolving names for inotify/fsnotify watches
\n
"
" --irmap-scan-path FILE
\n
"
" --irmap-scan-path FILE
\n
"
" add a path the irmap hints to scan
\n
"
" add a path the irmap hints to scan
\n
"
...
@@ -368,7 +372,7 @@ usage:
...
@@ -368,7 +372,7 @@ usage:
" The type can be either 'apparmor' or 'selinux'.
\n
"
" The type can be either 'apparmor' or 'selinux'.
\n
"
" --skip-mnt PATH ignore this mountpoint when dumping the mount namespace
\n
"
" --skip-mnt PATH ignore this mountpoint when dumping the mount namespace
\n
"
" --enable-fs FSNAMES a comma separated list of filesystem names or
\"
all
\"\n
"
" --enable-fs FSNAMES a comma separated list of filesystem names or
\"
all
\"\n
"
" force cr
iu
to (try to) dump/restore these filesystem's
\n
"
" force cr
bk
to (try to) dump/restore these filesystem's
\n
"
" mountpoints even if fs is not supported
\n
"
" mountpoints even if fs is not supported
\n
"
" --inherit-fd fd[NUM]:RES
\n
"
" --inherit-fd fd[NUM]:RES
\n
"
" Inherit file descriptors, treating fd NUM as being
\n
"
" Inherit file descriptors, treating fd NUM as being
\n
"
...
@@ -387,7 +391,7 @@ usage:
...
@@ -387,7 +391,7 @@ usage:
" user:PID,UID,GID
\n
"
" user:PID,UID,GID
\n
"
"
\n
"
"
\n
"
"Check options:
\n
"
"Check options:
\n
"
" Without options,
\"
cr
iu
check
\"
checks availability of absolutely required
\n
"
" Without options,
\"
cr
bk
check
\"
checks availability of absolutely required
\n
"
" kernel features, critical for performing dump and restore.
\n
"
" kernel features, critical for performing dump and restore.
\n
"
" --extra add check for extra kernel features
\n
"
" --extra add check for extra kernel features
\n
"
" --experimental add check for experimental kernel features
\n
"
" --experimental add check for experimental kernel features
\n
"
...
...
criu/include/cr_options.h
View file @
f466f811
...
@@ -141,7 +141,7 @@ struct cr_options {
...
@@ -141,7 +141,7 @@ struct cr_options {
};
};
extern
struct
cr_options
opts
;
extern
struct
cr_options
opts
;
char
*
rpc_cfg_file
;
extern
char
*
rpc_cfg_file
;
extern
int
parse_options
(
int
argc
,
char
**
argv
,
bool
*
usage_error
,
bool
*
has_exec_cmd
,
int
state
);
extern
int
parse_options
(
int
argc
,
char
**
argv
,
bool
*
usage_error
,
bool
*
has_exec_cmd
,
int
state
);
extern
int
check_options
();
extern
int
check_options
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment