Re: Error log vhost addition

2014-08-03 Thread kumar2000s
you can define error log separately per vhost inside the vhost
configuration


On Sun, Aug 3, 2014 at 5:30 PM, Leo Nikolaev  wrote:

> Hi,
>
>
>
> I’d like to propose a small patch to the error log routines.
>
>
>
> Here is the abstract. A lot of ISP’s and other hosting providers use
> mod_vhost_alias and VirtualDocumentRoot directive to provide effective
> configuration of virtual hosts.
>
>
>
> The problem comes in, when you would like to provide separate log per
> virtual host. With access log it could be easily done via log pipe: we can
> add %v variable and pass it along to some script or application, which will
> put the log line to virtual host log file.
>
>
>
> But error log is more tricky – there is no information about virtual host
> at all, so error log piping gives no ability to understand the vhost, which
> caused the error.
>
>
>
> Sure, information in error log is not always connected to any virtual
> host, it could be just some information like “Whoa, I’ve just started” or
> smth else. But there is a code, which checks whether there is request or
> even connection (lines 912 and 918 in log.c)
>
>
>
> So will it be reasonable to add [vhost: %s] section to error log string?
> Of we have info->r, we have the Host header value or host name for sure
> there.
>
>
>
> Cheers,
>
> Leo
>
>
>
>
>
>
>


Re: Serve multiple websites (not sub-domains) from port 80

2022-04-05 Thread kumar2000s
You should use Name based hosting and that will serve your purpose.

On Mon, Apr 4, 2022 at 8:48 PM A  wrote:

> Hi,
>
> I am planning to make changes to Apache web server so that it can serve
> multiple websites (not sub-domains) from port 80.
>
> This will save money for someone who has more than one website. That
> person need not buy more than one hosting plan, one hosting plan will
> suffice.
>
> Based on the incoming base URL, Apache web server will decide from which
> directory to serve the index file or other files. There will be a user file
> where user can list which website is mapped to which directory.
>
> For example:
>
> abcd:com:/abcd
> xyz.com:/xyz
>
> I am not familiar with Apache web server code so can someone point me to
> few files which I need to modify to implement this feature.
>
> Regards,
> Amit
>