Docker User Number

I am running mongodb using docker compose. Within the container the /data folder is owned by mongodb which is user number 999. When I look at this docker volume on my local ubuntu machine this user number 999 is interpreted as systemd-coredump .
My question is, is this an issue or is this normal as I had expected the docker volume on ubuntu to be owned by root as docker compose is being run as root.

Hi @Tim_Pynegar and welcome to the community!!

The file ownership issue seems to be a common theme with the Docker bind mount. However, are you seeing any specific issue with the file ownership, e.g. the container failing to start, etc.?

Looking at this issue, I found the following article on File Ownership Inside Docker that may be able to help you.

If Docker bind mount continues to be troublesome for you, may I suggest you examine the merits of Docker Volume as an alternative to bind mount.

Also, please note that the official MongoDB Docker image is maintained by Docker and not by MongoDB, so if there are any issue, we have limited means to help if it involves Docker itself. Having said that, we’re happy to help if you’re having any MongoDB-specific issue.



This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.