OpenVZ Forum


Home » General » Support » fork: Cannot alocate Memory ([solved] starting dimdim server)
fork: Cannot alocate Memory [message #38154] Tue, 24 November 2009 08:23 Go to next message
P_H_I_L is currently offline  P_H_I_L
Messages: 7
Registered: November 2009
Junior Member
Hey Sir, When I am starting my dimdim server this message is shown me: fork: Cannot alocate Memory

cat /proc/user_beancounters:
  uid  resource           held    maxheld    barrier      limit    failcnt
      202:  kmemsize        3700437    5840579   11055923   11377049          0
            lockedpages           0          0        256        256          0
            privvmpages      381463     384383     384000     393212        821
            shmpages             45       1341      21504      21504          0
            dummy                 0          0          0          0          0
            numproc              78        140        240        240          0
            physpages         16907      19458          0 2147483647          0
            vmguarpages           0          0     262144 2147483647          0
            oomguarpages      16907      19458      26112 2147483647          0
            numtcpsock           10         21        360        360          0
            numflock              8          9        188        206          0
            numpty                0          1         16         16          0
            numsiginfo            0         33        256        256          0
            tcpsndbuf         89440     136396    1720320    2703360          0
            tcprcvbuf        188980     222584    1720320    2703360          0
            othersockbuf       6708      16916    1126080    2097152          0
            dgramrcvbuf           0       8380     262144     262144          0
            numothersock         19         28        360        360          0
            dcachesize            0          0    3409920    3624960          0
            numfile            1475       2655       9312       9312          0
            dummy                 0          0          0          0          0
            dummy                 0          0          0          0          0
            dummy                 0          0          0          0          0
            numiptent            10         10        128        128          0
      101:  kmemsize        3338174    3816804   11055923   11377049          0
            lockedpages           0          0        256        256          0
            privvmpages      293342     301963     965536     969632          0
            shmpages              0       1341      21504      21504          0
            dummy                 0          0          0          0          0
            numproc              73         80        240        240          0
            physpages        135597     145294          0 2147483647          0
            vmguarpages           0          0   99933792 2147483647          0
            oomguarpages     135597     145294      26112 2147483647          0
            numtcpsock           19         26        360        360          0
            numflock              4          5        188        206          0
            numpty                0          1         16         16          0
            numsiginfo            0         12        256        256          0
            tcpsndbuf        143104     172172    1720320    2703360          0
            tcprcvbuf        131072     221748    1720320    2703360          0
            othersockbuf       6708      16916    1126080    2097152          0
            dgramrcvbuf           0       8380     262144     262144          0
            numothersock         11         18        360        360          0
            dcachesize            0          0    3409920    3624960          0
            numfile            1346       1559       9312       9312          0
            dummy                 0          0          0          0          0
            dummy                 0          0          0          0          0
            dummy                 0          0          0          0          0
            numiptent            10         10        128        128          0
        0:  kmemsize        6677257    7908659 2147483647 2147483647          0
            lockedpages           0          0 2147483647 2147483647          0
            privvmpages       73438      92242 2147483647 2147483647          0
            shmpages           1358       2974 2147483647 2147483647          0
            dummy                 0          0 2147483647 2147483647          0
            numproc             124        141 2147483647 2147483647          0
            physpages         29131      45853 2147483647 2147483647          0
            vmguarpages           0          0 2147483647 2147483647          0
            oomguarpages      29164      45853 2147483647 2147483647          0
            numtcpsock           10         19 2147483647 2147483647          0
            numflock              7         11 2147483647 2147483647          0
            numpty                1          2 2147483647 2147483647          0
            numsiginfo            1         12 2147483647 2147483647          0
            tcpsndbuf         98332     335720 2147483647 2147483647          0
            tcprcvbuf        163840     839960 2147483647 2147483647          0
            othersockbuf     111800     150764 2147483647 2147483647          0
            dgramrcvbuf           0      16760 2147483647 2147483647          0
            numothersock         92        102 2147483647 2147483647          0
            dcachesize            0          0 2147483647 2147483647          0
            numfile            2693       3029 2147483647 2147483647          0
            dummy                 0          0 2147483647 2147483647          0
            dummy                 0          0 2147483647 2147483647          0
            dummy                 0          0 2147483647 2147483647          0
            numiptent            10         10 2147483647 2147483647          0


Can anybody help me and say the problem?
I have 2 Virtual machines every need min. 1 u. max. 2 gb RAM

How can i configurate this? And I have a Pentium 2,4 Server. What CPUUNIT I can configurate?

I dont know how to calculate in linux. iam a newbie Sad)


Greetz,
Philipp

[Updated on: Wed, 25 November 2009 13:04] by Moderator

Report message to a moderator

Re: fork: Cannot alocate Memory [message #38155 is a reply to message #38154] Tue, 24 November 2009 08:37 Go to previous messageGo to next message
khorenko is currently offline  khorenko
Messages: 533
Registered: January 2006
Location: Moscow, Russia
Senior Member
Hi Philipp,

cat /proc/user_beancounters:
  uid  resource           held    maxheld    barrier      limit    failcnt
       privvmpages      381463     384383     384000     393212        821



Look, you simply got a "privvmpages" failcounters, which means that your Container allocated too much memory and hit its limit (allocated != used).

Well, i think you have to understand what application inside a Container requires so many RAM (381463*4096=1562472448 ~ 1.5 Gb is quite a lot) and decide if this is normal or not for that application.
And if you decide that this is normal, should just have to increase the privvmpages limit.

Hope that helps.

And talking about CPUUNITS... well, just leave it by default at least you get a stable and working system. Smile

Good luck!

--
Konstantin


If your problem is solved - please, report it!
It's even more important than reporting the problem itself...

[Updated on: Tue, 24 November 2009 10:38] by Moderator

Report message to a moderator

Re: fork: Cannot alocate Memory [message #38157 is a reply to message #38154] Tue, 24 November 2009 15:17 Go to previous messageGo to next message
P_H_I_L is currently offline  P_H_I_L
Messages: 7
Registered: November 2009
Junior Member
My english is not so good.
I dont understand all sentences Sad

I want to install an conference server. dimdim.

I need > 512mb RAM for dimdim in this openVZ.

Can you help me? What parameters do I have to set. I always get the alcote memory error. Sad
Re: fork: Cannot alocate Memory [message #38158 is a reply to message #38157] Tue, 24 November 2009 15:49 Go to previous messageGo to next message
khorenko is currently offline  khorenko
Messages: 533
Registered: January 2006
Location: Moscow, Russia
Senior Member
vzctl set 202 --privvmpages 768000:786424 --save


This will provide your Container 3 Gb of RAM for allocation.

--
Konstantin


If your problem is solved - please, report it!
It's even more important than reporting the problem itself...
Re: fork: Cannot alocate Memory [message #38160 is a reply to message #38154] Tue, 24 November 2009 19:36 Go to previous messageGo to next message
P_H_I_L is currently offline  P_H_I_L
Messages: 7
Registered: November 2009
Junior Member
if i do this i get: cannot alocate memory!
It's the first info, if i start the machine. whats wrong?

Sad


this is the config! I have a PC with 2GB! For the vz i need ca >700MB RAm, to start the conference server:

Maybe anybody can help me:

# UBC parameters (in form of barrier:limit)
# Primary parameters
#AVNUMPROC="200:200"
NUMPROC="400:1200"
NUMTCPSOCK="500:2048"
NUMOTHERSOCK="500:2048"
VMGUARPAGES="2047483647:2147483647"
# Secondary parameters
KMEMSIZE="16384000:18022400"
TCPSNDBUF="5365760:10485760"
TCPRCVBUF="5365760:10485760"
OTHERSOCKBUF="1503232:4063232"
DGRAMRCVBUF="262144:262144"
OOMGUARPAGES="2047483647:2147483647"
# Auxiliary parameters
LOCKEDPAGES="4096:4096"
SHMPAGES="131072:131072"
PRIVVMPAGES="2047483647:2147483647"
NUMFILE="8192:8192"
NUMFLOCK="200:220"
NUMPTY="64:64"
NUMSIGINFO="512:512"
DCACHESIZE="4194304:4194304"
PHYSPAGES="0:2147483647"
NUMIPTENT="128:128"                  
                                                                            
# Disk quota parameters (in form of softlimit:hardlimit)
DISKSPACE="991048576:991153024"
DISKINODES="1200000:1220000"
QUOTATIME="0"                                                        
                                                                            
# CPU fair sheduler parameter                                               
CPUUNITS="1000"

VE_ROOT="/vz/root/$VEID"
VE_PRIVATE="/vz/private/$VEID"
OSTEMPLATE="centos-5.2-i386-default"
ORIGIN_SAMPLE="vps.basic"
HOSTNAME="vm202.server.cams4friends.com"
IP_ADDRESS="64.120.180.5"


This is my *.conf! But I always get an privvmpage failcnt.

Sad

While starting the server i get an runtime exception: for: cannot alocate memory.

if I set too much in the conig
a) iam not able to start the ve or
b) The First message while starting the server 'cannot alocate memory' It's the first statement in the shell, that i get..

Suggestions?

[Updated on: Tue, 24 November 2009 20:06]

Report message to a moderator

Re: fork: Cannot alocate Memory [message #38163 is a reply to message #38160] Wed, 25 November 2009 07:50 Go to previous messageGo to next message
khorenko is currently offline  khorenko
Messages: 533
Registered: January 2006
Location: Moscow, Russia
Senior Member
Please, post here:
# cat /proc/user_beancounters
# vzctl start 202
# // any command do get "cannot allocate memory" error
# cat /proc/user_beancounters

Thanks.

--
Konstantin


If your problem is solved - please, report it!
It's even more important than reporting the problem itself...
Re: fork: Cannot alocate Memory [message #38164 is a reply to message #38154] Wed, 25 November 2009 08:04 Go to previous messageGo to next message
P_H_I_L is currently offline  P_H_I_L
Messages: 7
Registered: November 2009
Junior Member
First i stopped the vz:
  202:  kmemsize            589   12646078   16384000   18022400          0
            lockedpages           0          0       4096       4096          0
            privvmpages           0     753230 2047483647 2147483647        528
            shmpages              0       2301     131072     131072          0
            dummy                 0          0          0          0          0
            numproc               0        400        400       1200        254
            physpages             0      22316          0 2147483647          0
            vmguarpages           0          0 2047483647 2147483647          0
            oomguarpages          0      22316 2047483647 2147483647          0
            numtcpsock            0         14        500       2048          0
            numflock              0          9        200        220          0
            numpty                0          1         64         64          0
            numsiginfo            0         21        512        512          0
            tcpsndbuf             0     125216    5365760   10485760          0
            tcprcvbuf             0     188980    5365760   10485760          0
            othersockbuf          0      29988    1503232    4063232          0
            dgramrcvbuf           0       8380     262144     262144          0
            numothersock          0         38        500       2048          0
            dcachesize            0          0    4194304    4194304          0
            numfile               0       6796       8192       8192          0
            dummy                 0          0          0          0          0
            dummy                 0          0          0          0          0
            dummy                 0          0          0          0          0
            numiptent             0         10        128        128          0


Then i started it:
 202:  kmemsize       12502522   12779424   16384000   18022400          0
            lockedpages           0          0       4096       4096          0
            privvmpages      597485     597743 2047483647 2147483647          0
            shmpages           1325       1341     131072     131072          0
            dummy                 0          0          0          0          0
            numproc             400        400        400       1200        224
            physpages         19344      20705          0 2147483647          0
            vmguarpages           0          0 2047483647 2147483647          0
            oomguarpages      19344      20705 2047483647 2147483647          0
            numtcpsock           12         12        500       2048          0
            numflock              8          9        200        220          0
            numpty                1          1         64         64          0
            numsiginfo            0          2        512        512          0
            tcpsndbuf        169936     169936    5365760   10485760          0
            tcprcvbuf        221748     188980    5365760   10485760          0
            othersockbuf      11180      16916    1503232    4063232          0
            dgramrcvbuf           0       8380     262144     262144          0
            numothersock         24         28        500       2048          0
            dcachesize            0          0    4194304    4194304          0
            numfile            6692       6709       8192       8192          0
            dummy                 0          0          0          0          0
            dummy                 0          0          0          0          0
            dummy                 0          0          0          0          0
            numiptent            10         10        128        128          0



I became so message cannot alocate memory
Re: fork: Cannot alocate Memory [message #38166 is a reply to message #38164] Wed, 25 November 2009 08:20 Go to previous messageGo to next message
khorenko is currently offline  khorenko
Messages: 533
Registered: January 2006
Location: Moscow, Russia
Senior Member
You've got "numproc" failcounters.
Please, increase "numproc" limits.


If your problem is solved - please, report it!
It's even more important than reporting the problem itself...
Re: fork: Cannot alocate Memory [message #38167 is a reply to message #38154] Wed, 25 November 2009 12:50 Go to previous message
P_H_I_L is currently offline  P_H_I_L
Messages: 7
Registered: November 2009
Junior Member
it works thx. Thank you very much, Sir
Previous Topic: Memory Allocation issues
Next Topic: canno start VE's --> openvz kernel problem?
Goto Forum:
  


Current Time: Sun Jul 13 12:15:25 GMT 2025

Total time taken to generate the page: 0.02300 seconds