Question

How do I access mongo shell?

So I SSH as root into my droplet’s terminal and I want to access the mongo shell to drop my documents from my mongodb database. How do I got about this?

I tried

mongo

and i got

Failed global initialization: BadValue Invalid or no user locale set. Please ensure LANG and/or LC_* environment variables are set correctly.
Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

@laohasongkramsu

At the command prompt:

export LC_ALL=C

and then try again. If that doesn’t work, you may need to edit:

/etc/default/locale

and set

LANG=
LANGUAGE=
LC_ALL=

to your preferred settings. As an example:

LANG=en_US.UTF-8
LANGUAGE=en_US
LC_ALL=en_US.UTF-8

This comment has been deleted