Re: LogSQLMassVirtualHosting and mod_vhost_alias
Dave Steinberg <[email protected]> Sat, 21 Jan 2006 18:12:37 -0500
| Newsgroups | gmane.comp.apache.mod-log-sql |
|---|---|
| Message-ID | <[email protected]> |
> I'm rather impatient to get this new configuration up and running for > our clients, so I went ahead and wrote a patch against > mod_log_sql-1.100 that impliments this functionality. I added on a > configuration directive 'LogSQLTruncateDomains', added a flag to the > global configuration structure, and tacked on some additional logic to > the log_sql_transaction function. The end result is that if you > enable LogSQLTruncateDomains *and* LogSQLMassVirtualHosting then, for > the purposes of the logging table name, any hostname of the form > foo.bar.etc.domain.tld will be truncated to simply domain.tld. > > I've tested this and it works on my system, but I don't claim to have > tested it extensively so there could very well be a bug for some other > configurations. Just from glancing at the patch, it seems like it won't work well with domains like foobar.co.uk (since it only looks for 2 dots). Perhaps there's a way to specify a regular expression instead, and have it strip off whatever matches? LogSQLStripRegex ^www\. Just a suggestion. :) -- Dave Steinberg http://www.geekisp.com/ http://www.steinbergcomputing.com/ _______________________________________________ Download the latest version at http://www.outoforder.cc/projects/apache/mod_log_sql/ To unsubscribe send an e-mail to mod_log_sql-unsubscribe-7qY7E20V6GW73k+5HYS8LQqVMODqnSLI@public.gmane.org