Troubleshooting lxd silent connection issues with mongo

Hi Everybody,

This is my first post. I’m having problems with running several Mongo databases in LXD. There are about 10 mongo databases in 10 separate LXD containers. The database connections are proxy-ed through a nginx docker container. They work fine, but after about 12-24 hours, the applications has trouble connecting to the databases. When I log into the database, I can connect fine through localhost. However, I can’t connect from the outside. Once I restart the containers “lxd restart mongodb(1,2,etc.)”, then the connections both local and outside function again. I thought it may be the size of the VM, so I increased the VM to something really big like 6 CPUs, 16 GBS and the connection issues still happen. The databases are small, about 5 GB total for all 10. With the bigger load, there is plenty of memory and CPU. Does it have something to do with the LXD network? How do I troubleshoot this?

Anyhow, I love to continue to use LXD, but this silent failure is making it hard to continue. I might have to run the databases with a docker mongodb image head, but I wanted to try this forum and see any of you guys may have any idea of what’s going on.

Thanks in advance!

Will

Does the rest of the networking appear to work?

Can the containers still connect to outside services, can you still ping them, …

Good question! I only run the database containers, but I can check the next time they fail. Thanks for the suggestions!