3.6.0 speed improvements

After installing 3.6.0 I noticed a significant apparent speed decrease vs
3.4.5.

Basically, at least with my mod_perl based install, it was doing 15+ HTTP
GET’S - to fetch the current web page, the graphics, and the CSS.
I fixed that in two ways.

  1. Fedora Core 5’s Apache, at least, is disabling keepalives by default for
    some reason. I turned it on. Now a single apache process handles all the
    requests. Big speedup.

in httpd.conf

KeepAlive On

  1. Still, it was fetching all those files on every request, and arguably the
    only one that ever changes is the main web page. So I turned on:

ExpiresActive On
ExpiresByType text/css A3600 # expire in an hour
ExpiresByType image/png A3600
ExpiresByType application/x-javascript A3600
ExpiresByType image/gif A3600

Cut the number of requests per page down to 2 - and the total amount of tcp
packets on a typical rt page as measured by ethereal by about half. User
visible performance especially over the internet to my co-lo site was
markedly improved.

Now in this latter thing I only wanted to put in for NoAuth subdirs but thus
far I haven’t convinced .htaccess to work for these subdirs.

Is there a better way to do this?

Mike Taht
PostCards From the Bleeding Edge
http://the-edge.blogspot.com

  1. Still, it was fetching all those files on every request, and arguably the
    only one that ever changes is the main web page. So I turned on:

ExpiresActive On
ExpiresByType text/css A3600 # expire in an hour
ExpiresByType image/png A3600
ExpiresByType application/x-javascript A3600
ExpiresByType image/gif A3600

Cut the number of requests per page down to 2 - and the total amount of tcp
packets on a typical rt page as measured by ethereal by about half. User
visible performance especially over the internet to my co-lo site was
markedly improved.

Now in this latter thing I only wanted to put in for NoAuth subdirs but thus
far I haven’t convinced .htaccess to work for these subdirs.

Is there a better way to do this?

Well, there’s a more generic way to do it. (and we’ve started doing that
in the repository aiming otward 3.6.1), using a mason autohandler.

Jesse;
When is the planned release for 3.6.1, I am planning an upgrade to 3.6
and from I 've been reading it sounds its worth waiting till 3.6.1
Roy

Jesse Vincent wrote:

Mike Taht wrote:

After installing 3.6.0 I noticed a significant apparent speed decrease
vs 3.4.5.

Basically, at least with my mod_perl based install, it was doing 15+
HTTP GET’S - to fetch the current web page, the graphics, and the CSS.
I fixed that in two ways.

  1. Fedora Core 5’s Apache, at least, is disabling keepalives by
    default for some reason. I turned it on. Now a single apache process
    handles all the requests. Big speedup.

in httpd.conf

KeepAlive On
I’ve now also turned this on, thanks for the heads-up hadn’t noticed
this before (I run Centos 4.3 and it’s disabled by default too)

  1. Still, it was fetching all those files on every request, and
    arguably the only one that ever changes is the main web page. So I
    turned on:

ExpiresActive On
ExpiresByType text/css A3600 # expire in an hour
ExpiresByType image/png A3600
ExpiresByType application/x-javascript A3600
ExpiresByType image/gif A3600

Note to others who might try this and get configuration error : remove
the comment from text/css line this is what generates the configuration
error.

Cut the number of requests per page down to 2 - and the total amount
of tcp packets on a typical rt page as measured by ethereal by about
half. User visible performance especially over the internet to my
co-lo site was markedly improved.

Now in this latter thing I only wanted to put in for NoAuth subdirs
but thus far I haven’t convinced .htaccess to work for these subdirs.
This is probable because of the AllowOverride None directive in your
block for RT.
You should probably place the ExpiresActive directives in another
block for the /NoAuth directory or set AllowOverride All
(dangerous I think !)

Is there a better way to do this?

I’ve found that if you disable js and css completely from Mason parsing
it should give even faster results.
Using your techniques I got back to the speed I had with using this trick :

Alias /NoAuth/js /opt/rt3kvb/share/html/NoAuth/js
Alias /NoAuth/css /opt/rt3kvb/share/html/NoAuth/css

Of course this does give some bad output here and there but if you
really want speed you could probably overlook this if the RT is for
inside usage only.

Jesse :
If you could give an educated guess if disabling the js and css from
mason completely would actually impair functionality or stability ?


Mike Taht
PostCards From the Bleeding Edge
http://the-edge.blogspot.com

Vriendelijke groeten, ^ Bubbles IT
^ Oude Heerweg 175
Niels Huylebroeck ^ 9160 Lokeren, Belgie
Systeembeheerder, Programmeur ^ Tel: +32(0)9/355 13 31
niels@bubbles-it.be ^ Fax: +32(0)9/355 13 41

… Key : http://www.bubbles-it.be/pgp/niels.asc
… Fingerprint : 3885 CC0B C7A4 78CC 47DE 47AF 896A 6C40 80FA AF0F …
… Keyserver : http://pgp.mit.edu Key-ID : 0x80FAAF0F …

A diplomat is a person who can tell you to go to hell in such a way
that you actually look forward to the trip.
Caskie Stinnett, “Out of the Red”

Niels Huylebroeck wrote:

Jesse :
If you could give an educated guess if disabling the js and css from
mason completely would actually impair functionality or stability ?

The CSS and JS contains mason comments (so <%doc></%doc> and %#), which
means that if it’s unparsed by Mason, those won’t be whisked away before
the browser tries to parse it. Some browsers may handle it well and
still apply the CSS/JS correctly, others may not. If you’re going to
disable their mason parsing, I really suggest removing any mason
commands in the file.

Tom

Mike Taht wrote:

  1. Still, it was fetching all those files on every request, and arguably
    the only one that ever changes is the main web page.

Is there a better way to do this?

Still using 3.4.x, but we’ve modified the local/html/NoAuth directory so
that the content does not need to be parsed by a mason (e.g., the css
files), and then added:

Alias /NoAuth/ /data/rt/local/html/NoAuth/
<Directory /data/rt/local/html/res>
AllowOverride None
order deny,allow
allow from all

before the rest of the RT directives. Thus apache is handling the
content directly rather than letting Mason unnecessarily use CPU, IO,
and bandwidth.

Joby Walker
C&C SSG, University of Washington

Jesse;
When is the planned release for 3.6.1, I am planning an upgrade to
3.6 and from I 've been reading it sounds its worth waiting till 3.6.1
Roy

We, as a matter of course, do not promise release dates, other than
to support customers. I’m not convinced that we have the auto-logout
bug that some folks are seeing licked. That’s a showstopper for 3.6.1.

Jesse

in httpd.conf

KeepAlive On
I’ve now also turned this on, thanks for the heads-up hadn’t noticed
this before (I run Centos 4.3 and it’s disabled by default too)

You absolutely 100% don’t want to do this on a busy public web site,
especially one behind a stateful firewall. Many web clients open up
multiple connections simultaneously and you then end up with a bunch
of servers in keepalive state, where they could be helping others.

I understand. In my case it isn’t (and it’s set to only 15 seconds), and
the caching works well for the other 15 static files, so keepalive is not
required in the general case with caching turned turned on.

for a small load internal application, you won’t notice the difference.

and if you have a stateful firewall, all those keepalive state
servers will suck up all the states on your firewall in no time flat.

the redhat folks are not totally wrong in disabling it by default.

Mike Taht
PostCards From the Bleeding Edge
http://the-edge.blogspot.com

in httpd.conf

KeepAlive On
I’ve now also turned this on, thanks for the heads-up hadn’t noticed
this before (I run Centos 4.3 and it’s disabled by default too)

You absolutely 100% don’t want to do this on a busy public web site,
especially one behind a stateful firewall. Many web clients open up
multiple connections simultaneously and you then end up with a bunch
of servers in keepalive state, where they could be helping others.

for a small load internal application, you won’t notice the difference.

and if you have a stateful firewall, all those keepalive state
servers will suck up all the states on your firewall in no time flat.

the redhat folks are not totally wrong in disabling it by default.

smime.p7s (2.47 KB)

Jesse;
When is the planned release for 3.6.1, I am planning an upgrade to
3.6 and from I 've been reading it sounds its worth waiting till
3.6.1
Roy

We, as a matter of course, do not promise release dates, other than
to support customers. I’m not convinced that we have the auto-
logout bug that some folks are seeing licked. That’s a showstopper
for 3.6.1.

FWIW i upgraded our RT 3.4 to 3.6.0 this morning (2:30am!!!) and
everything seems to be running just fine. I used the FreeBSD port
for the upgrade and if I do say so myself, it went quite smoothly.

None of the service reps have complained about anything, though one
engineer did complain about the look and feel and wants to find some
customized skin he can apply to it… :slight_smile:

smime.p7s (2.47 KB)