I am using Fluentd data collector for storing Apache httpd logs in MongoDB. I made the necessary changes in td-agent configuration files like:
<source>
@type tail
format apache2
path C:\Program Files (x86)\Apache Group\Apache2\logs\access.log
tag mongo.apache
</source>
and
<match mongo.**>
# plugin type
@type mongo
# mongodb db + collection
database apache
collection access
# mongodb host + port
host localhost
port 27017
# interval
flush_interval 10s
# make sure to include the time key
include_time_key true
</match>
After doing all necessary changes, I tested configurations by pinging Apache server
ab -n 100 -c 10 http://localhost/
Everything works fine, but the logs files were not stored in MongoDB.
I did this in windows.