graylog2-images: configured inputs do not persist
We were running a docker container using the suggested command line:
docker run -e GRAYLOG_PASSWORD=secret -p 5556:5555 -p 515:514 -p 9000:9000 -p 12202:12201 -v /graylog/data:/var/opt/graylog/data -v /graylog/logs:/var/log/graylog graylog2/allinone
and expected my changes to Graylog to be persistent from one docker run to another. However, Graylog settings like configured inputs are gone after running the container once more.
It appears to me that the inputs are stored in the MongoDB. Is this correct? When doing a grep for the name of my configured input on the docker host:
root@srv1-graylog1:# grep -nre "marfris" /graylog/data/
Binary file /graylog/data/mongodb/graylog.0 matches
Still, there is no input configured when running the container a second time.
Other data like collected logs are persistent though.
About this issue
- Original URL
- State: closed
- Created 9 years ago
- Comments: 18 (9 by maintainers)
Could you please pull the latest image and provide this parameter when starting the container:
-e GRAYLOG_NODE_ID=30833ff4-f14c-4641-8001-0866ac439552(randomize the ID string!) This should now set the node ID to defined value. When the container is recreated on top of old data you can re-use the same ID. This should persist even inputs.