unexpected behaviour of default host

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello List,

used for years apache 2.2, now trying to upgrade to 2.4 and do some configtests.
I noticed an unexpected behaviour of default host.
like suggested here, i use a minimal default vhost:
https://httpd.apache.org/docs/2.4/vhosts/examples.html
<VirtualHost_default_:*>
DocumentRoot"/www/default"
</VirtualHost>

In Apache 2.2 we used additional "Servername *", but with 2.4 it is not allowed to use wildcards with Servername-Directive. So we leave it empty like suggested in the docs. First loaded valid VHost will be the default host. I think the missing Servername is internal evaluated and filled with hostname of local machine. I did a lot of tests and this is my only conclusion. So this leads to problems when using local hostname in other VHosts as Servername, which may lead now to wrong Documentroots. We do it this way on a couple of thousend servers. I think this happens also to the guy who commented here at bottom of page https://httpd.apache.org/docs/2.4/vhosts/examples.html To avoid this it seems necessary to add Servername with an unexisting hostname. "ServerName non.existing_host.noTld"

Alltogether i think the 2.4 solution for defaulthosts is quite unfortunate. May be there should be used a really Default-Servername to mark defaulthost. At least the docs should be updated and admins should be informed that they are "loosing" a usable servername and there is one fault probability.

Thanks,
Hajo

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx




[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux