Error mongoDB under Ubuntu – can’t find

When installing MongoDB under Ubuntu, one could stumble upon the following problem:

mongo: error while loading shared libraries: cannot open shared object file: No such file or directory

This is caused because MongoDB uses XulRunner for it’s operations. (This is also why you see a bunch of X11 programs that are to be installed when using apt-get). XulRunner, however, contains this file, but is not loaded.

Solving the problem:
Make sure you have xulrunner installed (sudo apt-get install xulrunner-1.9.2) and add its path to ldconfig’s configuration files, which are in/etc/ You could create a file, say, /etc/, containing the following line:


After this, you chould run ldconfig (as root) and that should do the trick. Let me know if you have any problems with this.






2 responses to “Error mongoDB under Ubuntu – can’t find”

  1. Abhishek Avatar

    Hello there,

    I tried making the file xulrunner.conf and running Mongo again but to no success.

    Any hint?

  2. Abhishek Avatar

    I found the workaround that btw,

    here it is:

    Thanks for your effort!

Leave a Reply

Your email address will not be published. Required fields are marked *