xfs
[Top] [All Lists]

Re: kernel panic:kmem_zone_zalloc: NULL memory on KM_SLEEP request!

To: Nathan Scott <nathans@xxxxxxx>
Subject: Re: kernel panic:kmem_zone_zalloc: NULL memory on KM_SLEEP request!
From: marat <nospam-259928-001@xxxxxxx>
Date: Tue, 09 Dec 2003 10:23:47 +0100
Cc: linux-xfs@xxxxxxxxxxx
In-reply-to: <20031209025039.GB1798@frodo>
Organization: westerngeco
References: <200312081317.26603.nospam-259928-001@slb.com> <20031209025039.GB1798@frodo>
Sender: linux-xfs-bounce@xxxxxxxxxxx
User-agent: KMail/1.4.1
Nathan,

Thanks a lot for a good explanation.

At the moment we are using 4Gb of memory on this machine. Do you think, it will 
help if I add more  memory ? 

And, you said it tries to allocated memory a number of times. Is it in 
support/kmem.c file : 
 #define MAX_SHAKE 8  ?
May be I can try to increase this value.


Regards,
Marat




On Tuesday 09 December 2003 03:50, you wrote:
> On Mon, Dec 08, 2003 at 01:17:26PM +0100, marat wrote:
> > Experts,
> >
> > Recently, I had one of the xfs filesystem failed and the only  message
> > was  : kernel panic:kmem_zone_zalloc: NULL memory on KM_SLEEP request!
> >
> > I had to reboot machine and run xfs_repair to make files system available
> > again.
> >
> > I am using kernel 2.4.20 SMP and xfs version 1.3.0.
> >
> > Any ideas, suggestions how I can avoid this problem to happen again ?
>
> Well, whats happened here is XFS is allocating memory from
> a context where it cannot fail, and retries the allocation
> a number of times (6 IIRC, with delays in-between each) and
> after freeing up everything that XFS can itself.  Afterward
> if we still cannot get any memory allocated we give up and
> call BUG().
>
> I guess we could keep retrying indefinitely, but that doesn't
> seem like a particularly good solution.  I suspect we should
> be getting a bit more help from the VM here (more recent 2.4
> kernels might make this case better) ... you may be able to
> tweak some variables in mm/vmscan.c too - these are likely
> sysctls somewhere - vm_mapped_ratio, vm_vfs_scan_ratio, etc
> (ah, have a look through "vm_table" in kernel/sysctl.c).
>
> cheers.

-



<Prev in Thread] Current Thread [Next in Thread>