OpenVZ Forum


Home » General » Support » Using threads on OpenVZ, and memory allocation versus memory usage
Re: Using threads on OpenVZ, and memory allocation versus memory usage [message #12923 is a reply to message #12655] Tue, 15 May 2007 07:41 Go to previous messageGo to previous message
MvdS is currently offline  MvdS
Messages: 2
Registered: May 2007
Junior Member
I have had no time yet to show the changes in the memmory map on an OpenVZ machine. But I found one thing that helps, limiting the stack size with ulimit:
ulimit -s 16

Significantly reduces the stack used by every thread, and thus the amount of memory allocated. However I have no idea what is a good amount of stack to use. I suppose this differs with programs.

The quick fix (while waiting for the RSS limiting) would be to mention the usage of threads and ulimit in the documentation of privvmpages usage.

pthreads allows to set the stack size, but it defaults to the maximum allowed by ulimit.

The mappings are really straight forward (4K + around 8MiB per thread). If you still want this info, I'll probably be able to mesure it sometime this week.
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: *SOLVED* ip_conntrack_ftp inside VE
Next Topic: *SOLVED* home dir of vps on an other partition or networkdevice
Goto Forum:
  


Current Time: Fri Oct 18 09:06:11 GMT 2024

Total time taken to generate the page: 0.05109 seconds