Oliver Nassar

Installing MongoDB on Ubuntu 10.10

January 19, 2011

Working on a new project that I'm going to use MongoDB with (just so that I have a straightforward, easy-to-use, key/value store). Here are the steps I followed to get mongo install on an Ubuntu 10.10 distro, with language bindings for Ruby, PHP and Python.

cd
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv 7F0CEB10
sudo vi /etc/apt/sources.list.d/10get.list

Insert the following:

deb http://downloads.mongodb.org/distros/ubuntu 10.10 10gen

Then continue with:

sudo apt-get update
sudo apt-get install -y mongodb-stable
sudo apt-get -y install python-software-properties
sudo add-apt-repository ppa:chris-lea/mongodb-drivers
sudo apt-get update
sudo apt-get -y install libmongodb-perl php5-mongo python-mongodb

To get the php extension loaded in, just restart your apache:

sudo /etc/init.d/apache2 restart