splitting web logs by domain
Im interested in splitting apache access logs into individual domains. the problem is that all the solutions ive seen so far put www.domain.com and domain.com in different filesusing a script called via cron is one solution: a perl regexp is the sorta thing im looking at, but the ones so far have had problems with domains such as .co.uk as opposed to .com
as a bit of background: we use mod_rewrite rules to dynamically setup sites via symlinks on the server (we symlink the urls into directories in peoples home dirs)