On 7/12/06, krokodylek@tenbit.pl <krokodylek@tenbit.pl> wrote:
I am to use Zope on a SMP machine which has 2 Xeon HT cpus (so 4 logical processors). As far as I know Python is not multithreaded, so the full potential of the server will not be used... How can I change that?
I was thinking about running a couple of identical instances connected with ZEO and then using some load balancing between them. Do you think this is a good idea? How many instances should I use on a machine I have described, four? Are there any cons of such a configuration?
I am open to any suggestions on how to use the machine's power best :-)
KISS. Just use Zope as anyone would use it. Hyperthreading is not that much of a gain, and actual sometimes it decreases overall performance. You would need a Hyperthreading-aware OS (don't know how far Linux is in this, but it is _not_ sufficient for the OS to schedule its processes/threads on the four "visible" processors). If you have one processor running Zope and one processor running the system and the rest, you will be pretty happy I think. Depending on your application you could also run two zope instances doing different things Start doing the fancy stuff if you happen to experience actual performance problems. Find the bottleneck. Do you know that the bottleneck will be on CPU scheduling? What happens, if your application on this server with this OS is i/o bound? You wasted your valuable time on premature optimization. With a simple application architecture you'll also be more efficient with troubleshooting, if any problems arise. --knitti