[Crash-utility] Issues with kmem -i

Dave Anderson anderson at redhat.com
Tue Apr 11 13:53:58 UTC 2006


Sharyathi Nagesh wrote:

> Dave
>         Please go through my observation.
>
> >
> > That makes the most sense at this point.  This is what I was
> > planning for vm_init():
> >
> >
> > @@ -694,7 +708,8 @@ vm_init(void)
> >                         vt->PG_slab = 10;
> >                 else if (THIS_KERNEL_VERSION >= LINUX(2,6,0))
> >                         vt->PG_slab = 7;
> > -       }
> > +       } else if (THIS_KERNEL_VERSION >= LINUX(2,6,0))
> > +               vt->PG_slab = 7;
> >  }
> here for the dump I was looking into vt->PG_slab needs to be set to 10
> and not 7. as slab value was 1024 in dump_mem_map() function.

What kernel version are you testing with?

>
> >  /*
> >
> > >
> > >
> > >
> > > o The output is breaking as  totalhigh_pages is coming out zero,
> > > So part of code in function dump_kmeminfo()
> > > pct = freehighmem_pages ?
> > >                         (freehighmem_pages * 100)/totalhigh_pages :
> > > 0;
> > > Cause Arithmetic calculation error.
> > >
> > > Still looking into the problem.
> > >
> > I can't reproduce this one.  In your case though, with
> > about 500MB, both "freehighmem_pages" and "totalhigh_pages"
> > should both be zero, leading to a "pct" setting of 0.
> > Are you showing "freehighmem_pages" as non-zero?
> >
> > Dave
> I could see totalhigh_pages coming out zero which was the right thing
> (As it was x86_64 machine) but freehighmem_pages came out as a non zero
> quantity.
> In function :dump_free_pages_zones_v2(). I could see vt->nr_zones as 4
> which I feel is incorrect and hence it entered the block
>         if (i == ZONE_HIGHMEM) {
>                                 readmem(node_zones+
>                                        OFFSET(zone_free_pages),
>                                              KVADDR, &value,
> sizeof(ulong),
>                                              "node_zones free_pages",
>                                              FAULT_ON_ERROR);
>                                       sum += value;
>                                 }
> and sum was updated with a value and hence freehighmem_pages causing
> Arithmetic exception

Ah -- the value of ZONE_HIGHMEM can no longer be fixed since
it's been changed from 3 to 4.  It should be based upon
the array size of the pglist_data.node_zones[] minus 1.
Since we already save this array index at init-time,
I'll make ZONE_HIGHMEM a variable in the vm_table.
The other two definitions (ZONE_DMA and ZONE_LOW) aren't
used).

Thanks,
  Dave


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/crash-utility/attachments/20060411/7d33a937/attachment.htm>


More information about the Crash-utility mailing list