File: perlmonth3_tune.html

package info (click to toggle)
libapache-asp-perl 2.63-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 4,120 kB
  • sloc: perl: 6,044; php: 409; sh: 62; lisp: 22; makefile: 10
file content (761 lines) | stat: -rw-r--r-- 18,642 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761

<html>
<head><title>Apache::ASP Site Tuning</title></head>
<body bgcolor=white>

<blockquote>
Note: this article was from a series running on PerlMonth from 1999.
PerlMonth.com seems to have disappeared, so this article is reposted
with some slight modifications to make it current for recent releases
of Apache::ASP ( versions >= 2.29 ).
</blockquote>

<h2>Apache::ASP Site Tuning</h2>
by Joshua Chamas <i>&lt;chamas&nbsp;at&nbsp;alumni.stanford.org&gt;</i>
<p>



Last month, we used Apache::ASP to build a simple 
<a href=http://www.apache-asp.org/apps/bookmarks/>MyBookmarks</a>
web application.  Now we are going to tune the 
<a href=http://www.apache-asp.org/>Apache::ASP</a> web application and 
<a href=http://www.apache.org>Apache</a> web server, taking a mild mannered 
web app running at <tt>250,000</tt> pages per day, and boosting it up 4 times 
to a <tt>1,000,000</tt> pages per day powerhouse.
<p>
Are you ready? <font size=+1>Let's Tune!</font>
<p>

<h3>Methodology</h3>
The application was taken as it was built last week,
and incrementally benchmarked, changing one configuration
setting at a time, and showing the performance changes 
below.  The URL tested is the main URL of the application,
<a href=http://www.apache-asp.org/apps/bookmarks/index.asp
  >.../bookmarks/index.asp</a>.
<p>
The application is run on a Solaris x86 box, PII300 512K cache
with 2 4G 7200 RPM SCSI drives in a software RAID 1 configuration.  
The following numbers are not meant to be compared against
other web application environments, or systems, but show 
relative performance improvements when tuning Apache::ASP 
and Apache on this particular system.
<p>
The web server software being tested is apache 1.3.4, with 
the testing client <tt>ab</tt>, or ApacheBench, 
run locally on the server.  Because ApacheBench does not support
cookies, a new Apache::ASP $Session is created in StateDir
for every request, so that the benchmark numbers are worse 
than what you would see in a production setting.  Obviously testing locally
does not take into account many slow client connections
over the internet, which would likely be offset by a reverse
proxy accelerator in production 
(<a href=http://perl.apache.org/guide>see mod_perl guide</a>).
<p>
The <tt>ab</tt> program was run with 5 concurrent clients for 
30 seconds with the following command:
<pre>
  ab -c 5 -t 30 http:// $HOST /bookmarks/index.asp
</pre>

<h3>Tuning</h3>

After running the first bench, and watching the system under
top, it becomes strikingly clear that disk i/o is the bottleneck,
with 50%+ of the time spent waiting for disk.  The reason
is that state management for $Session and $Application uses
SDBM_File, or optionally DB_File, databases on disk to store data, 
and is highly i/o intensive.
<p>
The <i>trick</i> then is to relocate the <tt>StateDir</tt> 
to a fast cached file system.  On Solaris, this happens to 
be /tmp/... by default, but on Linux and WinNT, the file systems seem
to be cached automatically, so you may not need to do anything
except locate <tt>StateDir</tt> to a secure, non-browsable, location.
Using a cached or RAM file system will also spare your disk, which is good 
as it is often the first thing to go on your box.



<center>
<p>
<table border=0 bgcolor=gray>

<tr bgcolor=white>
<td><b>Hits/sec</b></td>
<td align=center><b>Before</b></td>
<td align=center><b>After</b></td>
</tr>

<tr>
<td bgcolor=#bbccff>
	<tt>
	+116%
	</tt>
</b></td>
<td bgcolor=yellow><tt>6.5 h/s</tt></td>
<td bgcolor=yellow><tt>14.1 h/s</tt></td>
</tr>
<tr bgcolor=white><td colspan=3><b>Configuration</b></td></tr>

	<tr>
	<td bgcolor=#c0c0c0>AP.htaccess</td>
	<td bgcolor=#c0c0c0>yes</td>
	<td bgcolor=#c0c0c0>yes</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxClients</td>
	<td bgcolor=#c0c0c0>5</td>
	<td bgcolor=#c0c0c0>5</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxRequestsPerChild</td>
	<td bgcolor=#c0c0c0>50</td>
	<td bgcolor=#c0c0c0>50</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Debug</td>
	<td bgcolor=#c0c0c0>1</td>
	<td bgcolor=#c0c0c0>1</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Global</td>
	<td bgcolor=#c0c0c0>.</td>
	<td bgcolor=#c0c0c0>.</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>GlobalPackage</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionSerialize</td>
	<td bgcolor=#c0c0c0>0</td>
	<td bgcolor=#c0c0c0>0</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionTimeout</td>
	<td bgcolor=#c0c0c0>15</td>
	<td bgcolor=#c0c0c0>15</td>
	</tr>

	<tr>
	<td bgcolor=pink>StateDir</td>
	<td bgcolor=pink>.state</td>
	<td bgcolor=pink>/tmp/bookmarks</td>
	</tr>


	<tr bgcolor=white>
	<td><b>Comments</b></td>
	<td><font size=-1>Disk i/o activity takes 50% of the time, because the StateDir is pointed at a non-caching file system.</font></td>
	<td><font size=-1>Disk i/o activity is nearly 0%, with roughly 75% of the time spent in the user space, and 25% in the kernel</font></td>
	</tr>

<tr bgcolor=white>
<td><b>Legend</b></td>
<td colspan=2>
<font size=-2 face=verdana>
Configuration items
that start with AP are Apache configuration options, the
rest are Apache::ASP.  The 
.htaccess one means that configurations are stored in the .htaccess
if yes, if no in a configuration file.  The configuration changes
between benchmarks are highlighted in <font color=pink><b>pink</b></font>.
</font>
</td></tr>
</table>
<p>
</center>

More straightforward is turning off debugging.  
The Apache::ASP code has been streamlined for production
when debugging is turned off, and there is a significant
penalty for leaving it on, as well as a bunch of clutter
in your error_log.  



<center>
<p>
<table border=0 bgcolor=gray>

<tr bgcolor=white>
<td><b>Hits/sec</b></td>
<td align=center><b>Before</b></td>
<td align=center><b>After</b></td>
</tr>

<tr>
<td bgcolor=#bbccff>
	<tt>
	+12%
	</tt>
</b></td>
<td bgcolor=yellow><tt>14.1 h/s</tt></td>
<td bgcolor=yellow><tt>15.8 h/s</tt></td>
</tr>
<tr bgcolor=white><td colspan=3><b>Configuration</b></td></tr>

	<tr>
	<td bgcolor=#c0c0c0>AP.htaccess</td>
	<td bgcolor=#c0c0c0>yes</td>
	<td bgcolor=#c0c0c0>yes</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxClients</td>
	<td bgcolor=#c0c0c0>5</td>
	<td bgcolor=#c0c0c0>5</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxRequestsPerChild</td>
	<td bgcolor=#c0c0c0>50</td>
	<td bgcolor=#c0c0c0>50</td>
	</tr>

	<tr>
	<td bgcolor=pink>Debug</td>
	<td bgcolor=pink>1</td>
	<td bgcolor=pink>0</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Global</td>
	<td bgcolor=#c0c0c0>.</td>
	<td bgcolor=#c0c0c0>.</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>GlobalPackage</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionSerialize</td>
	<td bgcolor=#c0c0c0>0</td>
	<td bgcolor=#c0c0c0>0</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionTimeout</td>
	<td bgcolor=#c0c0c0>15</td>
	<td bgcolor=#c0c0c0>15</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>StateDir</td>
	<td bgcolor=#c0c0c0>/tmp/bookmarks</td>
	<td bgcolor=#c0c0c0>/tmp/bookmarks</td>
	</tr>


	<tr bgcolor=white>
	<td><b>Comments</b></td>
	<td><font size=-1>Disk i/o activity is nearly 0%, with roughly 75% of the time spent in the user space, and 25% in the kernel</font></td>
	<td><font size=-1></font></td>
	</tr>

<tr bgcolor=white>
<td><b>Legend</b></td>
<td colspan=2>
<font size=-2 face=verdana>
Configuration items
that start with AP are Apache configuration options, the
rest are Apache::ASP.  The 
.htaccess one means that configurations are stored in the .htaccess
if yes, if no in a configuration file.  The configuration changes
between benchmarks are highlighted in <font color=pink><b>pink</b></font>.
</font>
</td></tr>
</table>
<p>
</center>

Those were the two big basic tunes for Apache::ASP.
Let's now go to the Apache web server.  So far, our
configuration information has been stored in a .htaccess
file, which must be reparsed every request by Apache.
So, we move the configuration information into one of 
the *.conf configuration files, to avoid that per
request overhead.  Also make sure to disallow .htaccess
file parsing on up the file tree by setting an 

<pre>
  AllowOverride None
</pre>

wherever your Apache::ASP application is located.



<center>
<p>
<table border=0 bgcolor=gray>

<tr bgcolor=white>
<td><b>Hits/sec</b></td>
<td align=center><b>Before</b></td>
<td align=center><b>After</b></td>
</tr>

<tr>
<td bgcolor=#bbccff>
	<tt>
	+9%
	</tt>
</b></td>
<td bgcolor=yellow><tt>15.8 h/s</tt></td>
<td bgcolor=yellow><tt>17.3 h/s</tt></td>
</tr>
<tr bgcolor=white><td colspan=3><b>Configuration</b></td></tr>

	<tr>
	<td bgcolor=pink>AP.htaccess</td>
	<td bgcolor=pink>yes</td>
	<td bgcolor=pink>no</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxClients</td>
	<td bgcolor=#c0c0c0>5</td>
	<td bgcolor=#c0c0c0>5</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxRequestsPerChild</td>
	<td bgcolor=#c0c0c0>50</td>
	<td bgcolor=#c0c0c0>50</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Debug</td>
	<td bgcolor=#c0c0c0>0</td>
	<td bgcolor=#c0c0c0>0</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Global</td>
	<td bgcolor=#c0c0c0>.</td>
	<td bgcolor=#c0c0c0>.</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>GlobalPackage</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionSerialize</td>
	<td bgcolor=#c0c0c0>0</td>
	<td bgcolor=#c0c0c0>0</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionTimeout</td>
	<td bgcolor=#c0c0c0>15</td>
	<td bgcolor=#c0c0c0>15</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>StateDir</td>
	<td bgcolor=#c0c0c0>/tmp/bookmarks</td>
	<td bgcolor=#c0c0c0>/tmp/bookmarks</td>
	</tr>


	<tr bgcolor=white>
	<td><b>Comments</b></td>
	<td><font size=-1></font></td>
	<td><font size=-1>Couldn't believe my eyes when I saw there to be so little difference when not using .htaccess.  My guess is that the Apache people optimized this at some point.</font></td>
	</tr>

<tr bgcolor=white>
<td><b>Legend</b></td>
<td colspan=2>
<font size=-2 face=verdana>
Configuration items
that start with AP are Apache configuration options, the
rest are Apache::ASP.  The 
.htaccess one means that configurations are stored in the .htaccess
if yes, if no in a configuration file.  The configuration changes
between benchmarks are highlighted in <font color=pink><b>pink</b></font>.
</font>
</td></tr>
</table>
<p>
</center>

The MaxRequestsPerChild is commonly overlooked in 
web server setup.  What this does is control the
number of requests that a child httpd server may
serve before exiting, and the parent reforking 
another one.  With mod_perl library loading
and script recompilations, a fork is no small thing,
and avoiding the fork penalty is important.
<p>
We had the MaxRequestsPerChild pretty low before 
at 50 but we up it now to 500 which should be fine
for production.  You don't want to set this too high,
or the mod_perl httpds will often take up too much
memory because of leaks, and shared forked code
becoming unshared as it gets dirtied.



<center>
<p>
<table border=0 bgcolor=gray>

<tr bgcolor=white>
<td><b>Hits/sec</b></td>
<td align=center><b>Before</b></td>
<td align=center><b>After</b></td>
</tr>

<tr>
<td bgcolor=#bbccff>
	<tt>
	+31%
	</tt>
</b></td>
<td bgcolor=yellow><tt>17.3 h/s</tt></td>
<td bgcolor=yellow><tt>22.8 h/s</tt></td>
</tr>
<tr bgcolor=white><td colspan=3><b>Configuration</b></td></tr>

	<tr>
	<td bgcolor=#c0c0c0>AP.htaccess</td>
	<td bgcolor=#c0c0c0>no</td>
	<td bgcolor=#c0c0c0>no</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxClients</td>
	<td bgcolor=#c0c0c0>5</td>
	<td bgcolor=#c0c0c0>5</td>
	</tr>

	<tr>
	<td bgcolor=pink>APMaxRequestsPerChild</td>
	<td bgcolor=pink>50</td>
	<td bgcolor=pink>500</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Debug</td>
	<td bgcolor=#c0c0c0>0</td>
	<td bgcolor=#c0c0c0>0</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Global</td>
	<td bgcolor=#c0c0c0>.</td>
	<td bgcolor=#c0c0c0>.</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>GlobalPackage</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionSerialize</td>
	<td bgcolor=#c0c0c0>0</td>
	<td bgcolor=#c0c0c0>0</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionTimeout</td>
	<td bgcolor=#c0c0c0>15</td>
	<td bgcolor=#c0c0c0>15</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>StateDir</td>
	<td bgcolor=#c0c0c0>/tmp/bookmarks</td>
	<td bgcolor=#c0c0c0>/tmp/bookmarks</td>
	</tr>


	<tr bgcolor=white>
	<td><b>Comments</b></td>
	<td><font size=-1>Couldn't believe my eyes when I saw there to be so little difference when not using .htaccess.  My guess is that the Apache people optimized this at some point.</font></td>
	<td><font size=-1>This bench only had 684 requests, so there was no parent httpd forking during this time, whereas before there may have been reforking every few seconds during the 30 second bench.</font></td>
	</tr>

<tr bgcolor=white>
<td><b>Legend</b></td>
<td colspan=2>
<font size=-2 face=verdana>
Configuration items
that start with AP are Apache configuration options, the
rest are Apache::ASP.  The 
.htaccess one means that configurations are stored in the .htaccess
if yes, if no in a configuration file.  The configuration changes
between benchmarks are highlighted in <font color=pink><b>pink</b></font>.
</font>
</td></tr>
</table>
<p>
</center>

Back to Apache::ASP, and some finer tuning.  By
default SessionSerialize is 0, and we are going
to turn it on.  What this does is lock $Session
for exclusive use during the course of the script
being run, so that any reads or writes to $Session
don't have to lock it every time.  Because of the i/o
requirements of SDBM_File, each time $Session is read from
or written to, it is freshly tied to the 
database and locked, so to avoid these ties can save much.
<p>
The reason why SessionSerialize is not enabled
by default is that one could easily deny service
to a user with a long running script, such that no
other scripts for that same user $Session could be run,
and this requires some expertise.
Also SessionSerialize is probably not a good thing 
for framed sites, where there is greater concurrency 
for the same $Session.



<center>
<p>
<table border=0 bgcolor=gray>

<tr bgcolor=white>
<td><b>Hits/sec</b></td>
<td align=center><b>Before</b></td>
<td align=center><b>After</b></td>
</tr>

<tr>
<td bgcolor=#bbccff>
	<tt>
	+12%
	</tt>
</b></td>
<td bgcolor=yellow><tt>22.8 h/s</tt></td>
<td bgcolor=yellow><tt>25.74 h/s</tt></td>
</tr>
<tr bgcolor=white><td colspan=3><b>Configuration</b></td></tr>

	<tr>
	<td bgcolor=#c0c0c0>AP.htaccess</td>
	<td bgcolor=#c0c0c0>no</td>
	<td bgcolor=#c0c0c0>no</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxClients</td>
	<td bgcolor=#c0c0c0>5</td>
	<td bgcolor=#c0c0c0>5</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxRequestsPerChild</td>
	<td bgcolor=#c0c0c0>500</td>
	<td bgcolor=#c0c0c0>500</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Debug</td>
	<td bgcolor=#c0c0c0>0</td>
	<td bgcolor=#c0c0c0>0</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Global</td>
	<td bgcolor=#c0c0c0>.</td>
	<td bgcolor=#c0c0c0>.</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>GlobalPackage</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	</tr>

	<tr>
	<td bgcolor=pink>SessionSerialize</td>
	<td bgcolor=pink>0</td>
	<td bgcolor=pink>1</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionTimeout</td>
	<td bgcolor=#c0c0c0>15</td>
	<td bgcolor=#c0c0c0>15</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>StateDir</td>
	<td bgcolor=#c0c0c0>/tmp/bookmarks</td>
	<td bgcolor=#c0c0c0>/tmp/bookmarks</td>
	</tr>


	<tr bgcolor=white>
	<td><b>Comments</b></td>
	<td><font size=-1>This bench only had 684 requests, so there was no parent httpd forking during this time, whereas before there may have been reforking every few seconds during the 30 second bench.</font></td>
	<td><font size=-1></font></td>
	</tr>

<tr bgcolor=white>
<td><b>Legend</b></td>
<td colspan=2>
<font size=-2 face=verdana>
Configuration items
that start with AP are Apache configuration options, the
rest are Apache::ASP.  The 
.htaccess one means that configurations are stored in the .htaccess
if yes, if no in a configuration file.  The configuration changes
between benchmarks are highlighted in <font color=pink><b>pink</b></font>.
</font>
</td></tr>
</table>
<p>
</center>



















From start to finish, we have nearly quadrupled the
speed of the web application, and thus the site's
ability to serve up web pages.  This one should handle
just about 1,000,000 page views per day. :) 



<center>
<p>
<table border=0 bgcolor=gray>

<tr bgcolor=white>
<td><b>Hits/sec</b></td>
<td align=center><b>Before</b></td>
<td align=center><b>After</b></td>
</tr>

<tr>
<td bgcolor=#bbccff>
	<tt>
	+296%
	</tt>
</b></td>
<td bgcolor=yellow><tt>6.5 h/s</tt></td>
<td bgcolor=yellow><tt>25.74 h/s</tt></td>
</tr>
<tr bgcolor=white><td colspan=3><b>Configuration</b></td></tr>

	<tr>
	<td bgcolor=pink>AP.htaccess</td>
	<td bgcolor=pink>yes</td>
	<td bgcolor=pink>no</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>APMaxClients</td>
	<td bgcolor=#c0c0c0>5</td>
	<td bgcolor=#c0c0c0>5</td>
	</tr>

	<tr>
	<td bgcolor=pink>APMaxRequestsPerChild</td>
	<td bgcolor=pink>50</td>
	<td bgcolor=pink>500</td>
	</tr>

	<tr>
	<td bgcolor=pink>Debug</td>
	<td bgcolor=pink>1</td>
	<td bgcolor=pink>0</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>Global</td>
	<td bgcolor=#c0c0c0>.</td>
	<td bgcolor=#c0c0c0>.</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>GlobalPackage</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	<td bgcolor=#c0c0c0>My::Bookmarks</td>
	</tr>

	<tr>
	<td bgcolor=pink>SessionSerialize</td>
	<td bgcolor=pink>0</td>
	<td bgcolor=pink>1</td>
	</tr>

	<tr>
	<td bgcolor=#c0c0c0>SessionTimeout</td>
	<td bgcolor=#c0c0c0>15</td>
	<td bgcolor=#c0c0c0>15</td>
	</tr>

	<tr>
	<td bgcolor=pink>StateDir</td>
	<td bgcolor=pink>.state</td>
	<td bgcolor=pink>/tmp/bookmarks</td>
	</tr>


	<tr bgcolor=white>
	<td><b>Comments</b></td>
	<td><font size=-1>Disk i/o activity takes 50% of the time, because the StateDir is pointed at a non-caching file system.</font></td>
	<td><font size=-1></font></td>
	</tr>

<tr bgcolor=white>
<td><b>Legend</b></td>
<td colspan=2>
<font size=-2 face=verdana>
Configuration items
that start with AP are Apache configuration options, the
rest are Apache::ASP.  The 
.htaccess one means that configurations are stored in the .htaccess
if yes, if no in a configuration file.  The configuration changes
between benchmarks are highlighted in <font color=pink><b>pink</b></font>.
</font>
</td></tr>
</table>
<p>
</center>

For more information on Apache::ASP tuning, see the 
<a href=http://www.apache-asp.org/tuning.html>tuning docs online</a>.

</body>
</html>