[Systems] [Sugar-devel] Trac maintenance

Daniel Clark dclark at pobox.com
Thu Sep 17 21:11:33 EDT 2009


Benjamin Berg wrote:
> On Tue, 2009-09-15 at 01:39 -0400, Bernie Innocenti wrote:
>> == Performance ==
>>
>> In an attempt to solve the longstanding performance issue with our trac
>> instance, I've rebuilt and installed the latest versions of all the
>> plugins we were using.
>>
>> It didn't help much:
>>
>>   bernie at solarsail:~$ time wget http://bugs.sugarlabs.org/ticket/17 2>/dev/null
>>   real	0m12.149s
>>   user	0m0.004s
>>   sys	0m0.008s
>>   bernie at solarsail:~$ time wget http://bugs.sugarlabs.org/ticket/17 2>/dev/null
>>   real	0m4.107s
>>   user	0m0.008s
>>   sys	0m0.008s
>>   bernie at solarsail:~$ time wget http://bugs.sugarlabs.org/ticket/17 2>/dev/null
>>   real	0m6.097s
>>   user	0m0.012s
>>   sys	0m0.004s
>>
>> :-(
>>
>> It seems that 4sec is the lowest time it takes to display an ordinary
>> ticket.  The slowest responses are most probably caused by concurrent
>> requests of spammers, search engines and regular users.  Solarsail has
>> 32 processors, but our Trac setup with mod_wsgi is single threaded.
> 
> Multiple threads would probably not help much by itself, as python has
> the global interpreter lock. However, mod_wsgi has a processes parameter
> for WSGIDaemonProcess, which you could increase.
> 
> Another thing that may help if you do not do this already is to serve
> the CSS and other files statically. This can be done by running
> "trac-admin deploy trac_install static/files/dir" and Aliasing
> the /chrome URL to the created htdocs directory.
> 
> Not sure what you have already tried and done, but maybe this points
> help a bit.

http://www.websiteoptimization.com/services/analyze/ is useful - one
thing I found a while back is that some FSF sites were not compressing
javascript and/or css - below is the fix for apache2 and mod_deflate. My
experience is that this sped up load of a trac site a lot, but that may
just be because the WYSIWYG editing module was installed on the site
which was a lot of javascript text in each page which became a trivial
sized when compressed.

/etc/apache2/mods-available/deflate.conf

<IfModule mod_deflate.c>
          AddOutputFilterByType DEFLATE text/html text/plain text/xml
text/x-js text/css application/x-javascript text/x-javascript
</IfModule>

-- 
Daniel JB Clark   | Sys Admin, Free Software Foundation
pobox.com/~dclark | http://www.fsf.org/about/staff#danny

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 260 bytes
Desc: OpenPGP digital signature
Url : http://lists.sugarlabs.org/private/systems/attachments/20090917/67017aa8/attachment.pgp 


More information about the Systems mailing list