[CRIU] More uffd related questions (Error (page-read.c:128): Missing 7fff408d8000 in parent pagemap)

Adrian Reber adrian at lisas.de
Mon Nov 30 02:16:40 PST 2015


On Mon, Nov 30, 2015 at 12:47:48PM +0300, Pavel Emelyanov wrote:
> On 11/30/2015 12:28 PM, Adrian Reber wrote:
> > On Mon, Nov 30, 2015 at 12:24:35PM +0300, Pavel Emelyanov wrote:
> >> On 11/27/2015 05:51 PM, Adrian Reber wrote:
> >>> In addition to the pages requested via uffd I am now copying the not
> >>> requested pages into the process using uffd.
> >>>
> >>> The first part is waiting for requests from uffd and tracking which pages
> >>> have been transferred and once this part has finished I am switching to
> >>> 'copy-the-rest' mode. I am going through my list of pages and I am now
> >>> copying each page into the process using uffd.
> >>>
> >>> This works for the first two pages in my list but seeking to the third page
> >>> fails with in seek_pagemap_page():
> >>>
> >>> (05.009260) Error (page-read.c:128): Missing 7fff408d8000 in parent pagemap, current iov: base=7fff408d9000,len=12288
> >>
> >> Hm... Do you use the recent head? I've introduced this bug about 2-3 weeks
> >> ago and have fixed it some days later :)
> > 
> > Which commit did fix this again? So that I can check if I am using the
> > version with or without the fix?
> 
> The fix was 7d72537dbd264e1f92687853d31914a1b11c9153 (page-read: Properly handle 
> overlapping pagemaps in stack)

I was using the latest head from last week which included your fix and I
just rebased to today's head and I still get the same error.

> > Reading the page then also fails:
> > 
> > (05.009264) pr11 Read 7fff408d8000 1 pages
> > (05.009266) Error (page-read.c:152): Page read err 7fff408d9000:3 vs 7fff408d8000:1
> > (05.009267) Error (page-read.c:153): BUG at page-read.c:153
> > Aborted
> > 
> > Looking at crit's output I cannot detect anything special regarding this
> > pages:
> > 
> >                 {
> >                     "start": "0x7fff408ba000", 
> >                     "end": "0x7fff408dc000", 
> >                     "pgoff": 0, 
> >                     "shmid": 0, 
> >                     "prot": "PROT_READ | PROT_WRITE", 
> >                     "flags": "MAP_PRIVATE | MAP_ANON | MAP_GROWSDOWN", 
> >                     "status": "0x201", 
> >                     "fd": -1, 
> >                     "fdflags": "0x0"
> >                 }, 
> 
> This is mm.img part, while page-read engine deals with pagemap-xxx.img files where
> triplets of [start len in_parent] sit.

Ah, okay. This is my error. The page I am trying to copy does indeed not
exist in the pagemap:

        {
            "vaddr": "0x7f8025f6e000", 
            "nr_pages": 5
        }, 
        {
            "vaddr": "0x7fff408d9000", 
            "nr_pages": 3
        }, 
        {
            "vaddr": "0x7fff409c2000", 
            "nr_pages": 2
        }

So to decide which pages I have to copy I only have to look at the content
of pagemap-xxx.img and not mm.img, right? Good to know.

		Adrian


More information about the CRIU mailing list