วันพุธที่ 30 พฤศจิกายน พ.ศ. 2554

ubuntu installing mongodb- part I : install server




The newest version of mongodb is not in repository of ubuntu. To install newest 2.0, custom repository 10gen is needed.

Add key :
#sudo apt-key adv --keyserver keyserver.ubuntu.com --recv 7F0CEB10

Add repository by creating file name '/etc/apt/sources.list.d/10gen.list'
with this line :
(using upstart)
deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen
You're ready to install :
#apt-get update#apt-get install mongodb-10gen
The mongodb is running in the system. The configuration for mongodb is /etc/mongodb.conf and in /etc/init/mongodb.conf (for startup script)

Reference:
http://www.mongodb.org/display/DOCS/Ubuntu+and+Debian+packages