Maximum Virtualhosts per apache instance

2 posts / 0 new
Last post
#1 Mon, 11/07/2011 - 12:19
ashishpadave

Maximum Virtualhosts per apache instance

Refer http://httpd.apache.org/docs/2.2/vhosts/fd-limits.html

When using a large number of Virtual Hosts, Apache may run out of available file descriptors (sometimes called file handles) if each Virtual Host specifies different log files. The total number of file descriptors used by Apache is one for each distinct error log file, one for every other log file directive, plus 10-20 for internal use. Unix operating systems limit the number of file descriptors that may be used by a process; the limit is typically 64, and may usually be increased up to a large hard-limit.

Does Virtualmin handle this issue? Do we have an option in Virtualmin to specify a common log file and split it before the stats are generated?

Mon, 11/07/2011 - 22:18
andreychek

Howdy,

I've occasionally seen an issue with systems running out of available open files -- when that happens, you can see in the Apache logs that it's hitting an open file limit.

One workaround for that issue is to add this to the Apache init script:

ulimit -n 16384

Which bumps up the open file limit to 16384.

-Eric

Topic locked