hi thilo, the scaling problem comes from the overhead of switching python threads when they run on 2 CPUs. one strategy, if your OS allowed it, would be to force the python process onto a single CPU. sunOS/solaris allows you to do so if i remember right. you're a little luckier if you actually run 2 zope instances on the machine (like i do on an old pentium 166 at home), at least on linux, which does not allow you to set processor affinity, this will force each python process onto a single CPU. what you definitely might want to try is a fix that matt kromer here at digital creations came up with. the technical background is that python has a built-in timer that controls how often python checks on all its threads and, if needed, switches from one to another. if you increase the interval on this timer you will decrease the number of thread switches, thereby speeding up your zope installation. to apply it to your own zope install open z2.py in your zope root directory and add the following line just before the comment that starts the "Configuration section" (roughly around line 220): sys.setcheckinterval(50) the best number given as argument to setcheckinterval is something you could find out by benchmarking. 50 is what i use on my site, and compared to two standard zope 2.1.6 instances running i gained about 100% in speed. this fix is becoming part of zope 2.2.0, as far as i know it is already in the alpha and brian lloyd decided on 120 as a good number for starters. again, to see the best results you might want to try different numbers and benchmark the site with e.g. ab. hope that helps jens ---- Jens Vagelpohl jens@digicool.com Software Engineer www.digicool.com Digital Creations (888) 344-4332 Got Zope? ---- -----Original Message----- From: zope-dev-admin@zope.org [mailto:zope-dev-admin@zope.org]On Behalf Of Thilo Mezger Sent: Thursday, May 18, 2000 03:21 To: zope-dev@zope.org Subject: [Zope-dev] Zope and SMP hi! yesterday, i have test-driven zope on a dual-pentium smp-machine running linux 2.2 and i was very disappointed by the results. the zserver threads are running on both cpu's but it seems to scale really, really badly. i have only done some very cheap benchmarking but it seems that a single cpu is faster than 2 cpu's. but as i said, this is not proper benchmarking (yet). i wanted to ask if someone has already tried zope on more than 1 cpu and/or could point me to a direction where i could find out more about this subject? cheers! thilo -- thilo.mezger@innominate.de innominate AG networking people fon: +49-30-308806-0 fax: -77 web: http://innominate.de pgp: /pgp/tm _______________________________________________ Zope-Dev maillist - Zope-Dev@zope.org http://lists.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope )
participants (1)
-
Jens Vagelpohl