lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 10 Apr 2007 10:31:34 -0400
From:	"Mouawad, Tony" <Tony.Mouawad@...istiedigital.com>
To:	"Robert Hancock" <hancockr@...w.ca>
Cc:	<linux-kernel@...r.kernel.org>
Subject: RE: Help Understanding Linux memory management

When vm.overcommit_memory = 2 and there appears to be about 2M of memory
readily available and about 12M of memory allocated to pagecache (this
is info gathered from /proc/meminfo) , a call to malloc(5000000) returns
NULL.  I would have expected that somehow, the call to malloc(5000000)
would request the memory in pagecache to be released for use by the app.


-----Original Message-----
From: Robert Hancock [mailto:hancockr@...w.ca] 
Sent: Tuesday, April 10, 2007 10:15 AM
To: Mouawad, Tony
Cc: linux-kernel@...r.kernel.org
Subject: Re: Help Understanding Linux memory management

Mouawad, Tony wrote:
> Hello,
> 
> I've been a MS Windows based programmer for a very long time and was
> recently tossed in an environment where I am developing embedded apps
on
> the m68k / Linux platform.  That makes me a Linux newbie.  I started
> asking a few questions on various IRC channels and was directed to
this
> group.  So, I will start asking:
> 
> These are questions derived from observations on the MCF 5475 CPU
> running Linux 2.6.10 built for the m68k platform.  Disk swapping is
> disabled.
> 
> 1) When physical memory runs low, the memory manager will try to use
> memory currently allocated to the pagecache.  Is this true?

Yes.

> 2) When vm.overcommit_memory = 2 (overcommit disabled), and memory
runs
> low, it appears that the memory manager does not try to use memory
> currently allocated to pagecache.  Is this true?

Shouldn't be, what makes you think this is happening?

> 3) Is it possible to disable the pagecache?

Not as far as I know, it's unlikely this would be of any benefit.

-- 
Robert Hancock      Saskatoon, SK, Canada
To email, remove "nospam" from hancockr@...pamshaw.ca
Home Page: http://www.roberthancock.com/

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ