I try to use apache2gelf to send my error.log information to a graylog2 server.
To use that tool I have to change the ErrorLog setting to:
ErrorLog "|| /path/to/errorlog2gelf.py --vhost example.com"
errorlog2gelf.py itself is besides sending the input to the graylog2 server also outputting the error message again so it's possible to store it additionally into a local file.
Unfortunately I don't know how to accomplish this. I already tried piping into a file with following setting:
ErrorLog "|| /path/to/errorlog2gelf.py --vhost example.com >/var/log/httpd/error_log"
But that just throws an error from errorlog2gelf, as that program tries to interpret that as an argument, which is obviously an invalid option.
So how can I use errorlog2gelf and in parallel write to a local error.log file?