apache-mod_log_gelf
                                
                                 apache-mod_log_gelf copied to clipboard
                                
                                    apache-mod_log_gelf copied to clipboard
                            
                            
                            
                        virtualhost related config is getting ignored
Apache supports multitenant environments. each virtual domain can have its own custom settings for each module. this is done by including module specific settings into <ifmodule [modulename]> 
log_gelf_module is not accepting "per-virtualhost" configs.
Scenario: **mod_log_gelf is configured ** /etc/httpd/conf.modules.d/02-gelf.conf
LoadModule log_gelf_module /usr/lib64/httpd/modules/mod_log_gelf.so GelfEnabled On GelfUrl "udp://172.21.0.4:12201" GelfSource "gadgetshop.am" GelfFacility "apache-gelf" GelfTag "apache_all" GelfCookie "tracking" GelfFields "ABDhImsvRti"
mod_log_gelf is enabled
[root@vps-a ~]# apachectl -M | grep gelf log_gelf_module (shared) [root@vps-a ~]#
Virtualhost is configured with log_gelf_module settings
<VirtualHost *:80> ServerName www.myserver.am ... <IfModule log_gelf_module> GelfEnabled On GelfUrl "udp://172.21.0.4:12201" GelfSource "gadgetshop.am" GelfFacility "apache-gelf" GelfTag "apache_nossl" GelfCookie "tracking" GelfFields "ABDhImsvRti"g </IfModule> </VirtualHost>
Issus: only logs with "apache_all" tag are getting forwarded to GrayLog