I have a small Zope/Squishdot installation which runs behind Apache. Zope/Squishdot is the only thing that I use the site for. Almost no one visits it. Yet my ISP (imeme) says I use an average of 120MB of memory, which it says is twice what I should be using. Is there some way I can adjust the settings on my Zope installation so that I use less average memory? What are the tradeoffs involved? __________________________________________________ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com
[Jonathan Mark wrote (jonathansamuel@yahoo.com) on 2/6/03 7:45 PM]
I have a small Zope/Squishdot installation which runs behind Apache. Zope/Squishdot is the only thing that I use the site for. Almost no one visits it.
Yet my ISP (imeme) says I use an average of 120MB of memory, which it says is twice what I should be using.
Is there some way I can adjust the settings on my Zope installation so that I use less average memory? What are the tradeoffs involved?
Try these options: 1. pack the ZODB regularly (lessens your undo options) 2. minimize the cache regularly (may use slightly more proc time) 3. restart zope regularly (occasional brief (60-120 seconds) downtime as Zope and ZEO restart) 4. keep as many images and files out of the ZODB as possible (some inconvenience) 5. move to a Zope ISP that gives you a realistic memory allocation wrt to the environment they demand you run and does not penalize you for growth. (all upside) ;P <--> george donnelly - http://zettai.net/ - "We Love Newbies" :) Zope Hosting - Dynamic Website Design - Search Engine Promotion Yahoo, AIM: zettainet - ICQ: 51907738 - e:george@zettai.net
On Friday 07 February 2003 03:48, george donnelly wrote:
3. restart zope regularly (occasional brief (60-120 seconds) downtime as Zope and ZEO restart)
You sure you want to do this on production server for serious critical-missing web-applications? Or you mean "regularly" is when you do it during night and only when NO users logged in? -- Regards, Bogdan Premature optimization is the root of all evil. -- D.E. Knuth
[Bo M. Maryniuck wrote (b.maryniuk@forbis.lt) on 2/7/03 4:18 AM]
On Friday 07 February 2003 03:48, george donnelly wrote:
3. restart zope regularly (occasional brief (60-120 seconds) downtime as Zope and ZEO restart)
You sure you want to do this on production server for serious critical-missing web-applications? Or you mean "regularly" is when you do it during night and only when NO users logged in?
Its definitely not an ideal solution but given the small memory limit he has, it is a strategy that he should consider. (I used to have an account with the same ISP so I've gone through this whole memory-use-reduction dance.) <--> george donnelly - http://zettai.net/ - "We Love Newbies" :) Zope Hosting - Dynamic Website Design - Search Engine Promotion Yahoo, AIM: zettainet - ICQ: 51907738 - e:george@zettai.net
On Friday 07 February 2003 9:18 am, Bo M. Maryniuck wrote:
On Friday 07 February 2003 03:48, george donnelly wrote:
3. restart zope regularly (occasional brief (60-120 seconds) downtime as Zope and ZEO restart)
You sure you want to do this on production server for serious critical-missing web-applications?
You can use *two* zopes and a load balancing front end proxy like squid or pound. This adds a fixed 15M (roughly) memory overhead for the second zope, plus 5M for squid (which you really should be using anyway if 60 seconds downtime bothers you). Just dont restart both zopes at the same time! -- Toby Dickenson http://www.geminidataloggers.com/people/tdickenson
On Friday 07 February 2003 1:48 am, george donnelly wrote:
Try these options:
1. pack the ZODB regularly (lessens your undo options)
That wont significantly reduce memory usage unless you havent packed for a very long time. The 'Cache Parameters' page has a 'Total number of objects in the database' field. Under filestorage you can expect to reclaim a few tens of bytes for each object romoved from this total by packing.
2. minimize the cache regularly (may use slightly more proc time)
In 2.6 the cache management is most efficient if you let it manage itself, by setting a realistic target size.
3. restart zope regularly (occasional brief (60-120 seconds) downtime as Zope and ZEO restart)
Yes, If you have a memoy leak
4. keep as many images and files out of the ZODB as possible (some inconvenience)
If this makes a significant difference then there is a bug. File and Image classes have optimisations because they expect to deal with large things. You will see a memory impact of other large (multi-megabyte) responese, such as from a DTML method 6. If you mave many concurrent users then use a front end proxy. 7. Set a smaller cache target size 8. Use fewer (2) threads. Memory usage is proportional to thread count. 9. Fix your memory leak. -- Toby Dickenson http://www.geminidataloggers.com/people/tdickenson
--On Friday, February 07, 2003 11:09:13 AM +0000 Toby Dickenson <tdickenson@geminidataloggers.com> wrote:
On Friday 07 February 2003 1:48 am, george donnelly wrote:
Try these options:
1. pack the ZODB regularly (lessens your undo options)
That wont significantly reduce memory usage unless you havent packed for a very long time. The 'Cache Parameters' page has a 'Total number of objects in the database' field. Under filestorage you can expect to reclaim a few tens of bytes for each object romoved from this total by packing.
That's generally true, but Squishdot is sort of a pathalogical case if postings (either articles or replies) are added frequently. Adding a reply changes every posting above it in the reply tree which generates ZODB growth both for the changes to the postings and for the btree index changes.
On Thursday 06 February 2003 07:45 pm, Jonathan Mark wrote:
I have a small Zope/Squishdot installation which runs behind Apache. Zope/Squishdot is the only thing that I use the site for. Almost no one visits it.
Yet my ISP (imeme) says I use an average of 120MB of memory, which it says is twice what I should be using.
Is there some way I can adjust the settings on my Zope installation so that I use less average memory? What are the tradeoffs involved?
What version of Zope are you using? Zope 2.6 has much better ZODB cache management to keep Zope's memory usage in check. If you aren't using 2.6, I would upgrade (perhaps wait a few moments until 2.6.1 comes out ;^). -Casey
participants (6)
-
Bo M. Maryniuck -
Casey Duncan -
Dan L. Pierson -
george donnelly -
Jonathan Mark -
Toby Dickenson