Re: memory exhausted

Paul Sander <[email protected]>
Newsgroups gmane.comp.version-control.cvs.general
Message-ID <[email protected]>
We just had a similar question yesterday.  When CVS reads RCS files,  
it mmaps them into virtual memory.  When CVS fails, how large is the  
RCS file it's processing at the time, in comparison to the metrics  
you indicate below?

On Nov 12, 2008, at 10:11 AM, Alex Krasnov wrote:

> My server configuration is:
>
> CVS 1.12.13 on Solaris 11.
>
> My client configuration is:
>
> CVS 1.12.13 on Debian 4.0
>
> I am trying to check out a project containing multiple binary files  
> each less than 512 MB in size. The server reports the following error:
>
> Nov 12 10:01:24 root cvs[879]: [ID 233912 daemon.emerg] error (1,  
> 0) called recursively.  Original message was:
> Nov 12 10:01:24 root cvs[879]: [ID 702911 daemon.emerg] cvs  
> [checkout aborted]: memory exhausted
> Nov 12 10:01:24 root cvs[879]: [ID 587406 daemon.emerg] error (1,  
> 0) called recursively.  Second message was:
> Nov 12 10:01:24 root cvs[879]: [ID 702911 daemon.emerg] cvs  
> [checkout aborted]: memory exhausted
> Nov 12 10:01:24 root cvs[879]: [ID 286756 daemon.emerg] Aborting.
>
> The server reports sufficient physical memory available. Before:
>
> Page Summary                Pages                MB  %Tot
> ------------     ----------------  ----------------  ----
> Kernel                     100193               391   10%
> ZFS File Data               56597               221    5%
> Anon                        42156               164    4%
> Exec and libs               10991                42    1%
> Page cache                   1053                 4    0%
> Free (cachelist)             4824                18    0%
> Free (freelist)            830328              3243   79%
>
> Total                     1046142              4086
> Physical                  1046141              4086
>
> After:
>
> Page Summary                Pages                MB  %Tot
> ------------     ----------------  ----------------  ----
> Kernel                     127140               496   12%
> ZFS File Data              249138               973   24%
> Anon                        41993               164    4%
> Exec and libs               10799                42    1%
> Page cache                   1053                 4    0%
> Free (cachelist)           421502              1646   40%
> Free (freelist)            194517               759   19%
>
> Total                     1046142              4086
> Physical                  1046141              4086
>
> No per-process memory limits appear to be set. However, the cvs  
> process is unable to memory-map the file:
>
> mmap64(0x00000000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE| 
> MAP_ANON, -1, 0) = 0x08430000
> mmap64(0x00000000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE| 
> MAP_ANON, -1, 0) = 0x08420000
> mmap64(0x00000000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE| 
> MAP_ANON, -1, 0) Err#12 ENOMEM
> mmap64(0x00000000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE| 
> MAP_ANON, -1, 0) Err#12 ENOMEM
>
> Questions:
>
> (0) Why is mmap64 failing in this case?
> (1) Can the memory usage be limited?
> (2) Can the number of files memory-mapped simultaneousely be limited?
>
> Alex
>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.