Apache 1.2.0 -- Virtual Host Weirdness

Apache 1.2.0 -- Virtual Host Weirdness

Post by Steve Resnic » Fri, 24 Oct 1997 04:00:00



I am running Apache 1.2.0 under Solaris 2.5.1.
I have 83 virtual servers running. When I add an 84th, cgi's stop
working for EVERY virtual server.

I tried upgrading to 1.2.4. When httpd tries to load, it gets to the
4th virtual host defined and gives me "fopen: Error 0"
"Cannot open <path to error_log file>"

Am I running against some hard limit here? If so, are there
work-arounds?

- Steve

--
/|\ Steve Resnick * 0x2b |~ 0x2b What was the question?
\|/ Please note the REMOVE-BEFORE-SENDING in my e-mail address above.
/|\ Make SPAM once again be the odd looking stuff in the blue can!

 
 
 

Apache 1.2.0 -- Virtual Host Weirdness

Post by Marc Slemk » Fri, 24 Oct 1997 04:00:00



Quote:>I am running Apache 1.2.0 under Solaris 2.5.1.
>I have 83 virtual servers running. When I add an 84th, cgi's stop
>working for EVERY virtual server.
>I tried upgrading to 1.2.4. When httpd tries to load, it gets to the
>4th virtual host defined and gives me "fopen: Error 0"
>"Cannot open <path to error_log file>"
>Am I running against some hard limit here? If so, are there
>work-arounds?

http://www.apache.org/docs/misc/FAQ.html#fdlim

See http://www.apache.org/docs/misc/descriptors.html for specific
Solaris details and how to use the HIGH_SLACK_LINE define to work
around Solaris being broken.

 
 
 

Apache 1.2.0 -- Virtual Host Weirdness

Post by Steve Resnic » Thu, 30 Oct 1997 04:00:00



> I am running Apache 1.2.0 under Solaris 2.5.1.
> I have 83 virtual servers running. When I add an 84th, cgi's stop
> working for EVERY virtual server.

> I tried upgrading to 1.2.4. When httpd tries to load, it gets to the
> 4th virtual host defined and gives me "fopen: Error 0"
> "Cannot open <path to error_log file>"

It was suggested I add -DHIGH_SLACK_LINE=256 to the EXTRA_CFLAGS in the
Makefile -- I did this in the 1.2.0 source with no additional results.

I cannot seem to get 1.2.4 to run becuase of the above errors.

Since I have 3 log files per virtual server, It would appear that I am
close to the 256 open file limit with the 83 virtual hosts.

Or, am I missing something?

Also, is there a way to have multiple instances of Apache running.
I.e., multiple "master" processes with their sets of open log files,
etc...

This would certainly solve the problem.

Any ideas on this are appreciated ....

Cheers ... Steve

--
/|\ Steve Resnick * 0x2b |~ 0x2b What was the question?
\|/ Please note the REMOVE-BEFORE-SENDING in my e-mail address above.
/|\ Make SPAM once again be the odd looking stuff in the blue can!

 
 
 

Apache 1.2.0 -- Virtual Host Weirdness

Post by Steve Resnic » Fri, 31 Oct 1997 04:00:00




> >I am running Apache 1.2.0 under Solaris 2.5.1.
> >I have 83 virtual servers running. When I add an 84th, cgi's stop
> >working for EVERY virtual server.

> >I tried upgrading to 1.2.4. When httpd tries to load, it gets to the
> >4th virtual host defined and gives me "fopen: Error 0"
> >"Cannot open <path to error_log file>"

> >Am I running against some hard limit here? If so, are there
> >work-arounds?

> http://www.apache.org/docs/misc/FAQ.html#fdlim

> See http://www.apache.org/docs/misc/descriptors.html for specific
> Solaris details and how to use the HIGH_SLACK_LINE define to work
> around Solaris being broken.

I've tried the -DNO_SLACK_LINE with no difference under 1.2.0. It is
unclear whether this was supposed to fix the fopen: error 0 problem with
1.2.4.

More sauce for the goose: I am using three log files per server.
With 83 servers, that's 249 handles, no?

Now, I can break down the virtual servers in to groups and run
multiple "master" apache processes with different Listen directives
for groups of IP addresses -- This works on my Linux box, but I haven't
tried on the Sun (it's a production machine)

What are the ramifications of using multiple Apache's with multiple
listen statements. I would imagine that I would, at least, reduce my
available handles, since there would have to be multiple sockets
created, and I assume a select call to watch for the socket to be
connected.

Are there performance considerations I should be aware of?

Would upgrading the OS to 2.6 help?

Cheers,

Steve

--
/|\ Steve Resnick * 0x2b |~ 0x2b What was the question?
\|/ Please note the REMOVE-BEFORE-SENDING in my e-mail address above.
/|\ Make SPAM once again be the odd looking stuff in the blue can!

 
 
 

Apache 1.2.0 -- Virtual Host Weirdness

Post by Marc Slemk » Fri, 31 Oct 1997 04:00:00




>> I am running Apache 1.2.0 under Solaris 2.5.1.
>> I have 83 virtual servers running. When I add an 84th, cgi's stop
>> working for EVERY virtual server.

>> I tried upgrading to 1.2.4. When httpd tries to load, it gets to the
>> 4th virtual host defined and gives me "fopen: Error 0"
>> "Cannot open <path to error_log file>"

>It was suggested I add -DHIGH_SLACK_LINE=256 to the EXTRA_CFLAGS in the
>Makefile -- I did this in the 1.2.0 source with no additional results.

That will do nothing in 1.2.0.  The document I pointed you to
states this.

Quote:>I cannot seem to get 1.2.4 to run becuase of the above errors.

Have you tried 1.2.4 with the above changes?

Quote:>Since I have 3 log files per virtual server, It would appear that I am
>close to the 256 open file limit with the 83 virtual hosts.

Check out what "ulimit -n" (assuming a bourne shell) reports.  If
that is 256, you have found you limit.  Increase that before starting
Apache.  You will still need the HIGH_SLACK_LINE with 1.2.4.

Quote:>Or, am I missing something?
>Also, is there a way to have multiple instances of Apache running.
>I.e., multiple "master" processes with their sets of open log files,
>etc...

Sure.  Just do it, however you end up using an extra descriptor
per site since you need to add a Listen directive for each IP.
 
 
 

1. Apache 1.3b2: Default Host and all virtual hosts serve only first virtual hosts pages?

Hello.

Have been running 1.2b8 for a intranet and decided to move upto 1.3b2. I
have several name based virtual hosts that have been working under
1.2b8. After compiling and installing 1.3b2 my virtual hosts do not
work. In fact what happens is that even though DocumentRoot and default
server name is different, eg: www.serverA.net pointing to /www/default,
Apache 1.3b2 will always take me to the first defined virtual host as if
it's locked to it no matter what virtual host I try to browse. What
gives? Please post and E-Mail.

In /etc/hosts for my machines IP address I have

A.B.C.D         www.default.net www.virtA.net www.virtB.net

In ../conf/httpd.conf I have;

<VirtualHost www.virtA.net>

DocumentRoot /usr/local/www/virtA
ServerName www.virtA.net
ErrorLog logs/virtA.error.log
TransferLog logs/virtA.access.log
</VirtualHost>

<VirtualHost www.virtB.net>

DocumentRoot /usr/local/www/virtB
ServerName www.virtB.net
ErrorLog logs/virtB.error.log
TransferLog logs/virtB.access.log
</VirtualHost>

--

2. FreeBSD 4.0-STABLE? where?

3. Apache Virtual Host weirdness...

4. apache logs!

5. Mixing Apache Name Based Virtual Hosts and SSL Virtual Host

6. Help with setting up small home network

7. Apache - Virtual Host or /etc/hosts

8. 3com 3c595 Vortex Options

9. Apache 2.0.x virtual host ALWAYS beings up the FIRST host in the list..

10. virtual hosting weirdness

11. FrontPage virtual hosting, removal or reset of virtual host

12. : How to prevent one named virtual host from "seeing" another virtual hosts files ?

13. For Discussion: web virtual hosting vs mail virtual hosting