MongoDB的备份和恢复

MongoDB的备份和恢复

进入mongodb bin目录

导出

./mongodump -d database

导入

./mongorestore -d test -c user /tmp/testdb/

相关参数

扫描二维码关注公众号,回复: 243315 查看本文章

--host localhost --port 27017 --username quicktest --password quicktest --collection trans.sp --db quicktest

参考:

http://blog.csdn.net/fdipzone/article/details/51549520

猜你喜欢

转载自crabdave.iteye.com/blog/2360281