Hello , my question is a bit complex ( for me ). I have : - Linux RH 6.1 - python 1.5.2 --with-thread (source compiled) - zope 2.2.x or zope 2.3.x (source compiled) In any program in python with Linux (inclusive Zope), the threads are processes,i.e, they consume memory and don´t share it. In Windows this is different. In Linux, I have Zope running with 4 Threads. I have five processes and everyone consuming about 12 MB => 12 * 5 MB = 60 MB In Windows in the same situation I only have one process and the threads share the memory, which is the most desirable situation. Why?? Does anybody know a solution for Linux, in order to have only one process and threads sharing memory, as in Windows?? Thanks. Aitor /_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/ Aitor Grajal Crespo Director General e-mail: aitor.grajal@inetsys.es INETSYS, S.L. ETSI Informática Ctra. Colmenar, km. 15,500 28049 MADRID SPAIN Tfno : (34) 91 348 22 66 - Fax : (34) 91 348 22 66 http://www.inetsys.es /_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
Scavenging the mail folder uncovered Aitor Grajal Crespo's letter:
Hello , my question is a bit complex ( for me ). I have :
- Linux RH 6.1 - python 1.5.2 --with-thread (source compiled) - zope 2.2.x or zope 2.3.x (source compiled)
In any program in python with Linux (inclusive Zope), the threads are processes,i.e, they consume memory and don´t share it.
this is completely wrong. threads under linux have a different pid but are created setting the CLONE flag so they share almost anything (address space, shared objects, etc.)
In Linux, I have Zope running with 4 Threads. I have five processes and everyone consuming about 12 MB => 12 * 5 MB = 60 MB
this is what top tell you, but try using memstat to show the real memory consumed by each process... ciao, federico -- Federico Di Gregorio MIXAD LIVE Chief of Research & Technology fog@mixadlive.com Debian GNU/Linux Developer & Italian Press Contact fog@debian.org All programmers are optimists. -- Frederick P. Brooks, Jr.
participants (2)
-
Aitor Grajal Crespo -
Federico Di Gregorio