備份
mongodump --host 127.0.0.1 --port 27017 -d {database} --out {out-path}
恢復(fù)
mongorestore -d {database} --drop {src-path}
mongodump --host 127.0.0.1 --port 27017 -d {database} --out {out-path}
mongorestore -d {database} --drop {src-path}