Closed reallyworksxyz closed 1 year ago
@reallyworksxyz Thanks for reaching out, We will Investigate and update you shortly.
@milismsft, can you take a look at this issue? I didn't see anything obvious in the troubleshooting guide for the Linux Docker emulator.
Facing the same issue. Additionally, I get a message that the image will only continue for N number of days
docker run \
--publish 8081:8081 \
--publish 10251-10254:10251-10254 \
--memory 3g --cpus=2.0 \
--name=test-linux-emulator-mongo \
--env AZURE_COSMOS_EMULATOR_PARTITION_COUNT=10 \
--env AZURE_COSMOS_EMULATOR_ENABLE_DATA_PERSISTENCE=true \
--env AZURE_COSMOS_EMULATOR_IP_ADDRESS_OVERRIDE=$ipaddr \
--env AZURE_COSMOS_EMULATOR_ENABLE_MONGODB_ENDPOINT=4.0 \
--interactive \
mcr.microsoft.com/cosmosdb/linux/azure-cosmos-emulator &
produces:
shell: /usr/bin/bash --noprofile --norc -e -o pipefail {0}
This is an evaluation version. There are [118] days left in the evaluation period.
Invalid endpoint type enabled; only SQL endpoint type is supported.
Use mongodb
as the container image tag:
docker run \
--publish 8081:8081 \
--publish 10251-10254:10251-10254 \
--memory 3g --cpus=2.0 \
--name=test-linux-emulator-mongo \
--env AZURE_COSMOS_EMULATOR_PARTITION_COUNT=10 \
--env AZURE_COSMOS_EMULATOR_ENABLE_DATA_PERSISTENCE=true \
--env AZURE_COSMOS_EMULATOR_IP_ADDRESS_OVERRIDE=$ipaddr \
--env AZURE_COSMOS_EMULATOR_ENABLE_MONGODB_ENDPOINT=4.0 \
--interactive \
--tty \
mcr.microsoft.com/cosmosdb/linux/azure-cosmos-emulator:mongodb
Thanks! Will try it out
In any case, I think the documentation for the emulator needs to be updated to specify mcr.microsoft.com/cosmosdb/linux/azure-cosmos-emulator:mongodb
(https://docs.microsoft.com/en-us/azure/cosmos-db/linux-emulator?tabs=mongodb-api%2Cssl-netstd21#run-the-linux-emulator-on-macos)
When I include the --memory 3g --cpus=2.0 \
line, I get the error Failed to create CoreCLR, HRESULT: 0x8007000E
Omitting it, I can run the container successfully. However, the port 10255
is no longer open.
netstat -nat | grep '10255' | grep LISTEN
""
Hello @eugbyte!
We are publishing an update to the linux emulator instructions for the MongoDB API to not specify memory and CPU along with using the correct tag.
This should resolve the issue in this thread. If you run into any more issues with the docker flags, please consider giving feedback on the product feedback page.
@seesharprun the linux documentation does not publish port 10255. port 10255 is part of the mongoDB connection string
the emulator mongo db connection string is specified as mongodb://localhost:C2y6yDjf5...Jw==@localhost:10255/admin?ssl=true
docker run \
--publish 8081:8081 \
--publish 10251-10254:10251-10254 \ // <--- port 10255 is missing
--memory 3g --cpus=2.0 \
--name=test-linux-emulator \
As of now, both :mongodb and :latest are the same image, maybe that is part of the problem?
After some investigation, this seems to be a bug with the product as the :mongodb
tag incorrectly does not expose the mongodb endpoint. Unfortunately, we can't deal with product bugs here as this is a documentation repository and the docs articles are using the correct tag.
I looked at Microsoft Q&A and there doesn't seem to be a question about this issue. I recommend that you post your question over there so the custom support team can escalate this issue as it's blocking your work.
I'm sorry that I was unable to resolve this on the documentation site. Thanks for your patience and I hope this can be resolved quickly for you!
When following the instructions for Linux:MongoDB Emulator
I received the following results:
I am using
Ubuntu 20.04.4 Server LTS
andDocker version 20.10.17, build 100c701
. When running the command forSQL endpoints
everything works 100%.Similar issue refrences:
https://github.com/MicrosoftDocs/azure-docs/issues/94775
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.