"errmsg" : "distinct too big, 16mb cap",
repl_test:PRIMARY> show dbs
admin 0.000GB
direct_vote_resource 16.487GB
local 14.860GB
personas 30.809GB
recommendation 0.370GB
statistics_visit 0.138GB
superpub 75.234GB
test 0.000GB
repl_test:PRIMARY> use superpub
switched to db superpub
repl_test:PRIMARY> db.ask.count()
123989434
repl_test:PRIMARY> db.ask.find({}).limit(1)
{ "_id" : ObjectId("5b1103341ac2386e164dd796"), "md5" : "b1b791efdb4745e0", "ans wer" : "成本和37砖混的差不多的、、不过保温隔热效果好的", "likenum" : 0, "keyword " : "海容", "question" : "用海容模块建大棚成本高不高??" }
repl_test:PRIMARY> db.ask.distinct("md5").limit(3)
2018-11-23T15:27:29.186+0800 E QUERY [main] Error: distinct failed: {
"ok" : 0,
"errmsg" : "distinct too big, 16mb cap",
"code" : 17217,
"codeName" : "Location17217"
} :
DBCollection.prototype.distinct@src/mongo/shell/collection.js:1745:1
@(shell):1:1
repl_test:PRIMARY>
repl_test:PRIMARY> db.ask.aggregate([{$match:{}}, {$project:{"md5":true}}, {$group:{_id:"$md5"}}, {$group:{_id:null, count:{$sum:1}}}])
assert: command failed: {
"ok" : 0,
"errmsg" : "Exceeded memory limit for $group, but didn't allow external sort. Pass allowDiskUse:true to opt in.",
"code" : 16945,
"codeName" : "Location16945"
} : aggregate failed
_getErrorWithCode@src/mongo/shell/utils.js:25:13
doassert@src/mongo/shell/assert.js:16:14
assert.commandWorked@src/mongo/shell/assert.js:370:5
DBCollection.prototype.aggregate@src/mongo/shell/collection.js:1319:5
@(shell):1:1
2018-11-23T15:42:40.779+0800 E QUERY [main] Error: command failed: {
"ok" : 0,
"errmsg" : "Exceeded memory limit for $group, but didn't allow external sort. Pass allowDiskUse:true to opt in.",
"code" : 16945,
"codeName" : "Location16945"
} : aggregate failed :
_getErrorWithCode@src/mongo/shell/utils.js:25:13
doassert@src/mongo/shell/assert.js:16:14
assert.commandWorked@src/mongo/shell/assert.js:370:5
"errmsg" : "distinct too big, 16mb cap",的更多相关文章
- MongoDB 聚合查询报错
1.Distinct聚合查询报错 db.users.distinct("uname") db.runCommand({"distinct":"user ...
- MongoDB 聚合函数
概念 聚合函数是对一组值执行计算并返回单一的值 主要的聚合函数 count distinct Group MapReduce 1.count db.users.count() db.users.cou ...
- MongoDB常用命令
本文整理了一年多以来我常用的MongoDB操作,涉及mongo-shell.pymongo,既有运维层面也有应用层面,内容有浅有深,这也就是我从零到熟练的历程. MongoDB的使用之前也分享过一篇, ...
- MongoDB使用小结:一些常用操作分享
本文整理了一年多以来我常用的MongoDB操作,涉及mongo-shell.pymongo,既有运维层面也有应用层面,内容有浅有深,这也就是我从零到熟练的历程. MongoDB的使用之前也分享过一篇, ...
- 分布式系列文章——从ACID到CAP/BASE
事务 事务的定义: 事务(Transaction)是由一系列对系统中数据进行访问与更新的操作所组成的一个程序执行逻辑单元(Unit),狭义上的事务特指数据库事务. 事务的作用: 当多个应用程序并发访问 ...
- 分布式系统理论基础 - CAP
引言 CAP是分布式系统.特别是分布式存储领域中被讨论最多的理论,“什么是CAP定理?”在Quora 分布式系统分类下排名 FAQ 的 No.1.CAP在程序员中也有较广的普及,它不仅仅是“C.A.P ...
- {"errcode":40097,"errmsg":"invalid args hint: [vjNe7xxxxxx8vr19]"}——记录一次微信错误处理
错误情况概述: 启动应用之后,微信调用 相机拍照 等接口是可以正常使用的, 但是过了一段时间(2个小时左右--token/jsapi_ticket的过期时间),微信调用相机拍照的功能失效,启用debu ...
- [LeetCode] Longest Substring with At Most K Distinct Characters 最多有K个不同字符的最长子串
Given a string, find the length of the longest substring T that contains at most k distinct characte ...
- [LeetCode] Longest Substring with At Most Two Distinct Characters 最多有两个不同字符的最长子串
Given a string S, find the length of the longest substring T that contains at most two distinct char ...
随机推荐
- yuv420格式分析
http://blog.csdn.net/liuhongxiangm/article/details/9135791 http://blog.csdn.net/bluesky_sunshine/art ...
- 【Java面试题】25 同步和异步有何异同,在什么情况下分别使用他们?举例说明。
如果数据将在线程间共享.例如正在写的数据以后可能被另一个线程读到,或者正在读的数据可能已经被另一个线程写过了,那么这些数据就是共享数据,必须进行同步存取. 当应用程序在对象上调用了一个需要花费很长时间 ...
- UIView的背景渐变
//绘制背景渐变 /* CGCradientCreateWithColorComponents函数需要四个参数: 色彩空间:(Color Space)这是一个色彩范围的容器,类型必须是CGColorS ...
- Unity在协程内部停止协程自身后代码执行问题
当在协程内部停止自身后,后面的代码块还会继续执行,直到遇到yield语句才会终止. 经测试:停止协程,意味着就是停止yield,所以在停止协程后,yield之后的语句也就不会执行了. 代码如下: us ...
- Linux curl 命令
curl is a tool to transfer data from or to a server, using one of the supported protocols ( http ,ht ...
- 2017年要学习的三个CSS新特性
这是翻译的一篇文章,原文是:3 New CSS Features to Learn in 2017,翻译的不是很好,如有疑问欢迎指出. 新的一年,我们有一系列新的东西要学习.尽管CSS有很多新的特性, ...
- C语言之顺序结构
该章内容:这章我们学习三大结构之一:顺序结构,它是程序从上往下顺序执行,是程序运行最简单的方式.printf和scanf函数使用和特例是必考知识.本章是考试的重点章节. 学习方法:从简单的顺序结构题目 ...
- JDBC连接oracle地址出错
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 3 ...
- 解决instance中文命名导致nova list报错问题
当创建instance之后,如果使用英文命名,执行nova list的时候,无问题,但是,如果instance中出现中文,执行nova list的时候,会报以下错误: [root@controller ...
- 用示例详解php连接数据库操作
首先数据库mydb有三个表: 1 info表 2 users表 3 sname表 首先先做一个登录主页面 login_1.php <!DOCTYPE html PUBLIC "- ...