1 В избранное 0 Ответвления 0

OSCHINA-MIRROR/src-openeuler-iSulad

В этом репозитории не указан файл с открытой лицензией (LICENSE). При использовании обратитесь к конкретному описанию проекта и его зависимостям в коде.
Клонировать/Скачать
0053-remove-container-root-path-in-rt_lcr_rm-if-lcr-runti.patch 1.4 КБ
Копировать Редактировать Web IDE Исходные данные Просмотреть построчно История
liuxu Отправлено 20.04.2024 05:00 b409779
From 0cb96d50302f9f3ad1c17e0bb650ac37db4d5206 Mon Sep 17 00:00:00 2001
From: jikai <jikai11@huawei.com>
Date: Wed, 10 Apr 2024 08:41:46 +0000
Subject: [PATCH 53/69] remove container root path in rt_lcr_rm if lcr runtime
missing
Signed-off-by: jikai <jikai11@huawei.com>
---
src/daemon/modules/runtime/engines/lcr/lcr_rt_ops.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/src/daemon/modules/runtime/engines/lcr/lcr_rt_ops.c b/src/daemon/modules/runtime/engines/lcr/lcr_rt_ops.c
index 6b862958..978da079 100644
--- a/src/daemon/modules/runtime/engines/lcr/lcr_rt_ops.c
+++ b/src/daemon/modules/runtime/engines/lcr/lcr_rt_ops.c
@@ -238,7 +238,13 @@ int rt_lcr_rm(const char *name, const char *runtime, const rt_rm_params_t *param
engine_ops = engines_get_handler(runtime);
if (engine_ops == NULL || engine_ops->engine_delete_op == NULL) {
- ERROR("Failed to get engine delete operations");
+ // if engine_ops is NULL, container root path may have been corrupted, try to remove by daemon
+ // If user runs container with lcr but remove lcr runtime after, there might be resources remaining
+ ERROR("Failed to get engine delete operations, container %s root path may have been corrupted, try to remove by daemon", name);
+ if (remove_container_rootpath(name, params->rootpath) == 0) {
+ ret = 0;
+ goto out;
+ }
ret = -1;
goto out;
}
--
2.34.1

Опубликовать ( 0 )

Вы можете оставить комментарий после Вход в систему

1
https://api.gitlife.ru/oschina-mirror/src-openeuler-iSulad.git
git@api.gitlife.ru:oschina-mirror/src-openeuler-iSulad.git
oschina-mirror
src-openeuler-iSulad
src-openeuler-iSulad
master