curl -O https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-3.0.6.tgz
tar -zxvf mongodb-linux-x86_64-3.0.6.tgz
mv mongodb-linux-x86_64-3.0.6 /usr/local/soft/mongodb
cd mongodb
export PATH=/usr/local/soft/mongodb/bin:$PATH
mkdir -p /data/db
cd /usr/local/soft/mongodb/bin
cd ../
./bin/mongod --auth --dbpath=/data/db/
网友评论