[CRIU] [PATCH 1/1] report fd/path if dump_one_reg_file()->lookup_nsid_by_mnt_id() fails

Oleg Nesterov oleg at redhat.com
Tue Apr 21 10:14:49 PDT 2015


"Unable to look up the %d mount" doesn't really help to understand
the problem, add a bit more info.

And perhaps it makes more sense to change dump_task_files_seized()
to report fd/path if dump_one_file() fails.

Signed-off-by: Oleg Nesterov <oleg at redhat.com>
---
 files-reg.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/files-reg.c b/files-reg.c
index f313126..d7251ec 100644
--- a/files-reg.c
+++ b/files-reg.c
@@ -818,7 +818,8 @@ int dump_one_reg_file(int lfd, u32 id, const struct fd_parms *p)
 
 	nsid = lookup_nsid_by_mnt_id(p->mnt_id);
 	if (nsid == NULL) {
-		pr_err("Unable to look up the %d mount\n", p->mnt_id);
+		pr_err("Can't lookup mount=%d for fd=%d path=%s\n",
+			p->mnt_id, p->fd, link->name + 1);
 		return -1;
 	}
 
-- 
1.5.5.1




More information about the CRIU mailing list