show dbs //显示所有库
show tables //显示当前库所有表
csv 类型
-d 库名称
-c 集合名称
-f 字段名称
--type 导出类型
-o 导出名称
mongoexport -d test -c col -f name --type=csv -o /home/user/tt.csv
--type 导入类型
--headerline 第一行不导入 //json 不需要这个命令
--file 导入文件
mongoimport -d test -c col --headerline --type=csv --file /home/user/tt.csv
json 类型
mongoexport -d test -c col -f name --type=json -o /home/user/tt.json
mongoimport -d test -c col --type=json --file /home/user/tt.json