LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-22-2009, 03:46 PM   #1
Betzie
LQ Newbie
 
Registered: May 2008
Location: UK
Distribution: CentOS 4.6
Posts: 9

Rep: Reputation: 0
Tuning Apache with Reverse Proxy


Hi -

I have a small CentOS dedicated (2 GIG) that is running Apache and Oracle XE.

It's a tiny application, and when I am not using ProxyPass it runs fine (I actually ran the same stack on a 1 GIG server).

However, once I begin to use Reverse Proxy (as within vhost as below), it's painfully slow.

I have come across some articles and posts about adjusting child processes and servers (my Apache section is at bottom) and I have been trying to adjust them, but nothing seems to help much.

Am I looking in the right place?




<VirtualHost *:80>
ServerAdmin me@mydomain.com
DocumentRoot /home/mydomain.com/htdocs
ServerName mydomain.com
ServerAlias www.mydomain.com
RewriteEngine On


RewriteRule ^/$ apex/f?p=101:1 [R=301]

ProxyRequests Off
<Proxy *>
Order allow,deny
Allow from all
</Proxy>
ProxyPass / http://localhost:8080/
ProxyPassReverse / http://localhost:8080/
</VirtualHost>


Apache server info:


# prefork MPM
# StartServers: number of server processes to start
# MinSpareServers: minimum number of server processes which are kept spare
# MaxSpareServers: maximum number of server processes which are kept spare
# ServerLimit: maximum value for MaxClients for the lifetime of the server
# MaxClients: maximum number of server processes allowed to start
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule prefork.c>
StartServers 8
MinSpareServers 5
MaxSpareServers 20
ServerLimit 256
MaxClients 256
MaxRequestsPerChild 4000
</IfModule>

# worker MPM
# StartServers: initial number of server processes to start
# MaxClients: maximum number of simultaneous client connections
# MinSpareThreads: minimum number of worker threads which are kept spare
# MaxSpareThreads: maximum number of worker threads which are kept spare
# ThreadsPerChild: constant number of worker threads in each server process
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule worker.c>
StartServers 2
MaxClients 150
MinSpareThreads 25
MaxSpareThreads 75
ThreadsPerChild 25
MaxRequestsPerChild 0
</IfModule>
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache as Reverse Proxy LR_Brian Linux - Server 4 02-17-2009 11:33 AM
Apache reverse proxy noir911 Linux - Server 0 02-05-2008 08:21 PM
reverse proxy with apache 2 bootiack Linux - Software 1 08-09-2005 06:47 PM
apache reverse proxy wildbob Linux - Networking 8 10-15-2003 12:16 PM
apache Reverse Proxy !!!!! ashish_v Linux - Software 0 09-05-2003 04:42 PM


All times are GMT -5. The time now is 10:38 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration