Created
February 27, 2013 10:38
-
-
Save alertor/5047003 to your computer and use it in GitHub Desktop.
install mongodb - CentOS 6.3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# /etc/yum.repos.d/10gen.repo | |
[10gen] | |
name=10gen Repository | |
baseurl=http://downloads-distro.mongodb.org/repo/redhat/os/x86_64 | |
gpgcheck=0 | |
enabled=1 | |
# --- | |
yum install mongo-10gen mongo-10gen-server | |
# /etc/mongod.conf | |
logpath=/var/log/mongo/mongod.log | |
logappend = true | |
fork = true | |
bind_ip = 127.0.0.1 | |
port = 27017 | |
dbpath=/var/lib/mongo | |
pidfilepath=/var/run/mongodb/mongod.pid | |
journal = true | |
nounixsocket = true | |
auth = true | |
nohttpinterface = true | |
# add admin user | |
$ mongo | |
use admin | |
db.addUser("<username>", "<password>") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment