lxc/0010-cgfsng-adjust-log-level-from-error-to-warn.patch

77 lines
2.8 KiB
Diff
Raw Normal View History

From 9fa92a4f8d0fd772a27e5c27d03b927c765c133c Mon Sep 17 00:00:00 2001
From: lifeng68 <lifeng68@huawei.com>
Date: Fri, 13 Nov 2020 14:11:07 +0800
Subject: [PATCH 10/10] cgfsng: adjust log level from error to warn
Signed-off-by: lifeng68 <lifeng68@huawei.com>
---
src/lxc/cgroups/cgfsng.c | 6 +++---
src/lxc/cgroups/isulad_cgfsng.c | 6 +++---
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/lxc/cgroups/cgfsng.c b/src/lxc/cgroups/cgfsng.c
index 9b9aaf6c3..3f81f5c41 100644
--- a/src/lxc/cgroups/cgfsng.c
+++ b/src/lxc/cgroups/cgfsng.c
@@ -654,7 +654,7 @@ static char **cg_hybrid_get_controllers(char **klist, char **nlist, char *line,
* verify /sys/fs/cgroup/ in this field.
*/
if (strncmp(p, DEFAULT_CGROUP_MOUNTPOINT "/", 15) != 0)
- return log_error(NULL, "Found hierarchy not under " DEFAULT_CGROUP_MOUNTPOINT ": \"%s\"", p);
+ return log_warn(NULL, "Found hierarchy not under " DEFAULT_CGROUP_MOUNTPOINT ": \"%s\"", p);
p += 15;
p2 = strchr(p, ' ');
@@ -3092,7 +3092,7 @@ static int cg_hybrid_init(struct cgroup_ops *ops, bool relative, bool unprivileg
mountpoint = cg_hybrid_get_mountpoint(line);
if (!mountpoint) {
- ERROR("Failed parsing mountpoint from \"%s\"", line);
+ WARN("Failed parsing mountpoint from \"%s\"", line);
continue;
}
@@ -3101,7 +3101,7 @@ static int cg_hybrid_init(struct cgroup_ops *ops, bool relative, bool unprivileg
else
base_cgroup = cg_hybrid_get_current_cgroup(basecginfo, NULL, CGROUP2_SUPER_MAGIC);
if (!base_cgroup) {
- ERROR("Failed to find current cgroup");
+ WARN("Failed to find current cgroup");
continue;
}
diff --git a/src/lxc/cgroups/isulad_cgfsng.c b/src/lxc/cgroups/isulad_cgfsng.c
index 82a4333f3..e16f8a198 100644
--- a/src/lxc/cgroups/isulad_cgfsng.c
+++ b/src/lxc/cgroups/isulad_cgfsng.c
@@ -317,7 +317,7 @@ static char **cg_hybrid_get_controllers(char **klist, char **nlist, char *line,
* verify /sys/fs/cgroup/ in this field.
*/
if (strncmp(p, DEFAULT_CGROUP_MOUNTPOINT "/", 15) != 0)
- return log_error(NULL, "Found hierarchy not under " DEFAULT_CGROUP_MOUNTPOINT ": \"%s\"", p);
+ return log_warn(NULL, "Found hierarchy not under " DEFAULT_CGROUP_MOUNTPOINT ": \"%s\"", p);
p += 15;
p2 = strchr(p, ' ');
@@ -2847,7 +2847,7 @@ static int cg_hybrid_init(struct cgroup_ops *ops, bool relative, bool unprivileg
mountpoint = cg_hybrid_get_mountpoint(line);
if (!mountpoint) {
- ERROR("Failed parsing mountpoint from \"%s\"", line);
+ WARN("Failed parsing mountpoint from \"%s\"", line);
continue;
}
@@ -2856,7 +2856,7 @@ static int cg_hybrid_init(struct cgroup_ops *ops, bool relative, bool unprivileg
else
base_cgroup = cg_hybrid_get_current_cgroup(basecginfo, NULL, CGROUP2_SUPER_MAGIC);
if (!base_cgroup) {
- ERROR("Failed to find current cgroup");
+ WARN("Failed to find current cgroup");
continue;
}
--
2.25.1